23 lines
490 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class movePlatform : MonoBehaviour
{
[SerializeField] private float speed;
public float acceleration;
// Start is called before the first frame update
void Start()
{
}
// Update is called once per frame
void Update()
{
// speed += acceleration * Time.deltaTime;
transform.Translate(new Vector2(-1f, 0f) * speed * Time.deltaTime);
}
}