Hello Everyone! Firstly, i just want to thank you for using your time to read this. Now, I am making a money printer plugin. And i have a decent amount of it done, but i am stuck on one thing. Storing the coordinates of the signs used for the money printers, so i may edit them later. My first thought was to just store them outright in a config file, but in cases where there were large amounts of printers on one server, that file would become bloated and pose troubles with consuming too much memory. If this isnt a valid concern, then please let me know. If it is, then i am wondering what other way is there to store this information. It would need to be accessible through server restarts and reloads keep in mind. Thanks, Anerdson
After about a half hour of research, i have determined that I am nowhere near good enough with java and bukkit to be getting into MySQL so, is there any other way? OR am i stuck with either MySQL or a massive config?
Well... to store values you have to use either the "flatfile" method (such as yaml configuration) or a database like MySQL. I don't see what else you could use ? For a matter of performance, you can find your way out by optimizing the location saving / loading... Splitting files between worlds... or whatever you can imagine to get smaller files...
Hi If it was me making this plugin I would make it so that all money printers have [Printer] on the first line and then on PlayerInteractEvent i would check if the first line is equal to [Printer]. I think this is what essentials does and its what I usually do and there doesnt seem to be a problem with it.
Ok Thanks! I would do that, but the problem is that i need to be able to update the total money in the printers constantly