how can i setup the z coordinate, i only found "RunTowardLocation( x, y )" but there is no z coordinate.
http://nemmelheim.de/wendelwelt/drachenflug.php
Flying NPC's
Re: Flying NPC's
There is more to this than just that z coordinate. If you want to change the z for now just use mobile.z := whatever integer you want;
http://forums.polserver.com/tracker.php?p=6&t=15 <---- there is my post into the feature tracker requesting this thing.
http://forums.polserver.com/tracker.php?p=6&t=15 <---- there is my post into the feature tracker requesting this thing.
Re: Flying NPC's
Hmm i only can change the z coordinate with moveobjtolocation(npc,
npc.x+i,npc.y,npc.z+50);?i want to script a traveling system with a dragon like in the link i posted.
npc.x+i,npc.y,npc.z+50);?i want to script a traveling system with a dragon like in the link i posted.
Re: Flying NPC's
yes for that needs to be done more than just the z coordinate to moving functions, because now if you force the z value to be higher, the npc will get down to the worldheight z again on next move, that why Pol should ignore the z when npc has movetype A ( Air ) so it doesnt look like jumping to ground and back up again.
I still wonder how they have made the player follow with that drake.
I still wonder how they have made the player follow with that drake.
- Damien White
- Journeyman Poster
- Posts: 68
- Joined: Tue Aug 18, 2009 6:34 pm
Re: Flying NPC's
Would it not work to have a tile created at a higher Z level, and set the tile to be invisible? Kinda like the old swimming command? Where a player would then walk across the invisible tiles.
Re: Flying NPC's
I will test it, but i do it in another way. I create the dragon as an animated item with the height of 65 in the tiledata. Then i give the char an invisible graphic, now i can use it with MoveObjToLocation .Damien White wrote:Would it not work to have a tile created at a higher Z level, and set the tile to be invisible? Kinda like the old swimming command? Where a player would then walk across the invisible tiles.
Re: Flying NPC's
Is it possible to move a charakter with a script(pol97), like if i double-click the right mouse button(pathfinding)? i know that it is possble with pol99.
Re: Flying NPC's
Just thinking, I'm not sure if it can be done, or if it is simple to do.
Simply move the pc and use the packethook to send a dragon graphic to the client.
The client should add the moving effect with the new graphic on its own, maybe a graphic-packet refresh is needed periodically.
Simply move the pc and use the packethook to send a dragon graphic to the client.
The client should add the moving effect with the new graphic on its own, maybe a graphic-packet refresh is needed periodically.
Re: Flying NPC's
Hmm this was my question, I want to move a pc. In pol99 I can do it with "CanWalk(movemode, x1, y1, z1, x2_or_dir, y2 := -1, realm := _DEFAULT_REALM)" but how can I do it on pol97?Gnafu wrote:Just thinking, I'm not sure if it can be done, or if it is simple to do.
Simply move the pc and use the packethook to send a dragon graphic to the client.
The client should add the moving effect with the new graphic on its own, maybe a graphic-packet refresh is needed periodically.
Re: Flying NPC's
pol99 is opensource try to script the code with escript.
Re: Flying NPC's
CanWalk does not move the char, simply checks IF the char can move in that direction and, if the char can it gives you the new z.
If you move the char with MoveObjectToLocation() in the direction the char is facing, you will see the walking animation.
I discovered that the chars have .movemode prop but is r/o.
If you move the char with MoveObjectToLocation() in the direction the char is facing, you will see the walking animation.
I discovered that the chars have .movemode prop but is r/o.
Re: Flying NPC's
npcs have the movemode in npcdesc, and for playing characters its of no use because player characters can only walk on land anyway.