0

I'm making a game where you can get coins, highscore etc. and keep them without setting it back to default when I exit and close the game. May I know how to do this?

2 Answers2

0

If you want the state to be restored even after your program exists and runs again, below are the options-

  1. Store the data in DB
  2. Serialize in the file system
  3. Store the data on disk
Jaydeep Rajput
  • 3,605
  • 17
  • 35
0

You need to use JDBC to store data to database in java.

Jay Smith
  • 2,331
  • 3
  • 16
  • 27