Closed valeatory closed 10 years ago
We should also write up some documentation on the format of these files.
I was thinking something like this (in json)
{
current_game: true,
current_level: 0,
levels: [
{
options: [
"1/4",
"-1/2",
"-1/3",
"2/3",
"5/6"
],
answer: "8/9"
}
]
}
Any additions to the information we should be storing?
@chrisknepper @valeatory @ExplosiveHippo @Waterseas
Documentation on the format of the files is already a separate issue: https://github.com/chrisknepper/xo-fractions-game/issues/29 If player data such as score, levels completed, etc is to be stored at the moment, it should be in a separate text file, because one should be edited by people, and the other is edited by the game. Since storing play-time variables is a separate issue from loading levels, and is used in a fundamentally different way, I would go so far as to suggest that it be added as another issue in the issue tracker instead of adding it here.
For now, that level format looks good as it will give us the ability to create a lot of testable levels quickly. Randomization can come later.
Store level parameters in an easily editable text file that the game can read and generate multiple levels from, to keep hardcoded numbers separate from the abstract game functionality.