Files
Crash-Course/Assets/Scripts/HealthBarFollow.cs
2025-02-26 20:17:19 -05:00

16 lines
263 B
C#

using UnityEngine;
public class HealthBarFollow : MonoBehaviour
{
public Transform target;
public Vector3 offset;
void Update()
{
if (target != null)
{
transform.position = target.position + offset;
}
}
}