AdminChat

AdminChat

112k Downloads

Fix dynamic command reflection

mdcfe opened this issue ยท 1 comments

commented

Issue by 1Rogue
Friday Jan 31, 2014 at 04:23 GMT
Originally opened as 1Rogue#9


Notes from a plugin page:

Before: (incompatible)

SimplePluginManager spm = (SimplePluginManager)Bukkit.getServer().getPluginManager();
Field scmF = spm.getClass().getDeclaredField("commandMap");

After: (compatible!)

PluginManager pm = Bukkit.getServer().getPluginManager();
Field scmF = pm.getClass().getDeclaredField("commandMap");

commented

Commands are now in their own classes which extend BaseCommand, which currently extends org.bukkit.command.Command.