Is there a decent tutorial for a local high score table (android)?

Hi, I have a highscore screen in my game. Which when the game ends it displays a simple highscore.

What I want to have is a few entries (say 5) eg: 1)john…999 2)bert…982 3)mike…663 4)frank…432 5)ben…125 in a verticle list.

I have searched questions and forum, youtube, googled etc which keeps bringing me back to the same results which are not really clear or easy for a newbie to understand.

Can anyone help my with this or point me to a decent tutorial please?

I currently have this script to set my highscore:

#pragma strict
var countdownTimer : countdownTimer;

function Update(){

if (countdownTimer.seconds ==0);


function GameOver () {

if(Scorecounter.Counter > PlayerPrefs.GetInt("highscore"))

		PlayerPrefs.SetInt("highscore", Scorecounter.Counter);



and this one to show it on the highscore screen (where I hope to display the highscore list):

#pragma strict
var highScore3dText : TextMesh;

function Start(){

highScore3dText.text = "High Score: " + PlayerPrefs.GetInt("highscore").ToString();


Ok so lets break down what you want bit by bit. First you say you want a few entries maybe 5. So it sounds like you need a container of some kind.

You want to have entries like “Ben 125” and “Bill 500”. My suggestion would be to use a generic dictionary container.

You also want to have the list displayed vertically. The GUI class enables you to stack elements vertically also. I’m not going to script it for you, just provide you the links to get started. Good luck!!