Forum

> > CS2D > Scripts > Clientdata(x,y)&player(x,y) distance calculation?
Forums overviewCS2D overview Scripts overviewLog in to reply

English Clientdata(x,y)&player(x,y) distance calculation?

12 replies
To the start Previous 1 Next To the start

old Re: Clientdata(x,y)&player(x,y) distance calculation?

Apache uwu
User Off Offline

Quote
Try this:

Click to reveal code:
More >


IMG:https://img189.imageshack.us/img189/7428/dedust00003i.jpg


IMG:https://img21.imageshack.us/img21/1035/dedust00004.jpg


Here's another step further:
     When a player says "teleport" they will only teleport to their mouse if it is a clear path.

Click to reveal code:
More >
edited 1×, last 31.01.12 08:19:33 am

old Re: Clientdata(x,y)&player(x,y) distance calculation?

KenVo
User Off Offline

Quote
Ah ok I'll wait 2 more years to understand those stuffs

BTW, I don't like to use 'always' hook because I don't know if it would cause high traffic...?, so I added the 'reqcld' to a skill function. The 'reqcld' only runs only when I use the skill or other skills that need pointer's x and y.

(It's not the whole script because I'm editing Weiwen's script.)

Code >


EDIT: Question: Do you think there is a way to make my "dmg" calculations in EXPpointer shorter ? If there is then would the longer calculations slower or the same as the shorten ones.

Also, my English is not completely good because I have only been in US for 2 years
edited 1×, last 01.02.12 03:18:31 am

old Re: Clientdata(x,y)&player(x,y) distance calculation?

Apache uwu
User Off Offline

Quote
user Alistaire has written
Sinus, Cosinus and Tangens aren't that hard to learn.. If you're really into scripting you should know about them.


lmao, reminds me of thread cs2d tile(x/32,y/32,'walkable) error lol @ user Infinite Rain

& no, even if you were into scripting that doesn't mean you would need to know it or even use it.

Here is an example: you are creating an accounting page, you would need to know all the aspects of banking.
To the start Previous 1 Next To the start
Log in to reply Scripts overviewCS2D overviewForums overview