Closed jcdesimp closed 8 years ago
Just use Java's default Properties class
@jamierocks I was just gonna extend Bukkit's YamlConfiguration class. I need to sort out all the hardcoded strings that are already there first, which I've already started to do.
YML just doesn't seem like the right thing to use for this.
@jamierocks I want it to be easily configurable by the server owners as well.
Properties files are easily configurable?
player.quit=%1 has quit the game.
@jamierocks I plan on having the messages sorted in a hierarchical way. Command output, help info... should be logical. There will be a default bundled inside the plugin which will get referenced if the value is not found in the user configurable one.
What advantages do Java properties offer for this? If you can convince me I'll consider it :)
Java's properties are just key=value
and comments are like # this is a comment
So to do it in a hierarchical way you would do:
player.join=%1 has joined the game! player.quit=%1 has quit the game!
server.shutdown=The server is shutting down!
I don't really see how that would make it easier, only more annoying, With yaml I only need to write out a parent node once.
Rather than using hardcoded strings for messages and words that are shown to players, the messages should be configurable externally via something such as a "message.yml" file.