Dev Commands: Difference between revisions
Jump to navigation
Jump to search
Marcely1199 (talk | contribs) (Created page with "First of all, make sure that you have the BedwarsAddon object.<br /> Click Dev_AddOn to get to the documentation for that.<br /> Adding commands isn't much harder than cre...") |
Marcely1199 (talk | contribs) No edit summary |
||
Line 1: | Line 1: | ||
First of all, make sure that you have the BedwarsAddon object.<br /> | First of all, make sure that you have the BedwarsAddon object.<br /> | ||
Click [[Dev_AddOn]] to get to the documentation for that.<br /> | Click [[Dev_AddOn|here]] to get to the documentation for that.<br /> | ||
Adding commands isn't much harder than creating the BedwarsAddon.<br /> | Adding commands isn't much harder than creating the BedwarsAddon.<br /> | ||
Simply create a new BedwarsAddonCommand (Example: | Simply create a new BedwarsAddonCommand (Example: |
Latest revision as of 16:12, 9 November 2016
First of all, make sure that you have the BedwarsAddon object.
Click here to get to the documentation for that.
Adding commands isn't much harder than creating the BedwarsAddon.
Simply create a new BedwarsAddonCommand (Example:
BedwarsAddonCommand cmd = new BedwarsAddonCommand("testcommand" /* command */, "<arg1> [arg2] [arg3]" /* usage */){ public void onWrite(String[] args){ // do something } };
) And register the command using the registerCommand method in the BedwarsAddon command (Example:
bedwarsAddon.registerCommand(cmd);
).