ZombieSquirrel
Member
Hi everyone,
I'm currently trying to create an NPC system, in which NPC's have a simple path setup,
but it turns out to not be as simple as I thought.
What I want to do is:
have a non-persistent OR persistent NPC walk along a certain path,
and be able to move between rooms.
The player can talk to the NPC, at which point the NPC stops walking.
Talking and stopping the NPC is the only way the path can be temporarily paused.
The paths don't need to dynamically change at random, just a preset path to follow.
I've figured something out with persistent NPC's,just letting them run their path
and turning their visibility ON if the current room = the room associated with the right path.
At the end of that path, the NPC will switch to the next room's path, and if the player is
also in that room, only there will the NPC remain visible.
Persistent NPC's at first seem easy to do like this, but
persistence is something i want to avoid because it's not something I would give an NPC.
Persistence is more something I use for a save data object, or specific game controller objects.
Anyone that can point me to a forum post, a video,...
where NON-PERSISTENT NPC objects have a certain path BETWEEN multiple rooms,
with the possibility of "pausing" a path and still making the NPC transition rooms correctly?
Much appreciated
I'm currently trying to create an NPC system, in which NPC's have a simple path setup,
but it turns out to not be as simple as I thought.
What I want to do is:
have a non-persistent OR persistent NPC walk along a certain path,
and be able to move between rooms.
The player can talk to the NPC, at which point the NPC stops walking.
Talking and stopping the NPC is the only way the path can be temporarily paused.
The paths don't need to dynamically change at random, just a preset path to follow.
I've figured something out with persistent NPC's,just letting them run their path
and turning their visibility ON if the current room = the room associated with the right path.
At the end of that path, the NPC will switch to the next room's path, and if the player is
also in that room, only there will the NPC remain visible.
Persistent NPC's at first seem easy to do like this, but
persistence is something i want to avoid because it's not something I would give an NPC.
Persistence is more something I use for a save data object, or specific game controller objects.
Anyone that can point me to a forum post, a video,...
where NON-PERSISTENT NPC objects have a certain path BETWEEN multiple rooms,
with the possibility of "pausing" a path and still making the NPC transition rooms correctly?
Much appreciated