[REQUEST] teleport / move using packets

11/01/2012 10:51 nonosocr1986#1
hey all , i was wondering if i can move or teleport to other location using packets , i got coordinates from "Kal World Editor" , but they are usually high numbers more than a byte can handle , since the move packet is "bbb" i think i need lower coordinates , any help ?
11/01/2012 11:38 mohm195#2
The same way you do port to mob, excpet area coord is static.
11/01/2012 15:22 hehepwnz#3
Quote:
Originally Posted by nonosocr1986 View Post
hey all , i was wondering if i can move or teleport to other location using packets , i got coordinates from "Kal World Editor" , but they are usually high numbers more than a byte can handle , since the move packet is "bbb" i think i need lower coordinates , any help ?
how about split packets?
you need to create a function that calculates how much steps you need to go to final x,y,z.
example: youre on coordinates x:1000, y:500, z: 500 and you want to go to x:2000, y:500, z:500, so you need to walk +1000 x, you could do it like that
for(int i=0;i <movesteps;i++) // movesteps = 50.
{
SendPacket(0x11,"bbb",20,0,0);
}

you can use other values ofc. just an example how it could work
11/02/2012 10:26 nonosocr1986#4
Quote:
Originally Posted by hehepwnz View Post
how about split packets?
you need to create a function that calculates how much steps you need to go to final x,y,z.
example: youre on coordinates x:1000, y:500, z: 500 and you want to go to x:2000, y:500, z:500, so you need to walk +1000 x, you could do it like that
for(int i=0;i <movesteps;i++) // movesteps = 50.
{
SendPacket(0x11,"bbb",20,0,0);
}

you can use other values ofc. just an example how it could work
it's not working :\ , i've tried it in hidden , with both 0x14 (move) and 0x15 (move stop) nothing happens , even when i put static values nothing happen , any suggestions ?
11/02/2012 12:04 katze123#5
0x14 and 0x15 are the wrong move packets. just like hehepwnz said: 0x11 (and 0x12)
11/02/2012 12:59 pamz12#6
In old client they (0x14/0x15) are right i belive
11/02/2012 16:00 nonosocr1986#7
Quote:
Originally Posted by katze123 View Post
0x14 and 0x15 are the wrong move packets. just like hehepwnz said: 0x11 (and 0x12)
i think 0x11 , 0x12 are in int , i found that 0x14 , and 0x15 for p.servers old client , any ideas :\ ?
11/02/2012 16:30 hehepwnz#8
so whats your value (x,y,z) you send to server?
11/03/2012 00:16 nonosocr1986#9
Quote:
Originally Posted by hehepwnz View Post
so whats your value (x,y,z) you send to server?
i tried your method , and i've tried sending coordinates that i got from uce just for test , with no luck :\
11/03/2012 13:44 hehepwnz#10
i mean whats the value you use for x,y,z
there is a max value you can use with that paket.
as i said you cant just send the coordinates you wanna go to.
11/03/2012 15:33 mohm195#11
Max is 127 or 128 not sure :p
What about this?
Code:
unsigned char tempx=(double(difX)/sqrt(range))*30;
unsigned char tempy=(double(difY)/sqrt(range))*30;
SendKoemV2(0x15,"bbb",tempx,tempy,0);
difX/Y is the distance between you and the coord.
11/03/2012 21:21 BorSti#12
Quote:
Originally Posted by mohm195 View Post
Max is 127 or 128 not sure :p
What about this?
Code:
unsigned char tempx=(double(difX)/sqrt(range))*30;
unsigned char tempy=(double(difY)/sqrt(range))*30;
SendKoemV2(0x15,"bbb",tempx,tempy,0);
difX/Y is the distance between you and the coord.
SendKoemV2(0x15,"bbb",tempx,tempy,0);

b= byte => max= 127 min= -128 ==> 255
11/05/2012 14:40 nonosocr1986#13
Quote:
Originally Posted by mohm195 View Post
Max is 127 or 128 not sure :p
What about this?
Code:
unsigned char tempx=(double(difX)/sqrt(range))*30;
unsigned char tempy=(double(difY)/sqrt(range))*30;
SendKoemV2(0x15,"bbb",tempx,tempy,0);
difX/Y is the distance between you and the coord.
i think that what i need , but what is "range" in this case ?
11/05/2012 16:20 hehepwnz#14
i also dont get it with range.
my function "teleport"-function works without that range thing :P
11/05/2012 18:09 mohm195#15
Code:
	int difX = Player[0].dwPlayerX - PX;
	int difY = Player[0].dwPlayerY - PY;
	float range =((difX*difX)+(difY*difY))*1.0;
xD

Can you tell us more about it? because this way sucks abit xd