Favorites Medals Posts ID:155599
ID:155599

what I am tying to do is make a pixel run along the path of a circle in a 32x32 title
closest i got this crazy parabola

 ```mob/verb/shoot() var/obj/o = new/obj/dot o.loc=usr.loc o:pixel_x=-((4+4-(abs(Tim)))**2)+30 o:pixel_y=(Tim)+23mob/verb/Up() usr.Tim+=0.5 ```

excess info
a change in the Tim var shifts the location of creation when a new pixel is created
the point i wanted the circle to begin at was at 32,14
for this Tim was orginal value was -9
Majorminor wrote:
 ```> mob/verb/shoot()> var/obj/o = new/obj/dot> o.loc=usr.loc> o:pixel_x=-((4+4-(abs(Tim)))**2)+30> o:pixel_y=(Tim)+23> mob/verb/Up()> usr.Tim+=0.5> ```

First off, don't use ":" like that, that's a terrible habit. Also, change usr to src.

You can do this:

 ```mob/verb/Circle() var/obj/o = new/obj/dot o.loc = locate(x, y, z)//same as locate(src.x, src.y, src.z) src = mob = user that clicks the verb var/radius = 32//The distance from the center of the circle for(var/angle = 0 to 360 step 10)//step #, # = how fast you want it to move around the circle o.pixel_x = cos(angle) * radius o.pixel_y = sin(angle) * radius sleep(1) ```

 #2 May 10 2011, 1:16 pm In response to Zaltron (#1) thanks for the help Zaltron