123456789101112131415161718192021222324 |
- using UnityEngine;
- /// <summary>
- /// UI使用-自动旋转脚本
- /// </summary>
- public class TransformRotater : MonoBehaviour
- {
- /// <summary>
- /// 旋转速度
- /// </summary>
- public Vector3 angleSpeed;
- // Start is called before the first frame update
- void Start()
- {
-
- }
- // Update is called once per frame
- void Update()
- {
- transform.localRotation *= Quaternion.Euler(angleSpeed * Time.deltaTime);
- }
- }
|