using System.Collections; using System.Collections.Generic; using UnityEngine; using UnityEngine.UI; public class Cloud : MonoBehaviour { [SerializeField] private float speed = 1f; Rigidbody2D rb; void Start(){ rb = GetComponent(); } void FixedUpdate(){ rb.velocity += new Vector2(speed,0); } }