Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- package AirPunch.korra.abilities;
- import org.bukkit.permissions.PermissionDefault;
- import com.projectkorra.ProjectKorra.ProjectKorra;
- import com.projectkorra.ProjectKorra.Ability.AbilityModule;
- import com.projectkorra.ProjectKorra.Element;
- public class AirPunchInformation extends AbilityModule {
- public AirPunchInformation() {
- super("AirPunch");
- }
- public String getDescription() {
- return "Left Click to shoot a punch of air, pushing back and damaging your enemy.";
- }
- public String getAuthor() {
- return "xXturbokidXx";
- }
- public String getVersion() {
- return "v1.0.0";
- }
- public String getElement() {
- return Element.Air.toString();
- }
- public boolean isShiftAbility() {
- return false;
- }
- public void onThisLoad() {
- ProjectKorra.plugin.getLogger().info("Discharge developed by jedk1 has been loaded!");
- ProjectKorra.plugin.getServer().getPluginManager().registerEvents(new AirPunchListener(), ProjectKorra.plugin);
- //Register permissions here, they will be set to default every time the move is loaded.
- ProjectKorra.plugin.getServer().getPluginManager().addPermission(new AirPunchPermissions().airpunchDefault);
- //Here you would replace 'bending.ability.Discharge' with 'bending.ability.[Your Ability]'.
- ProjectKorra.plugin.getServer().getPluginManager().getPermission("bending.ability.AirPunch").setDefault(PermissionDefault.TRUE);
- }
- public void stop() {
- //Unregister the permission, this stop it from breaking next time you start the server up. After all, you don't want the player having 100000 permission nodes of
- //"bending.ability.[Your Ability]" now do you?
- ProjectKorra.plugin.getServer().getPluginManager().removePermission(new AirPunchPermissions().AirPunchDefault);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement