Help with Obstacle. Please Help.
So I have this script that is should to put the player at this gameobject's transform position but its not working for some reason. Can someone please give me a detailed answer on why this doesn't work and what works and why it would work. Here is the code: (Btw I know I misspelled "Obsticle")
public GameObject spawnPoint;
public GameObject player;
void OnCollitionEnter ()
{
player.transform.position = spawnPoint.transform.position;
}
Answer by pankajb · May 13, 2016 at 08:09 PM
Again misspelled
change OnCollitionEnter with OnCollisionEnter
Follow this Question
Related Questions
How do you access the transform of a gameobject and put it in a variable? 3 Answers
Vector3.Lerp not working properly, making the player bounce around 2 Answers
Transform.position of object not the same as shown on the inspector 1 Answer
How to make a cylinder that dynamically connects two objects? 0 Answers
Can you help explain this positioning conundrum to me! 1 Answer