I’ve gotten my score script down, but it does not seem to reset when I restart the game from my game over scene in play mode. It’s when I exist play mode and enter it again in which the score resets. What is wrong?
Here is my score script:
#pragma strict
static var currentScore : int = 0;
var offsetY : float = 40;
var sizeX : float = 200;
var sizeY : float = 20;
function OnGUI () {
GUI.color = Color.yellow;
GUI.Box (new Rect (Screen.width/2-sizeX/2, offsetY, sizeX, sizeY), "" + currentScore);
}