Login / Registrieren
DE EN FR ES IT CZ
Zurück Nach oben

movement of the npc character along the route

  • #1, by red363 5 years ago Zitieren
    Greetings.
    There was a problem that I can't solve. I need to make the npc character move from point 1 to point 2. And upon reaching point 2, he returns to point 1. And so it is constantly (like patrolling). Is it possible to somehow implement it? Thank.
  • #2, by esmeralda 5 years ago Zitieren
    There is an action part called "jump to action part". With that you can create a loop.

    You could create a "called by other action" action and add the movement actions, then jump to the 1. action part. Call this action whenever the patrolling should start

    send character "npc" to position 1 and wait
    send character "npc" to position 2 and wait
    jump to action part #1

    kill the loop by action "quit action" or wrap the "jump" action inside an if query and change the condition to stop the loop.
  • #3, by red363 5 years ago Zitieren
    There is an action part called "jump to action part". With that you can create a loop.

    You could create a "called by other action" action and add the movement actions, then jump to the 1. action part. Call this action whenever the patrolling should start

    send character "npc" to position 1 and wait
    send character "npc" to position 2 and wait
    jump to action part #1

    kill the loop by action "quit action" or wrap the "jump" action inside an if query and change the condition to stop the loop.
    Thank you very match!