Add most of research

This commit is contained in:
Bram verhulst
2025-05-31 15:54:23 +02:00
commit 70f128f092
270 changed files with 80847 additions and 0 deletions

View File

@@ -0,0 +1,23 @@
using UnityEngine;
using UnityEngine.AI;
public class MovingController : MonoBehaviour
{
public string speedParameterName = "WalkingSpeed";
[SerializeField] private NavMeshAgent agent;
[SerializeField] private Animator animator;
void Awake()
{
// agent = GetComponent<NavMeshAgent>();
// animator = GetComponent<Animator>();
}
void Update()
{
float speed = agent.velocity.magnitude;
animator.SetFloat(speedParameterName, speed);
}
}