Quantcast
Channel: Latest Questions by Crispinator
Viewing all articles
Browse latest Browse all 30

Saving Highscore

$
0
0
I have code that calculates score based on distance. How would I go about getting this code to remember the high score after the game is quit? Thanks in advance. #pragma strict var player : Transform; function Update () { var dist : int = Vector3.Distance(player.position, transform.position); print ("Distance : " + dist); var score : int = dist / 5.5; guiText.text = "Score : " + score; }

Viewing all articles
Browse latest Browse all 30

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>