Hello, im aware to an experience modder this is probably a simple question, but ive just started today so bear with me. Ive managed to create a tile entity that saves inventory data after accessing the inventory based on this tutorial by kaupenjoe
this video Works great, works a treat, until you restart the server and all the contents of the inventory are gone.
Ive got a bunch of years experience in spigot and bukkit development and to make data persistent through restarts there we usually just save to a MySQL or YML file. I think I could probably list through all the entities with item capibility on the server when it shuts down and then save them to a YML file, and then load them back in on startup, but i have a feeling thats a very inefficient way of doing things. Anyone have any advice?
I tried looking at some other mods for an example, also tried reading the docs on this forum about capabilities and such, but couldnt quite wrap my head around it. If anyone could break it down for me real simple would be much appreciated!