I have a simple script for object follow so I can have an enemy follow the player. This is my script:
Vector3( direction = player.position - transform.position );
direction.Normalize();
transform.position += direction * speed * Time.deltaTime;
The error is that "direction" is an unexpected token. How can I fix this?
It's worth noting that the object is an animate ragdoll, however I don't want to play a separate animation for walking. I just want it to follow the player.
↧