using UnityEngine; public class MovingBlock : MonoBehaviour { [SerializeField] private float moveSpeed = 3f; // Update is called once per frame void Update() { transform.position += Vector3.left * Time.deltaTime * moveSpeed; } }
using UnityEngine; public class MovingBlock : MonoBehaviour { [SerializeField] private float moveSpeed = 3f; // Update is called once per frame void Update() { transform.position += Vector3.left * Time.deltaTime * moveSpeed; } }