Save a player's Name???

Hello,
First of all, i have to say that i am an absolute beginner…
Well, I am trying to develop a little game in which you first have to type in up to 4 Player names…My Question is: How do i manage to save the names that were typed in, so that they can still be seen, after restarting the Game???

If I wanted to share the info I would research http.request object.

If you want to store local I saw documentation near the bottom of the help I think it was called storage.

Hey,

I have the same problem. I tried the saveProjectData() function (in die init of a class). Is it just: saveProjectData(“ab”,5)?

And how do I read them? In the Setup function? With readProjectData(“ab”,import)? Does anyone know a short tutorial?

Thanks for your help.

I have implemented something similar in my current project using saveLocalData. I save player 1 data by touching a “save” button using:

saveLocalData('p1score', p1score)
saveLocalData('p1wins', p1wins)

I then read it in a statistics screen with:

p1score = readLocalData('p1score', p1score)
p1wins = readLocalData('p1wins', p1wins)

I don’t fully understand the process but it works so far.

There will be many more statistics that I will need to save and I hope to find a way to use tables to reduce coding quantity. I’ll post most when I get to that point.

.@Bobby and .@Xaxa - you could also have a look at this tutorial: http://codeatuts.blogspot.com.au/2012/07/tutorial-7-minesweeper-part-2.html

The relevant bit is on saving and loading the high score. As you need to save the data as a string it shows how you can combine different variables like name, score and difficulty for saving and then reversing the process for loading.