2024-09-11 12:56:13 +03:00

14 lines
282 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class FollowYRotation : MonoBehaviour
{
public Transform target;
void Update()
{
if (target != null) transform.eulerAngles = new Vector3(0 ,target.eulerAngles.y, 0);
}
}