mergemilitary/Assets/Scripts/Utils/AutoRotate.cs

20 lines
359 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class AutoRotate : MonoBehaviour
{
[SerializeField] Vector3 mRotateSpeed;
private Transform mTrans;
private void Awake()
{
mTrans = transform;
}
private void Update()
{
mTrans.Rotate(mRotateSpeed * Time.deltaTime);
}
}