Chapter 11Use Configuration Files and Store Game Data

Now we’ll add some storage capability to your toolbox, and discover some more advanced Java language features. You’ll add these skills:

  • Save and load user-editable configuration data from a local file

  • Save and load your private game data from a database

  • Build up more complex code from smaller functions

  • Use Canary’s DataAccess to use their built-in database functions

  • Understand Java exceptions and annotations

Now we’re getting someplace. From what you’ve learned so far, you can listen for events, schedule tasks to run later, keep data around in lists or hashes, and let your whole plugin use it as long as the server is up and running. That puts you in a good position to build some ...

Get Learn to Program with Minecraft Plugins, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.