We are about to switch to a new forum software. Until then we have removed the registration on this forum.
okay so I need help with how to create a high score board for a slings and arrows game I am making for my computer studies course summative the rubric says I need to use file I/O in my code to create a high score table that will be displayed when you loose or win my game and I have no idea how to do it please can you help me.
Answers
https://forum.Processing.org/two/discussions/tagged/highscore
You could have a high score during one session
When your game has a restart you could have 6 games in a row and every time see a high score (of yourself or you and your friend)
Simple - and no file i/o required
Can you do this? Like showing a high score after the game and restart?
This is already quite hard... you need a proper state system to tell the program in which state it is.
@neshki --
In the reference, look up the section under Input > Files -- there are many useful functions there that support different approaches.
In particular check out
loadStrings
(if you want to load and save raw data) andloadTable()
(if you want to load and save more structured, tabular data).You can use text, XML, JSON, or whatever you like to store your data. As you will see from past discussions (linked above), one general pattern might be: