circle please help

ioxc

New Member
Reaction score
0
can someone tell me how can i make a trigger that make unit move at circle/spiral?



(sorry for my english im from israel)
 

ioxc

New Member
Reaction score
0
moveing in a Circuit
i mean like spinning but not in the place and end at the same point
(360 degrees)
and spiral is like spinning and getting closer to a target point

and at moving i mean like

events- evrey 0.02 of game time

actions
move unit instantly to <rly close point that i need to know>

(sorry for my english im from israel)
 

ZakkWylde-

New Member
Reaction score
14
periodically (every .2 seconds is fine--though .3 will work too, less demanding, and still pretty smooth):

Set unit's x position to xCoordOfCircleCenter + radiusOfCircle*Cos(angle)
set unit's y position to yCoordOfCircleCenter + radiusOfCircle*Sin(angle)

set angle = angle + 1.5 (1.5 is effectively the speed of the unit going around the circle...)


radiusOfCircle is a constant (100 is pretty good) -- you can make it a variable, integer, if you want.
angle is a REAL.
 
General chit-chat
Help Users

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top