Files
racesm/Assets/Scripts/NPC improved.cs
magn9775 c598a700e2 RoadKill
2024-04-20 11:31:59 +02:00

27 lines
422 B
C#

using System.Collections;
using System.Collections.Generic;
using UnityEngine;
public class NPCimproved : MonoBehaviour
{
// Animator animator;
public Animator animator;
void Start()
{
}
void Update()
{
}
void OnCollisionEnter(Collision col) {
if (col.gameObject.tag == "Player")
{
animator.SetTrigger("hit");
}
}
}