Hi. I am making an iOS game, and for some reason, Unity3d is saying I need a semicolon when there is actually one there. Here is the code:
//Script to revert winning player back to main menu
var levelToLoad : String;
function OnTriggerEnter(hit : Collider)
{
if (other.gameObject.name == "Player")
then Application.LoadLevel(levelToLoad);
}
//END FUNCTION ONTRIGGERENTER
It says I need a semicolon on lines 8,7. Please help!
↧