Movement Packets(Need Help)

08/17/2011 22:15 silencer61#1
Hey all

im making bot . i have problems with movement packets.I can't get posZ coordinat(Height) .Anyone have formule?
08/17/2011 22:22 sarkoplata#2
Why you need it ?
08/17/2011 22:41 silencer61#3
for example if i wanna go x:1234 y:456 and i write wrong Zcoord, it goes wrong side
08/17/2011 23:02 kevin_owner#4
There isn't a formula for it. You will need to read the .nvm(navmesh) files which contain the height of a certain position. You can find these files in the data.pk2 in the folder navmesh.

But lucky for you the server should correct the z coord. so sent 0 and it should be fine.
08/17/2011 23:12 silencer61#5
thx bro

Code:
            Packet move = new Packet(0x7021);
            move.WriteByte(1);
            move.WriteByte(sectorx);
            move.WriteByte(sectory);
            move.WriteInt16(posx);
            move.WriteInt16(posy);
            move.WriteInt16(0);   //z
when i send this it goes wrong side
where is mistake?
08/17/2011 23:18 ÑõÑ_Ŝŧóp#6
[C -> S] 7021
01 // flag
[byte] x sec
[byte] y sec
[word] x pos
[word] z pos
[word] y pos


you replaced y with z :)
08/17/2011 23:19 kevin_owner#7
Code:
            Packet move = new Packet(0x7021);
            move.WriteByte(1);
            move.WriteByte(sextorx);
            move.WriteByte(sextory);
            move.WriteInt16(posx);
            move.WriteInt16(0);   //z
            move.WriteInt16(posy);
Try this.

Edit: nonstop beat me
08/17/2011 23:23 silencer61#8
thx so much. It works woowww! xD
08/18/2011 01:03 sarkoplata#9
As I said, you dont need it . :)