Full Version : Moving PCs
xmlspawner >>Q&A >>Moving PCs
<< Prev | Next >>
Hale- 07-24-2007
I'm wondering about the syntax used to move a player from one place to the next. I've got the players using a gump that's triggered based on an item and if they have the item then they can pass through a gate, but I wanted to teleport them to the other side.
Or perhaps would it be easier for me to spawn a door with an xmlspawner and have the gump, once the conditions are satisfied, just open the door for the player?
ArteGordon- 07-24-2007
you can set the Location property on them to the exact target coordinates, or you could just increment their X or Y coords if you wanted to make it a relative change instead of an absolute one, like this
SETONTRIGMOB/location/(100,200,0)
or
SETONTRIGMOB/x/INC,3
Note that you might also want to consider moving their pets. You would do the same thing but use the SETONPETS instead of the SETONTRIGMOB keyword
from xmlspawner2.txt

QUOTE
- added the new standalone keyword 'SETONPETS,range' that allows you to set properties on nearby pets belonging to the triggering mob where the range is the distance from the triggering mob. You would use it like SETONPETS,range/prop/value/prop/value...

so if this was in an Action field of an XmlDialog entry, for example, you could do both with something like
SETONPETS,10/location/(100,200,0) ; SETONTRIGMOB/location/(100,200,0)
remember to move the pets first otherwise the range test will not find them after you move the player.
Hale- 07-24-2007
Awesome, this just what I needed!