mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-21 20:56:45 +01:00
don't show unimplemented supers for mccooldowns
This commit is contained in:
parent
64206c3ac8
commit
ed0c9469e2
@ -206,17 +206,15 @@ public enum SuperAbilityType {
|
||||
public boolean getPermissions(Player player) {
|
||||
return switch (this) {
|
||||
case BERSERK -> Permissions.berserk(player);
|
||||
case EXPLOSIVE_SHOT -> Permissions.explosiveShot(player);
|
||||
case BLAST_MINING -> Permissions.remoteDetonation(player);
|
||||
case GIGA_DRILL_BREAKER -> Permissions.gigaDrillBreaker(player);
|
||||
case GREEN_TERRA -> Permissions.greenTerra(player);
|
||||
case SERRATED_STRIKES -> Permissions.serratedStrikes(player);
|
||||
case SKULL_SPLITTER -> Permissions.skullSplitter(player);
|
||||
case SUPER_BREAKER -> Permissions.superBreaker(player);
|
||||
case SUPER_SHOTGUN -> Permissions.superShotgun(player);
|
||||
case TREE_FELLER -> Permissions.treeFeller(player);
|
||||
case TRIDENTS_SUPER_ABILITY -> Permissions.tridentsSuper(player);
|
||||
case MACES_SUPER_ABILITY -> Permissions.macesSuper(player);
|
||||
// TODO: once implemented, return permissions for the following abilities
|
||||
case EXPLOSIVE_SHOT, TRIDENTS_SUPER_ABILITY, SUPER_SHOTGUN, MACES_SUPER_ABILITY -> false;
|
||||
};
|
||||
}
|
||||
|
||||
|
@ -10,12 +10,4 @@ public class MacesManager extends SkillManager {
|
||||
public MacesManager(McMMOPlayer mmoPlayer) {
|
||||
super(mmoPlayer, PrimarySkillType.MACES);
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the player can activate the Super Ability for Maces
|
||||
* @return true if the player can activate the Super Ability, false otherwise
|
||||
*/
|
||||
public boolean canActivateAbility() {
|
||||
return mmoPlayer.getToolPreparationMode(ToolType.MACES) && Permissions.macesSuper(getPlayer());
|
||||
}
|
||||
}
|
||||
|
@ -13,14 +13,6 @@ public class TridentsManager extends SkillManager {
|
||||
super(mmoPlayer, PrimarySkillType.TRIDENTS);
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the player can activate the Super Ability for Tridents
|
||||
* @return true if the player can activate the Super Ability, false otherwise
|
||||
*/
|
||||
public boolean canActivateAbility() {
|
||||
return mmoPlayer.getToolPreparationMode(ToolType.TRIDENTS) && Permissions.tridentsSuper(getPlayer());
|
||||
}
|
||||
|
||||
public double impaleDamageBonus() {
|
||||
int rank = RankUtils.getRank(getPlayer(), SubSkillType.TRIDENTS_IMPALE);
|
||||
|
||||
|
@ -185,7 +185,6 @@ public final class Permissions {
|
||||
public static boolean concoctions(Permissible permissible) { return permissible.hasPermission("mcmmo.ability.alchemy.concoctions"); }
|
||||
|
||||
/* ARCHERY */
|
||||
public static boolean explosiveShot(Permissible permissible) { return permissible.hasPermission("mcmmo.ability.archery.explosiveshot"); }
|
||||
public static boolean arrowRetrieval(Permissible permissible) { return permissible.hasPermission("mcmmo.ability.archery.trackarrows"); }
|
||||
public static boolean daze(Permissible permissible) { return permissible.hasPermission("mcmmo.ability.archery.daze"); }
|
||||
|
||||
@ -233,25 +232,13 @@ public final class Permissions {
|
||||
public static boolean treeFeller(Permissible permissible) { return permissible.hasPermission("mcmmo.ability.woodcutting.treefeller"); }
|
||||
|
||||
/* CROSSBOWS */
|
||||
public static boolean superShotgun(Permissible permissible) {
|
||||
return permissible.hasPermission("mcmmo.ability.crossbows.supershotgun");
|
||||
}
|
||||
public static boolean trickShot(Permissible permissible) { return permissible.hasPermission("mcmmo.ability.crossbows.trickshot"); }
|
||||
public static boolean poweredShot(Permissible permissible) { return permissible.hasPermission("mcmmo.ability.crossbows.poweredshot"); }
|
||||
|
||||
/* TRIDENTS */
|
||||
public static boolean tridentsSuper(Permissible permissible) {
|
||||
return false;
|
||||
// return permissible.hasPermission("mcmmo.ability.tridents.superability");
|
||||
}
|
||||
public static boolean tridentsLimitBreak(Permissible permissible) { return permissible.hasPermission("mcmmo.ability.tridents.superability"); }
|
||||
|
||||
/* MACES */
|
||||
public static boolean macesSuper(Permissible permissible) {
|
||||
// TODO: When a super is added, change this
|
||||
return false;
|
||||
}
|
||||
|
||||
public static boolean macesLimitBreak(Permissible permissible) { return permissible.hasPermission("mcmmo.ability.maces.limitbreak"); }
|
||||
|
||||
/*
|
||||
|
Loading…
Reference in New Issue
Block a user