Official Everybody Edits Forums

Do you think I could just leave this part blank and it'd be okay? We're just going to replace the whole thing with a header image anyway, right?

You are not logged in.

#1 2016-09-18 16:35:32

GareY
Member
Joined: 2015-10-28
Posts: 23

Help in "m"

Can some1 Help in "m" https://github.com/Tunous/EverybodyEditsProtocol#sm-m

I want to move to cords, thanks.


G511Cwj.png

98% of teenagers cannot count; if you're apart of the 3% that can, copy this into your signature.

Offline

#2 2016-09-18 16:53:32

MartenM
Member
From: The Netherlands
Joined: 2016-03-31
Posts: 978
Website

Re: Help in "m"

"m"

Sent to move.

Id	Type	Name	Description
0	Double	X	The x coordinate of the player's position.
1	Double	Y	The y coordinate of the player's position.

You have to divide these by 16.
So

playerX = m.GetDouble(0) / 16

lm3hgg8.jpg

Ingame: marten22        My steam: MartenM

Offline

Wooted by: (2)

#3 2016-09-18 17:40:41

Koya
Fabulous Member
From: The island with those Brits
Joined: 2015-02-18
Posts: 6,310

Re: Help in "m"

GareY wrote:

I want to move to cords, thanks.

connection.Send("m", x*16, y*16, 0, 0, 0, 0, 0, 0, 0, false, false, 0);

x and y to block grid.


Po9cnQh.png

PLNQVL8.png
Thank you eleizibeth ^

1SYOldu.png

I stack my signatures rather than delete them so I don't lose them
giphy.gif

WfSi4mm.png

Offline

#4 2016-09-18 17:55:23

MartenM
Member
From: The Netherlands
Joined: 2016-03-31
Posts: 978
Website

Re: Help in "m"

Miss understood the question. Thought that he wanted to get the players X and Y.
He meant what @koya said. I helped him with it using TV.


lm3hgg8.jpg

Ingame: marten22        My steam: MartenM

Offline

#5 2016-09-18 18:15:21

Tomahawk
Forum Mod
From: UK
Joined: 2015-02-18
Posts: 2,847

Re: Help in "m"

Kinda off-topic, but:

MartenM wrote:
playerX = m.GetDouble(1) / 16;

If your "playerX" variable is an int it'll cut off any decimal places remaining after that division, meaning your coordinates will always be rounded down. This is bad for things like digbot, so you should round it to the nearest integer by doing:

playerX = Convert.ToInt32(m.GetDouble(1) / 16);

One bot to rule them all, one bot to find them. One bot to bring them all... and with this cliché blind them.

Offline

#6 2016-09-18 18:26:39

Thanel
Member
Joined: 2015-02-18
Posts: 713

Re: Help in "m"

I thought that it might be useful to add a small tip about it in the protocol documentation to make it easier to discover.

Do you think something like this is good enough to be included?

Offline

Wooted by: (2)
Thanel1474219599623527

Board footer

Powered by FluxBB

[ Started around 1732678573.3744 - Generated in 0.078 seconds, 14 queries executed - Memory usage: 1.48 MiB (Peak: 1.62 MiB) ]