using System; using UnityEngine; using System.Collections; public class liikumine3 : MonoBehaviour { float nurk=0; public float nurgasamm=0.01f; public float horisontaalraadius=10; public float vertikaalraadius=7; public float keskx = 0; public float kesky = 0; void Update () { float x = keskx + (float)(horisontaalraadius * Math.Cos (nurk)); float y = kesky + (float)(vertikaalraadius * Math.Sin (nurk)); transform.position = new Vector3 (x, y, 0); nurk += nurgasamm; } }