Moving non-playing characters

Started by Thriller, Sun 20/04/2008 03:11:16

Previous topic - Next topic

Thriller

 I have a problem I was going through the manual and i seen how to move characters and I typed it in the Repeat script and it works but i don't want the timer on it and it won't let me leave the current room the moving non-player character is in.
                            Sorry if you don't understand :(

          ~Thriller

Mazoliin

Sorry, I don't understand.

What code did you use?
How do you want the character to walk?

If you want the non-player character walk around in a path (say, a patrolling guard) you can use this:
Code: ags


//In room repeatedly_execute

if (cGuard.Walking == false){
  cGuard.AddWaypoint(x1, y1); //First place to walk to
  cGuard.AddWaypoint(x2, y2); //Second place to walk to
  //Keep adding the above AddWaypoint depending on the route
}



Hope this is to any help

Thriller

 Thats what i was looking for but in the second spot to walk it says

"MoveCharacterPath: Move is to complex,cannot add any further paths"

Thriller

 some reason it only works with moving once

SMF spam blocked by CleanTalk