I have looked into rotation, and other similar thing, but can’t figure out how to spin like this dash. I want it go to center for infinity. When it comes to center delete that one.
Also any advice how to manage this dashes. Do i need to init all dashes at beggining in start function, and when it comes to center, to put that dash at begging of circle?
In attachment is picture
Sorry for bad english… If any clearification be needed, ask
Here what i hacked, i only can tell u
_divider and _acc is for speed and radius of circle
Try hacking it to adjust your needs. In overall, LateUpdate is key-thing
float _time_Counter = 0;
float _divider = 1;
float _acc = 0;
// Update is called once per frame
void Update () {
_time_Counter += Time.deltaTime;
float x = Mathf.Cos (_time_Counter);
float y = Mathf.Sin (_time_Counter);
float z = 0;
x /= _divider;
y /= _divider;
transform.Translate (new Vector3 (x, y, z));
}
void LateUpdate(){
_divider += 0.0005f;
_acc += 0.01f; // if higher, cycle is smaller, and vice versa
}