Plugin update #25
Reference in New Issue
Block a user
No description provided.
Delete Branch "master"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
So I fixed and changed a few things in this pull request. Please let me know if you're not happy with anything in this pull request.
Looks nice, great work! I didn't get a chance to test it though. I added you on the bukkitdev project as well, if you feel like uploading the jar there.
Sure, I'd be happy to do that. You added the wrong ShadowRanger though. Unfortunately someone took my name on BukkitDev so I had to use ShadowRanger24 instead.
I just sent you a PM on BukkitDev with my actual account.
That's unfortunate... I corrected the permissions on bukkitdev. Thanks for helping out! (I also have to say that I'm quite embarrassed reading over my old code, seeing bad practices everywhere)
I've added you as a github commiter as well, in case you want to oversee the repo anytime in the future.
Alright sweet, thanks. I'll upload the updated jar of the plugin tonight :)
Actually I have a few questions which I was hoping you could provide some input on.
Currently the plugin uses item id's for setting the item which is used to perform the openinv command when a player right clicks. Due to the fact that this is now deprecated with the Minecraft changes to how blocks and items are identified, I thought it might be worth updating the plugin so it uses names instead. The only thing with this is for people who are currently using id's for the item they want to use and how they might have to change their config to use the name of the item instead.
Another thing that I wanted to ask was in regards to the current method used for setting a player's status for silent/any chest into the config. Right now it uses player names when saving to config so I thought it might be worth changing them to UUID's instead. But then again, a similar problem to above would be how to approach old configs. I was thinking of maybe using the UUIDFetcher I added to retrieve the UUID's of any of the usernames people might have added and converting the usernames to them instead. But with that I'm not sure because I wouldn't want to have the plugin do that without them knowing and then when they happen to check wonder what happened to their config.
Please let me know what you think.
I'm thinking of running some kind of migration on plugin load that would check and read the old integer and write it back as a string corresponding to the item. Then we can internally use the item name instead.
I'd say add a "config version" field that will identify whether the config is from the old world (no config version field) or new world (with, say, version=1).
I don't think anyone would manually touch the config for that. It would have been probably better if I used some kind of DB (like sqlite) but the config option was lightweight so I chose that.
I'd say use the same method as the config upgrade I wrote above. Migrate everything to UUIDs and then put in a config version so you don't attempt to migrate again.
@ShadowRanger worlds largest necro but -
I was looking over the commit - would it not be useful, for the sake of backwards compatibility (for plugins using the player methods) to just have a bunch of methods for Player but they just return the same method but using Player#getUniqueId()?