Author Topic: Finding the distance between two points [SOLVED]  (Read 952 times)

Alright, let's speak hypothetically here.

Let's say that I want to take my current position and the position of another person and then find the distance between us. I am aware of the formula to find the distance between two points, however I would like to know how I would go about doing it in Blockland. The reason for my wanting to know this shall remain unknown to anyone but myself for the time being.

I greatly appreciate all, if any, help.
« Last Edit: September 07, 2011, 07:17:48 PM by Gamefandan »

vectordist("x y z", "x y z");

Also

msqrt(mpow(x, 2) + mpow(y, 2) + mpow(z, 2));

vectordist("x y z", "x y z");

Also

msqrt(mpow(x, 2) + mpow(y, 2) + mpow(z, 2));

Yeah that basically solved all my problems, thanks.

Ah, yes.

%bot.pathtime[%ArgB] = vectordist(%bot.pathpoint[%m],%bot.gettransform())/%bot.MaxForwardSpeed;

This will be perfect.

seeing how long a bot will take to scurry somewhere? i wonder what that could be used for


seeing how long a bot will take to scurry somewhere? i wonder what that could be used for

Maybe pathbots. MAYBE.

Maybe pathbots. MAYBE.

There are going to be many more equations that I personally don't think you have the skills or knowledge to pull off.

There are going to be many more equations that I personally don't think you have the skills or knowledge to pull off.

I didn't know what a vector until recently and I still made BuildBot and Terragen in the meantime.
I made a coding help topic about how to find the player from the client because I didnt know it was possible to do %client.player just a few months ago.

I really don't think you are one to be talking.

There are going to be many more equations that I personally don't think you have the skills or knowledge to pull off.

Pathbots would be an addition to my already successful Copymod.

I have nearly three years coding experience, however I still forget things, like any normal person would.

So thank you for your helpful feedback towards my coding help thread. Doucheforgeter.

Pathbots would be an addition to my already successful Copymod.

I have nearly three years coding experience, however I still forget things, like any normal person would.

So thank you for your helpful feedback towards my coding help thread. Doucheforgeter.

I've seen your "successful" (though it has virtually no use IMO) copymod's code and my statement still remains.



I have no reason to argue with someone so bent on just trying to make me angry.

I'm better than you and I pity you very wholeheartedly.

He's been an starfish today, don't mind him.

this makes me want to make a TD mod somehow