java - Best way to save game data for an rpg -


i making space themed game many different types of data needing saved, , require here list of things need save hdd:

  1. player data (health, position, array of ints indicating quest completion)(only 1 player per saved game)
  2. an arbitrary amount of planets composed of fixed amount of levels. level 2d array of hierarchical tile data , arraylist of mobs.

i need of these files not editable user, say, .properties file not work. far internet has pointed me json files , xml files, neither of i'm familiar willing learn, , serialization of objects. assume best way store player's data serialize , store in file. level i'm not sure about. better serialize entire level or each tile individually? or besides serialization better in instance? goal computational efficiency , minimum save/load time.

if want light file read fast use json framworks in java know good:

  • gson
  • jackson

if want make file more readable use xml abut xml read here:

which best library xml parsing in java


Comments

Popular posts from this blog

node.js - Node js - Trying to send POST request, but it is not loading javascript content -

javascript - Replicate keyboard event with html button -

javascript - Web audio api 5.1 surround example not working in firefox -