Drawing Line and Checking if something is inside circles in Developer Help
|
|
Well i've made a post about this (I think...) But seems like it's gone ;_; So i have to repost... I've got this so far using Forum_account MousePosition library.
obj/Capturing/Stylus icon = 'Stylus.dmi'; icon_state = "Stylus"; screen_loc = "1,1"
turf icon = 'trf.dmi';
client MouseUpdate(tx, px, ty, py) var/mob/A = src.mob; A.MyStylus.screen_loc = "[tx]:[px - 16],[ty]:[py - 16]"
mob Login() ..() track_mouse() var obj/Capturing/Stylus/MyStylus;
client/MouseDown() { var/obj/Capturing/Stylus/Stylus = new(); mob.MyStylus = Stylus; src.screen += Stylus; }
|
What i'm missing is the line drawing (Which in my oppinion is a little hard depending on the direction.)
Something like this: http://youtu.be/eFbqywlRZa8?t=3m22s (How line is begin drawed... and how the system checks that pokemon is inside the "circle", i've been looking and seems like this is done by some maths.)
Thanks.
|