mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-28 16:16:47 +01:00
Merge branch 'master' of github.com:mcMMO-Dev/mcMMO into tridentsxbows
This commit is contained in:
commit
642a351bb5
@ -60,6 +60,26 @@ Version 2.2.000
|
|||||||
|
|
||||||
Notes:
|
Notes:
|
||||||
These are the first new skills that I've written for mcMMO in about 9 years, I'll be listening closely to feedback and tweaking them often.
|
These are the first new skills that I've written for mcMMO in about 9 years, I'll be listening closely to feedback and tweaking them often.
|
||||||
|
Version 2.1.143
|
||||||
|
mcMMO now tracks super ability boosted items through persistent metadata
|
||||||
|
mcMMO no longer relies on lore to tell if an item has been modified by a super ability
|
||||||
|
Slight buff to Rupture (1 more tick duration across all ranks)
|
||||||
|
Lore no longer gets added to items being buffed by mcMMO
|
||||||
|
|
||||||
|
NOTES:
|
||||||
|
The item tracking is persistent for MC versions 1.13-1.16.2 (and beyond). However the code handling the persistence for 1.13.2 differs from the other versions. It shouldn't result in any problems.
|
||||||
|
Any items that currently have the old "mcMMO Ability Tool" lore on them will have that lore stripped off them and will have any dig speed enchants removed. This should only affect glitched items that never properly got their buffs removed.
|
||||||
|
|
||||||
|
Version 2.1.142
|
||||||
|
Iron Arm Style renamed to Steel Arm Style
|
||||||
|
Steel Arm Style now scales over 20 ranks instead of 5
|
||||||
|
Added 'mcmmo.ability.unarmed.steelarmstyle' permission node
|
||||||
|
Removed 'mcmmo.ability.unarmed.ironarmstyle' permission node
|
||||||
|
Added locale entry 'Unarmed.SubSkill.SteelArmStyle.Name'
|
||||||
|
Added locale entry 'Unarmed.SubSkill.SteelArmStyle.Description'
|
||||||
|
Updated locale entry 'Unarmed.Ability.Bonus.0'
|
||||||
|
|
||||||
|
>>>>>>> b35c58ec21f8eaec83f57f11b869fba6765b3856
|
||||||
Version 2.1.141
|
Version 2.1.141
|
||||||
Added some missing values for 1.16.2 compatibility modes
|
Added some missing values for 1.16.2 compatibility modes
|
||||||
|
|
||||||
|
@ -3,6 +3,7 @@ package com.gmail.nossr50.commands.skills;
|
|||||||
import com.gmail.nossr50.datatypes.skills.PrimarySkillType;
|
import com.gmail.nossr50.datatypes.skills.PrimarySkillType;
|
||||||
import com.gmail.nossr50.datatypes.skills.SubSkillType;
|
import com.gmail.nossr50.datatypes.skills.SubSkillType;
|
||||||
import com.gmail.nossr50.locale.LocaleLoader;
|
import com.gmail.nossr50.locale.LocaleLoader;
|
||||||
|
import com.gmail.nossr50.mcMMO;
|
||||||
import com.gmail.nossr50.util.Permissions;
|
import com.gmail.nossr50.util.Permissions;
|
||||||
import com.gmail.nossr50.util.TextComponentFactory;
|
import com.gmail.nossr50.util.TextComponentFactory;
|
||||||
import com.gmail.nossr50.util.skills.CombatUtils;
|
import com.gmail.nossr50.util.skills.CombatUtils;
|
||||||
@ -60,7 +61,7 @@ public class UnarmedCommand extends SkillCommand {
|
|||||||
|
|
||||||
// IRON ARM
|
// IRON ARM
|
||||||
if (canIronArm) {
|
if (canIronArm) {
|
||||||
ironArmBonus = mcMMO.getUserManager().getPlayer(player).getUnarmedManager().getIronArmDamage();
|
ironArmBonus = mcMMO.getUserManager().getPlayer(player).getUnarmedManager().getSteelArmStyleDamage();
|
||||||
}
|
}
|
||||||
|
|
||||||
// IRON GRIP
|
// IRON GRIP
|
||||||
@ -74,7 +75,7 @@ public class UnarmedCommand extends SkillCommand {
|
|||||||
@Override
|
@Override
|
||||||
protected void permissionsCheck(Player player) {
|
protected void permissionsCheck(Player player) {
|
||||||
canBerserk = RankUtils.hasUnlockedSubskill(player, SubSkillType.UNARMED_BERSERK) && Permissions.berserk(player);
|
canBerserk = RankUtils.hasUnlockedSubskill(player, SubSkillType.UNARMED_BERSERK) && Permissions.berserk(player);
|
||||||
canIronArm = canUseSubskill(player, SubSkillType.UNARMED_IRON_ARM_STYLE);
|
canIronArm = canUseSubskill(player, SubSkillType.UNARMED_STEEL_ARM_STYLE);
|
||||||
canDeflect = canUseSubskill(player, SubSkillType.UNARMED_ARROW_DEFLECT);
|
canDeflect = canUseSubskill(player, SubSkillType.UNARMED_ARROW_DEFLECT);
|
||||||
canDisarm = canUseSubskill(player, SubSkillType.UNARMED_DISARM);
|
canDisarm = canUseSubskill(player, SubSkillType.UNARMED_DISARM);
|
||||||
canIronGrip = canUseSubskill(player, SubSkillType.UNARMED_IRON_GRIP);
|
canIronGrip = canUseSubskill(player, SubSkillType.UNARMED_IRON_GRIP);
|
||||||
|
@ -0,0 +1,14 @@
|
|||||||
|
package com.gmail.nossr50.datatypes.meta;
|
||||||
|
|
||||||
|
import com.gmail.nossr50.mcMMO;
|
||||||
|
import org.bukkit.metadata.FixedMetadataValue;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Stores the original dig speed of a tool, also marks the tool as boosted by super abilities
|
||||||
|
*/
|
||||||
|
public class SuperAbilityToolMeta extends FixedMetadataValue {
|
||||||
|
|
||||||
|
public SuperAbilityToolMeta(int value, mcMMO plugin) {
|
||||||
|
super(plugin, value);
|
||||||
|
}
|
||||||
|
}
|
@ -30,7 +30,6 @@ import com.gmail.nossr50.util.Permissions;
|
|||||||
import com.gmail.nossr50.util.experience.MMOExperienceBarManager;
|
import com.gmail.nossr50.util.experience.MMOExperienceBarManager;
|
||||||
import com.gmail.nossr50.util.input.AbilityActivationProcessor;
|
import com.gmail.nossr50.util.input.AbilityActivationProcessor;
|
||||||
import com.gmail.nossr50.util.input.SuperAbilityManager;
|
import com.gmail.nossr50.util.input.SuperAbilityManager;
|
||||||
import com.gmail.nossr50.util.skills.RankUtils;
|
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
import org.bukkit.entity.Player;
|
import org.bukkit.entity.Player;
|
||||||
import org.bukkit.metadata.FixedMetadataValue;
|
import org.bukkit.metadata.FixedMetadataValue;
|
||||||
@ -570,4 +569,9 @@ public class McMMOPlayer extends PlayerProfile {
|
|||||||
public void togglePartyChatSpying() {
|
public void togglePartyChatSpying() {
|
||||||
getPersistentPlayerData().togglePartyChatSpying();
|
getPersistentPlayerData().togglePartyChatSpying();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
//TODO: Rewrite this
|
||||||
|
public double getAttackStrength() {
|
||||||
|
return 1.0F;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -63,7 +63,7 @@ public enum PrimarySkillType {
|
|||||||
TAMING(TamingManager.class, Color.PURPLE,
|
TAMING(TamingManager.class, Color.PURPLE,
|
||||||
ImmutableList.of(SubSkillType.TAMING_BEAST_LORE, SubSkillType.TAMING_CALL_OF_THE_WILD, SubSkillType.TAMING_ENVIRONMENTALLY_AWARE, SubSkillType.TAMING_FAST_FOOD_SERVICE, SubSkillType.TAMING_GORE, SubSkillType.TAMING_HOLY_HOUND, SubSkillType.TAMING_SHARPENED_CLAWS, SubSkillType.TAMING_SHOCK_PROOF, SubSkillType.TAMING_THICK_FUR, SubSkillType.TAMING_PUMMEL)),
|
ImmutableList.of(SubSkillType.TAMING_BEAST_LORE, SubSkillType.TAMING_CALL_OF_THE_WILD, SubSkillType.TAMING_ENVIRONMENTALLY_AWARE, SubSkillType.TAMING_FAST_FOOD_SERVICE, SubSkillType.TAMING_GORE, SubSkillType.TAMING_HOLY_HOUND, SubSkillType.TAMING_SHARPENED_CLAWS, SubSkillType.TAMING_SHOCK_PROOF, SubSkillType.TAMING_THICK_FUR, SubSkillType.TAMING_PUMMEL)),
|
||||||
UNARMED(UnarmedManager.class, Color.BLACK, SuperAbilityType.BERSERK,
|
UNARMED(UnarmedManager.class, Color.BLACK, SuperAbilityType.BERSERK,
|
||||||
ImmutableList.of(SubSkillType.UNARMED_BERSERK, SubSkillType.UNARMED_UNARMED_LIMIT_BREAK, SubSkillType.UNARMED_BLOCK_CRACKER, SubSkillType.UNARMED_ARROW_DEFLECT, SubSkillType.UNARMED_DISARM, SubSkillType.UNARMED_IRON_ARM_STYLE, SubSkillType.UNARMED_IRON_GRIP)),
|
ImmutableList.of(SubSkillType.UNARMED_BERSERK, SubSkillType.UNARMED_UNARMED_LIMIT_BREAK, SubSkillType.UNARMED_BLOCK_CRACKER, SubSkillType.UNARMED_ARROW_DEFLECT, SubSkillType.UNARMED_DISARM, SubSkillType.UNARMED_STEEL_ARM_STYLE, SubSkillType.UNARMED_IRON_GRIP)),
|
||||||
WOODCUTTING(WoodcuttingManager.class, Color.OLIVE, SuperAbilityType.TREE_FELLER,
|
WOODCUTTING(WoodcuttingManager.class, Color.OLIVE, SuperAbilityType.TREE_FELLER,
|
||||||
ImmutableList.of(SubSkillType.WOODCUTTING_LEAF_BLOWER, SubSkillType.WOODCUTTING_TREE_FELLER, SubSkillType.WOODCUTTING_HARVEST_LUMBER)),
|
ImmutableList.of(SubSkillType.WOODCUTTING_LEAF_BLOWER, SubSkillType.WOODCUTTING_TREE_FELLER, SubSkillType.WOODCUTTING_HARVEST_LUMBER)),
|
||||||
TRIDENTS(TridentManager.class, Color.TEAL, ImmutableList.of(SubSkillType.TRIDENTS_MULTI_TASKING, SubSkillType.TRIDENTS_TRIDENTS_LIMIT_BREAK)),
|
TRIDENTS(TridentManager.class, Color.TEAL, ImmutableList.of(SubSkillType.TRIDENTS_MULTI_TASKING, SubSkillType.TRIDENTS_TRIDENTS_LIMIT_BREAK)),
|
||||||
|
@ -95,7 +95,7 @@ public enum SubSkillType {
|
|||||||
UNARMED_BERSERK(1),
|
UNARMED_BERSERK(1),
|
||||||
UNARMED_BLOCK_CRACKER,
|
UNARMED_BLOCK_CRACKER,
|
||||||
UNARMED_DISARM(1),
|
UNARMED_DISARM(1),
|
||||||
UNARMED_IRON_ARM_STYLE(5),
|
UNARMED_STEEL_ARM_STYLE(20),
|
||||||
UNARMED_IRON_GRIP(1),
|
UNARMED_IRON_GRIP(1),
|
||||||
UNARMED_UNARMED_LIMIT_BREAK(10),
|
UNARMED_UNARMED_LIMIT_BREAK(10),
|
||||||
|
|
||||||
|
@ -686,7 +686,7 @@ public class BlockListener implements Listener {
|
|||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if ((mmoPlayer.getSuperAbilityManager().getAbilityMode(SuperAbilityType.SUPER_BREAKER) && !BlockUtils.affectedBySuperBreaker(blockState)) || (mmoPlayer.getSuperAbilityManager().getAbilityMode(SuperAbilityType.GIGA_DRILL_BREAKER) && !BlockUtils.affectedByGigaDrillBreaker(blockState))) {
|
if ((mmoPlayer.getSuperAbilityManager().getAbilityMode(SuperAbilityType.SUPER_BREAKER) && !BlockUtils.affectedBySuperBreaker(blockState)) || (mmoPlayer.getSuperAbilityManager().getAbilityMode(SuperAbilityType.GIGA_DRILL_BREAKER) && !BlockUtils.affectedByGigaDrillBreaker(blockState))) {
|
||||||
SkillUtils.handleAbilitySpeedDecrease(player);
|
SkillUtils.removeAbilityBoostsFromInventory(player);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -382,6 +382,10 @@ public class InventoryListener implements Listener {
|
|||||||
|
|
||||||
@EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true)
|
@EventHandler(priority = EventPriority.MONITOR, ignoreCancelled = true)
|
||||||
public void onInventoryClickEvent(InventoryClickEvent event) {
|
public void onInventoryClickEvent(InventoryClickEvent event) {
|
||||||
|
if(event.getCurrentItem() == null) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
SkillUtils.removeAbilityBuff(event.getCurrentItem());
|
SkillUtils.removeAbilityBuff(event.getCurrentItem());
|
||||||
if (event.getAction() == InventoryAction.HOTBAR_SWAP) {
|
if (event.getAction() == InventoryAction.HOTBAR_SWAP) {
|
||||||
if(isOutsideWindowClick(event))
|
if(isOutsideWindowClick(event))
|
||||||
@ -390,7 +394,7 @@ public class InventoryListener implements Listener {
|
|||||||
PlayerInventory playerInventory = event.getWhoClicked().getInventory();
|
PlayerInventory playerInventory = event.getWhoClicked().getInventory();
|
||||||
|
|
||||||
if(playerInventory.getItem(event.getHotbarButton()) != null)
|
if(playerInventory.getItem(event.getHotbarButton()) != null)
|
||||||
SkillUtils.removeAbilityBuff(event.getWhoClicked().getInventory().getItem(event.getHotbarButton()));
|
SkillUtils.removeAbilityBuff(playerInventory.getItem(event.getHotbarButton()));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -413,6 +417,7 @@ public class InventoryListener implements Listener {
|
|||||||
|
|
||||||
ItemStack result = event.getRecipe().getResult();
|
ItemStack result = event.getRecipe().getResult();
|
||||||
|
|
||||||
|
//TODO: what is the point of this
|
||||||
if (!ItemUtils.isMcMMOItem(result)) {
|
if (!ItemUtils.isMcMMOItem(result)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -650,7 +650,7 @@ public class PlayerListener implements Listener {
|
|||||||
|
|
||||||
// Make sure the player knows what he's doing when trying to salvage an enchanted item
|
// Make sure the player knows what he's doing when trying to salvage an enchanted item
|
||||||
if (salvageManager.checkConfirmation(true)) {
|
if (salvageManager.checkConfirmation(true)) {
|
||||||
SkillUtils.handleAbilitySpeedDecrease(player);
|
SkillUtils.removeAbilityBoostsFromInventory(player);
|
||||||
salvageManager.handleSalvage(clickedBlock.getLocation(), heldItem);
|
salvageManager.handleSalvage(clickedBlock.getLocation(), heldItem);
|
||||||
player.updateInventory();
|
player.updateInventory();
|
||||||
}
|
}
|
||||||
|
@ -37,7 +37,7 @@ public class AbilityDisableTask extends BukkitRunnable {
|
|||||||
switch (ability) {
|
switch (ability) {
|
||||||
case SUPER_BREAKER:
|
case SUPER_BREAKER:
|
||||||
case GIGA_DRILL_BREAKER:
|
case GIGA_DRILL_BREAKER:
|
||||||
SkillUtils.handleAbilitySpeedDecrease(player);
|
SkillUtils.removeAbilityBoostsFromInventory(player);
|
||||||
// Fallthrough
|
// Fallthrough
|
||||||
|
|
||||||
case BERSERK:
|
case BERSERK:
|
||||||
|
@ -188,6 +188,9 @@ public class BleedTimerTask extends BukkitRunnable {
|
|||||||
if(toolTier < 4)
|
if(toolTier < 4)
|
||||||
ticks = Math.max(1, (ticks / 3));
|
ticks = Math.max(1, (ticks / 3));
|
||||||
|
|
||||||
|
ticks+=1;
|
||||||
|
|
||||||
|
|
||||||
BleedContainer newBleedContainer = new BleedContainer(entity, ticks, bleedRank, toolTier, attacker);
|
BleedContainer newBleedContainer = new BleedContainer(entity, ticks, bleedRank, toolTier, attacker);
|
||||||
bleedList.put(entity, newBleedContainer);
|
bleedList.put(entity, newBleedContainer);
|
||||||
}
|
}
|
||||||
|
@ -113,7 +113,7 @@ public class SmeltingManager extends SkillManager {
|
|||||||
applyXpGain(Smelting.getResourceXp(smelting), XPGainReason.PVE, XPGainSource.PASSIVE);
|
applyXpGain(Smelting.getResourceXp(smelting), XPGainReason.PVE, XPGainSource.PASSIVE);
|
||||||
|
|
||||||
if (Config.getInstance().getDoubleDropsEnabled(PrimarySkillType.SMELTING, result.getType())
|
if (Config.getInstance().getDoubleDropsEnabled(PrimarySkillType.SMELTING, result.getType())
|
||||||
&& isSecondSmeltSuccessful()) {
|
&& isSecondSmeltSuccessful() && result.getAmount() < 64) {
|
||||||
ItemStack newResult = result.clone();
|
ItemStack newResult = result.clone();
|
||||||
|
|
||||||
newResult.setAmount(result.getAmount() + 1);
|
newResult.setAmount(result.getAmount() + 1);
|
||||||
|
@ -35,10 +35,10 @@ public class UnarmedManager extends SkillManager {
|
|||||||
}
|
}
|
||||||
|
|
||||||
public boolean canUseIronArm() {
|
public boolean canUseIronArm() {
|
||||||
if(!RankUtils.hasUnlockedSubskill(getPlayer(), SubSkillType.UNARMED_IRON_ARM_STYLE))
|
if(!RankUtils.hasUnlockedSubskill(getPlayer(), SubSkillType.UNARMED_STEEL_ARM_STYLE))
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
return Permissions.isSubSkillEnabled(getPlayer(), SubSkillType.UNARMED_IRON_ARM_STYLE);
|
return Permissions.isSubSkillEnabled(getPlayer(), SubSkillType.UNARMED_STEEL_ARM_STYLE);
|
||||||
}
|
}
|
||||||
|
|
||||||
public boolean canUseBerserk() {
|
public boolean canUseBerserk() {
|
||||||
@ -145,23 +145,22 @@ public class UnarmedManager extends SkillManager {
|
|||||||
/**
|
/**
|
||||||
* Handle the effects of the Iron Arm ability
|
* Handle the effects of the Iron Arm ability
|
||||||
*/
|
*/
|
||||||
public double calculateIronArmDamage() {
|
public double calculateSteelArmStyleDamage() {
|
||||||
if (!RandomChanceUtil.isActivationSuccessful(SkillActivationType.ALWAYS_FIRES, SubSkillType.UNARMED_IRON_ARM_STYLE, getPlayer())) {
|
if (!RandomChanceUtil.isActivationSuccessful(SkillActivationType.ALWAYS_FIRES, SubSkillType.UNARMED_STEEL_ARM_STYLE, getPlayer())) {
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
return getIronArmDamage();
|
return getSteelArmStyleDamage();
|
||||||
}
|
}
|
||||||
|
|
||||||
public double getIronArmDamage() {
|
public double getSteelArmStyleDamage() {
|
||||||
int rank = RankUtils.getRank(getPlayer(), SubSkillType.UNARMED_IRON_ARM_STYLE);
|
double rank = RankUtils.getRank(getPlayer(), SubSkillType.UNARMED_STEEL_ARM_STYLE);
|
||||||
|
double bonus = 0;
|
||||||
|
|
||||||
if(rank == 1)
|
if(rank >= 18)
|
||||||
{
|
bonus = 1 + rank - 18;
|
||||||
return 1.5;
|
|
||||||
} else {
|
return bonus + 0.5 + (rank / 2);
|
||||||
return 3 + (rank * 2);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -1,16 +1,21 @@
|
|||||||
package com.gmail.nossr50.util;
|
package com.gmail.nossr50.util;
|
||||||
|
|
||||||
|
import com.gmail.nossr50.config.AdvancedConfig;
|
||||||
import com.gmail.nossr50.config.Config;
|
import com.gmail.nossr50.config.Config;
|
||||||
import com.gmail.nossr50.config.party.ItemWeightConfig;
|
import com.gmail.nossr50.config.party.ItemWeightConfig;
|
||||||
import com.gmail.nossr50.locale.LocaleLoader;
|
import com.gmail.nossr50.locale.LocaleLoader;
|
||||||
import com.gmail.nossr50.mcMMO;
|
import com.gmail.nossr50.mcMMO;
|
||||||
import org.bukkit.ChatColor;
|
import org.bukkit.ChatColor;
|
||||||
import org.bukkit.Material;
|
import org.bukkit.Material;
|
||||||
|
import org.bukkit.enchantments.Enchantment;
|
||||||
import org.bukkit.entity.Player;
|
import org.bukkit.entity.Player;
|
||||||
import org.bukkit.inventory.FurnaceRecipe;
|
import org.bukkit.inventory.FurnaceRecipe;
|
||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
import org.bukkit.inventory.Recipe;
|
import org.bukkit.inventory.Recipe;
|
||||||
import org.bukkit.inventory.meta.ItemMeta;
|
import org.bukkit.inventory.meta.ItemMeta;
|
||||||
|
import org.jetbrains.annotations.NotNull;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
import static org.bukkit.Material.AIR;
|
import static org.bukkit.Material.AIR;
|
||||||
|
|
||||||
@ -23,29 +28,28 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a bow, false otherwise
|
* @return true if the item is a bow, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isBow(ItemStack item) {
|
public static boolean isBow(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isBow(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isBow(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isCrossbow(ItemStack itemStack) {
|
public static boolean isCrossbow(@NotNull ItemStack itemStack) {
|
||||||
return mcMMO.getMaterialMapStore().isCrossbow(itemStack.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isCrossbow(itemStack.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public static boolean hasItemInEitherHand(@NotNull Player player, @NotNull Material material) {
|
||||||
public static boolean hasItemInEitherHand(Player player, Material material) {
|
|
||||||
return hasItemInEitherHand(player, material.getKey().getKey());
|
return hasItemInEitherHand(player, material.getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean hasItemInEitherHand(Player player, String id) {
|
public static boolean hasItemInEitherHand(@NotNull Player player, @NotNull String id) {
|
||||||
return player.getInventory().getItemInMainHand().getType().getKey().getKey().equalsIgnoreCase(id)
|
return player.getInventory().getItemInMainHand().getType().getKey().getKey().equalsIgnoreCase(id)
|
||||||
|| player.getInventory().getItemInOffHand().getType().getKey().getKey().equalsIgnoreCase(id);
|
|| player.getInventory().getItemInOffHand().getType().getKey().getKey().equalsIgnoreCase(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean hasItemInMainHand(Player player, String id) {
|
public static boolean hasItemInMainHand(@NotNull Player player, @NotNull String id) {
|
||||||
return player.getInventory().getItemInMainHand().getType().getKey().getKey().equalsIgnoreCase(id);
|
return player.getInventory().getItemInMainHand().getType().getKey().getKey().equalsIgnoreCase(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean hasItemInOffHand(Player player, String id) {
|
public static boolean hasItemInOffHand(@NotNull Player player, @NotNull String id) {
|
||||||
return player.getInventory().getItemInOffHand().getType().getKey().getKey().equalsIgnoreCase(id);
|
return player.getInventory().getItemInOffHand().getType().getKey().getKey().equalsIgnoreCase(id);
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -56,11 +60,11 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a sword, false otherwise
|
* @return true if the item is a sword, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isSword(ItemStack item) {
|
public static boolean isSword(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isSword(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isSword(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isTrident(ItemStack itemStack) {
|
public static boolean isTrident(@NotNull ItemStack itemStack) {
|
||||||
return mcMMO.getMaterialMapStore().isTrident(itemStack.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isTrident(itemStack.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -89,7 +93,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a hoe, false otherwise
|
* @return true if the item is a hoe, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isHoe(ItemStack item) {
|
public static boolean isHoe(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isHoe(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isHoe(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -99,7 +103,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a shovel, false otherwise
|
* @return true if the item is a shovel, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isShovel(ItemStack item) {
|
public static boolean isShovel(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isShovel(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isShovel(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -109,7 +113,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is an axe, false otherwise
|
* @return true if the item is an axe, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isAxe(ItemStack item) {
|
public static boolean isAxe(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isAxe(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isAxe(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -119,7 +123,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a pickaxe, false otherwise
|
* @return true if the item is a pickaxe, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isPickaxe(ItemStack item) {
|
public static boolean isPickaxe(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isPickAxe(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isPickAxe(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -129,7 +133,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item counts as unarmed, false otherwise
|
* @return true if the item counts as unarmed, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isUnarmed(ItemStack item) {
|
public static boolean isUnarmed(@NotNull ItemStack item) {
|
||||||
if (Config.getInstance().getUnarmedItemsAsUnarmed()) {
|
if (Config.getInstance().getUnarmedItemsAsUnarmed()) {
|
||||||
return !isMinecraftTool(item);
|
return !isMinecraftTool(item);
|
||||||
}
|
}
|
||||||
@ -143,7 +147,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is armor, false otherwise
|
* @return true if the item is armor, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isArmor(ItemStack item) {
|
public static boolean isArmor(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isArmor(item.getType());
|
return mcMMO.getMaterialMapStore().isArmor(item.getType());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -153,7 +157,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is leather armor, false otherwise
|
* @return true if the item is leather armor, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isLeatherArmor(ItemStack item) {
|
public static boolean isLeatherArmor(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isLeatherArmor(item.getType());
|
return mcMMO.getMaterialMapStore().isLeatherArmor(item.getType());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -163,7 +167,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is gold armor, false otherwise
|
* @return true if the item is gold armor, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isGoldArmor(ItemStack item) {
|
public static boolean isGoldArmor(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isGoldArmor(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isGoldArmor(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -173,7 +177,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is iron armor, false otherwise
|
* @return true if the item is iron armor, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isIronArmor(ItemStack item) {
|
public static boolean isIronArmor(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isIronArmor(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isIronArmor(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -183,7 +187,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is diamond armor, false otherwise
|
* @return true if the item is diamond armor, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isDiamondArmor(ItemStack item) {
|
public static boolean isDiamondArmor(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isDiamondArmor(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isDiamondArmor(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -201,7 +205,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is chainmail armor, false otherwise
|
* @return true if the item is chainmail armor, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isChainmailArmor(ItemStack item) {
|
public static boolean isChainmailArmor(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isChainmailArmor(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isChainmailArmor(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -211,7 +215,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a tool, false otherwise
|
* @return true if the item is a tool, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isMinecraftTool(ItemStack item) {
|
public static boolean isMinecraftTool(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isTool(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isTool(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -221,7 +225,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a stone tool, false otherwise
|
* @return true if the item is a stone tool, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isStoneTool(ItemStack item) {
|
public static boolean isStoneTool(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isStoneTool(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isStoneTool(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -231,7 +235,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a wooden tool, false otherwise
|
* @return true if the item is a wooden tool, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isWoodTool(ItemStack item) {
|
public static boolean isWoodTool(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isWoodTool(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isWoodTool(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -241,7 +245,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a string tool, false otherwise
|
* @return true if the item is a string tool, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isStringTool(ItemStack item) {
|
public static boolean isStringTool(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isStringTool(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isStringTool(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -251,7 +255,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a stone tool, false otherwise
|
* @return true if the item is a stone tool, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isGoldTool(ItemStack item) {
|
public static boolean isGoldTool(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isGoldTool(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isGoldTool(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -261,7 +265,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is an iron tool, false otherwise
|
* @return true if the item is an iron tool, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isIronTool(ItemStack item) {
|
public static boolean isIronTool(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isIronTool(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isIronTool(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -271,7 +275,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a diamond tool, false otherwise
|
* @return true if the item is a diamond tool, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isDiamondTool(ItemStack item) {
|
public static boolean isDiamondTool(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isDiamondTool(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isDiamondTool(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -281,15 +285,15 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is enchantable, false otherwise
|
* @return true if the item is enchantable, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isEnchantable(ItemStack item) {
|
public static boolean isEnchantable(@NotNull ItemStack item) {
|
||||||
return mcMMO.getMaterialMapStore().isEnchantable(item.getType().getKey().getKey());
|
return mcMMO.getMaterialMapStore().isEnchantable(item.getType().getKey().getKey());
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isSmeltable(ItemStack item) {
|
public static boolean isSmeltable(@NotNull ItemStack item) {
|
||||||
return item != null && item.getType().isBlock() && MaterialUtils.isOre(item.getType());
|
return item != null && item.getType().isBlock() && MaterialUtils.isOre(item.getType());
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isSmelted(ItemStack item) {
|
public static boolean isSmelted(@NotNull ItemStack item) {
|
||||||
if (item == null) {
|
if (item == null) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -311,7 +315,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item that will get shared
|
* @param item Item that will get shared
|
||||||
* @return True if the item can be shared.
|
* @return True if the item can be shared.
|
||||||
*/
|
*/
|
||||||
public static boolean isSharable(ItemStack item) {
|
public static boolean isSharable(@NotNull ItemStack item) {
|
||||||
if (item == null || item.getType() == AIR) {
|
if (item == null || item.getType() == AIR) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -325,7 +329,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a mining drop, false otherwise
|
* @return true if the item is a mining drop, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isMiningDrop(ItemStack item) {
|
public static boolean isMiningDrop(@NotNull ItemStack item) {
|
||||||
//TODO: 1.14 This needs to be updated
|
//TODO: 1.14 This needs to be updated
|
||||||
switch (item.getType()) {
|
switch (item.getType()) {
|
||||||
case COAL:
|
case COAL:
|
||||||
@ -356,7 +360,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a herbalism drop, false otherwise
|
* @return true if the item is a herbalism drop, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isHerbalismDrop(ItemStack item) {
|
public static boolean isHerbalismDrop(@NotNull ItemStack item) {
|
||||||
//TODO: 1.14 This needs to be updated
|
//TODO: 1.14 This needs to be updated
|
||||||
switch (item.getType()) {
|
switch (item.getType()) {
|
||||||
case WHEAT:
|
case WHEAT:
|
||||||
@ -395,7 +399,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a mob drop, false otherwise
|
* @return true if the item is a mob drop, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isMobDrop(ItemStack item) {
|
public static boolean isMobDrop(@NotNull ItemStack item) {
|
||||||
//TODO: 1.14 This needs to be updated
|
//TODO: 1.14 This needs to be updated
|
||||||
switch (item.getType()) {
|
switch (item.getType()) {
|
||||||
case STRING:
|
case STRING:
|
||||||
@ -453,7 +457,7 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a woodcutting drop, false otherwise
|
* @return true if the item is a woodcutting drop, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isWoodcuttingDrop(ItemStack item) {
|
public static boolean isWoodcuttingDrop(@NotNull ItemStack item) {
|
||||||
switch (item.getType()) {
|
switch (item.getType()) {
|
||||||
case ACACIA_LOG:
|
case ACACIA_LOG:
|
||||||
case BIRCH_LOG:
|
case BIRCH_LOG:
|
||||||
@ -493,11 +497,11 @@ public final class ItemUtils {
|
|||||||
* @param item Item to check
|
* @param item Item to check
|
||||||
* @return true if the item is a miscellaneous drop, false otherwise
|
* @return true if the item is a miscellaneous drop, false otherwise
|
||||||
*/
|
*/
|
||||||
public static boolean isMiscDrop(ItemStack item) {
|
public static boolean isMiscDrop(@NotNull ItemStack item) {
|
||||||
return ItemWeightConfig.getInstance().getMiscItems().contains(item.getType());
|
return ItemWeightConfig.getInstance().getMiscItems().contains(item.getType());
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isMcMMOItem(ItemStack item) {
|
public static boolean isMcMMOItem(@NotNull ItemStack item) {
|
||||||
if (!item.hasItemMeta()) {
|
if (!item.hasItemMeta()) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -511,7 +515,7 @@ public final class ItemUtils {
|
|||||||
&& itemMeta.getLore().contains("mcMMO Item");
|
&& itemMeta.getLore().contains("mcMMO Item");
|
||||||
}
|
}
|
||||||
|
|
||||||
public static boolean isChimaeraWing(ItemStack item) {
|
public static boolean isChimaeraWing(@NotNull ItemStack item) {
|
||||||
if (!isMcMMOItem(item)) {
|
if (!isMcMMOItem(item)) {
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
@ -523,4 +527,54 @@ public final class ItemUtils {
|
|||||||
|
|
||||||
return itemMeta.hasDisplayName() && itemMeta.getDisplayName().equals(ChatColor.GOLD + LocaleLoader.getString("Item.ChimaeraWing.Name"));
|
return itemMeta.hasDisplayName() && itemMeta.getDisplayName().equals(ChatColor.GOLD + LocaleLoader.getString("Item.ChimaeraWing.Name"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// public static void addAbilityLore(@NotNull ItemStack itemStack) {
|
||||||
|
// ItemMeta itemMeta = itemStack.getItemMeta();
|
||||||
|
// List<String> itemLore = new ArrayList<>();
|
||||||
|
//
|
||||||
|
// if(itemMeta == null)
|
||||||
|
// return;
|
||||||
|
//
|
||||||
|
// if (itemMeta.hasLore()) {
|
||||||
|
// itemLore = itemMeta.getLore();
|
||||||
|
// }
|
||||||
|
//
|
||||||
|
// itemLore.add("mcMMO Ability Tool");
|
||||||
|
//
|
||||||
|
// itemMeta.setLore(itemLore);
|
||||||
|
// itemStack.setItemMeta(itemMeta);
|
||||||
|
// }
|
||||||
|
|
||||||
|
public static void removeAbilityLore(@NotNull ItemStack itemStack) {
|
||||||
|
ItemMeta itemMeta = itemStack.getItemMeta();
|
||||||
|
|
||||||
|
if(itemMeta == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
if (itemMeta.hasLore()) {
|
||||||
|
List<String> itemLore = itemMeta.getLore();
|
||||||
|
|
||||||
|
if(itemLore == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
if (itemLore.remove("mcMMO Ability Tool")) {
|
||||||
|
itemMeta.setLore(itemLore);
|
||||||
|
itemStack.setItemMeta(itemMeta);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
public static void addDigSpeedToItem(@NotNull ItemStack itemStack, int existingEnchantLevel) {
|
||||||
|
ItemMeta itemMeta = itemStack.getItemMeta();
|
||||||
|
|
||||||
|
if(itemMeta == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
itemMeta.addEnchant(Enchantment.DIG_SPEED, existingEnchantLevel + AdvancedConfig.getInstance().getEnchantBuff(), true);
|
||||||
|
itemStack.setItemMeta(itemMeta);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static boolean canBeSuperAbilityDigBoosted(@NotNull ItemStack itemStack) {
|
||||||
|
return isShovel(itemStack) || isPickaxe(itemStack);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -1,19 +1,59 @@
|
|||||||
package com.gmail.nossr50.util.compat.layers.persistentdata;
|
package com.gmail.nossr50.util.compat.layers.persistentdata;
|
||||||
|
|
||||||
|
import com.gmail.nossr50.mcMMO;
|
||||||
import com.gmail.nossr50.util.compat.layers.AbstractCompatibilityLayer;
|
import com.gmail.nossr50.util.compat.layers.AbstractCompatibilityLayer;
|
||||||
|
import org.bukkit.NamespacedKey;
|
||||||
import org.bukkit.block.Furnace;
|
import org.bukkit.block.Furnace;
|
||||||
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
import org.bukkit.inventory.meta.ItemMeta;
|
||||||
|
import org.jetbrains.annotations.NotNull;
|
||||||
import org.jetbrains.annotations.Nullable;
|
import org.jetbrains.annotations.Nullable;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
|
||||||
public abstract class AbstractPersistentDataLayer extends AbstractCompatibilityLayer {
|
public abstract class AbstractPersistentDataLayer extends AbstractCompatibilityLayer {
|
||||||
|
|
||||||
|
public static final String LEGACY_ABILITY_TOOL_LORE = "mcMMO Ability Tool";
|
||||||
|
public final NamespacedKey superAbilityBoosted;
|
||||||
|
public final String SUPER_ABILITY_BOOSTED = "super_ability_boosted";
|
||||||
|
|
||||||
public AbstractPersistentDataLayer() {
|
public AbstractPersistentDataLayer() {
|
||||||
|
superAbilityBoosted = getNamespacedKey(SUPER_ABILITY_BOOSTED);
|
||||||
initializeLayer();
|
initializeLayer();
|
||||||
}
|
}
|
||||||
|
|
||||||
public abstract @Nullable UUID getFurnaceOwner(Furnace furnace);
|
public @NotNull NamespacedKey getNamespacedKey(@NotNull String key) {
|
||||||
|
return new NamespacedKey(mcMMO.p, key);
|
||||||
|
}
|
||||||
|
|
||||||
public abstract void setFurnaceOwner(Furnace furnace, UUID uuid);
|
public abstract @Nullable UUID getFurnaceOwner(@NotNull Furnace furnace);
|
||||||
|
|
||||||
|
public abstract void setFurnaceOwner(@NotNull Furnace furnace, @NotNull UUID uuid);
|
||||||
|
|
||||||
|
public abstract void setSuperAbilityBoostedItem(@NotNull ItemStack itemStack, int originalDigSpeed);
|
||||||
|
|
||||||
|
public abstract boolean isSuperAbilityBoosted(@NotNull ItemStack itemStack);
|
||||||
|
|
||||||
|
public abstract int getSuperAbilityToolOriginalDigSpeed(@NotNull ItemStack itemStack);
|
||||||
|
|
||||||
|
public abstract void removeBonusDigSpeedOnSuperAbilityTool(@NotNull ItemStack itemStack);
|
||||||
|
|
||||||
|
public boolean isLegacyAbilityTool(ItemStack itemStack) {
|
||||||
|
ItemMeta itemMeta = itemStack.getItemMeta();
|
||||||
|
|
||||||
|
if(itemMeta == null)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
List<String> lore = itemMeta.getLore();
|
||||||
|
|
||||||
|
if(lore == null || lore.isEmpty())
|
||||||
|
return false;
|
||||||
|
|
||||||
|
return lore.contains(LEGACY_ABILITY_TOOL_LORE);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static String getLegacyAbilityToolLore() {
|
||||||
|
return LEGACY_ABILITY_TOOL_LORE;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -3,6 +3,9 @@ package com.gmail.nossr50.util.compat.layers.persistentdata;
|
|||||||
import com.gmail.nossr50.mcMMO;
|
import com.gmail.nossr50.mcMMO;
|
||||||
import org.bukkit.NamespacedKey;
|
import org.bukkit.NamespacedKey;
|
||||||
import org.bukkit.block.Furnace;
|
import org.bukkit.block.Furnace;
|
||||||
|
import org.bukkit.enchantments.Enchantment;
|
||||||
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
import org.bukkit.inventory.meta.ItemMeta;
|
||||||
import org.bukkit.persistence.PersistentDataContainer;
|
import org.bukkit.persistence.PersistentDataContainer;
|
||||||
import org.bukkit.persistence.PersistentDataHolder;
|
import org.bukkit.persistence.PersistentDataHolder;
|
||||||
import org.bukkit.persistence.PersistentDataType;
|
import org.bukkit.persistence.PersistentDataType;
|
||||||
@ -13,6 +16,12 @@ import java.util.UUID;
|
|||||||
|
|
||||||
public class SpigotPersistentDataLayer extends AbstractPersistentDataLayer {
|
public class SpigotPersistentDataLayer extends AbstractPersistentDataLayer {
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Don't modify these keys
|
||||||
|
*/
|
||||||
|
public static final String FURNACE_UUID_MOST_SIG = "furnace_uuid_most_sig";
|
||||||
|
public static final String FURNACE_UUID_LEAST_SIG = "furnace_uuid_least_sig";
|
||||||
|
|
||||||
private NamespacedKey furnaceOwner_MostSig_Key;
|
private NamespacedKey furnaceOwner_MostSig_Key;
|
||||||
private NamespacedKey furnaceOwner_LeastSig_Key;
|
private NamespacedKey furnaceOwner_LeastSig_Key;
|
||||||
|
|
||||||
@ -23,17 +32,12 @@ public class SpigotPersistentDataLayer extends AbstractPersistentDataLayer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
private void initNamespacedKeys() {
|
private void initNamespacedKeys() {
|
||||||
furnaceOwner_MostSig_Key = getNamespacedKey("furnace_uuid_most_sig");
|
furnaceOwner_MostSig_Key = getNamespacedKey(FURNACE_UUID_MOST_SIG);
|
||||||
furnaceOwner_LeastSig_Key = getNamespacedKey("furnace_uuid_least_sig");
|
furnaceOwner_LeastSig_Key = getNamespacedKey(FURNACE_UUID_LEAST_SIG);
|
||||||
}
|
|
||||||
|
|
||||||
@NotNull
|
|
||||||
public NamespacedKey getNamespacedKey(String key) {
|
|
||||||
return new NamespacedKey(mcMMO.p, key);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public @Nullable UUID getFurnaceOwner(Furnace furnace) {
|
public @Nullable UUID getFurnaceOwner(@NotNull Furnace furnace) {
|
||||||
//Get container from entity
|
//Get container from entity
|
||||||
PersistentDataContainer dataContainer = ((PersistentDataHolder) furnace).getPersistentDataContainer();
|
PersistentDataContainer dataContainer = ((PersistentDataHolder) furnace).getPersistentDataContainer();
|
||||||
|
|
||||||
@ -49,7 +53,7 @@ public class SpigotPersistentDataLayer extends AbstractPersistentDataLayer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void setFurnaceOwner(Furnace furnace, UUID uuid) {
|
public void setFurnaceOwner(@NotNull Furnace furnace, @NotNull UUID uuid) {
|
||||||
PersistentDataContainer dataContainer = ((PersistentDataHolder) furnace).getPersistentDataContainer();
|
PersistentDataContainer dataContainer = ((PersistentDataHolder) furnace).getPersistentDataContainer();
|
||||||
|
|
||||||
dataContainer.set(furnaceOwner_MostSig_Key, PersistentDataType.LONG, uuid.getMostSignificantBits());
|
dataContainer.set(furnaceOwner_MostSig_Key, PersistentDataType.LONG, uuid.getMostSignificantBits());
|
||||||
@ -57,4 +61,75 @@ public class SpigotPersistentDataLayer extends AbstractPersistentDataLayer {
|
|||||||
|
|
||||||
furnace.update();
|
furnace.update();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setSuperAbilityBoostedItem(@NotNull ItemStack itemStack, int originalDigSpeed) {
|
||||||
|
if(itemStack.getItemMeta() == null) {
|
||||||
|
mcMMO.p.getLogger().severe("Can not assign persistent data to an item with null item metadata");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
ItemMeta itemMeta = itemStack.getItemMeta();
|
||||||
|
PersistentDataContainer dataContainer = itemMeta.getPersistentDataContainer();
|
||||||
|
|
||||||
|
dataContainer.set(superAbilityBoosted, PersistentDataType.INTEGER, originalDigSpeed);
|
||||||
|
|
||||||
|
itemStack.setItemMeta(itemMeta);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isSuperAbilityBoosted(@NotNull ItemStack itemStack) {
|
||||||
|
if(itemStack.getItemMeta() == null)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
ItemMeta itemMeta = itemStack.getItemMeta();
|
||||||
|
//Get container from entity
|
||||||
|
PersistentDataContainer dataContainer = itemMeta.getPersistentDataContainer();
|
||||||
|
|
||||||
|
//If this value isn't null, then the tool can be considered dig speed boosted
|
||||||
|
Integer boostValue = dataContainer.get(superAbilityBoosted, PersistentDataType.INTEGER);
|
||||||
|
|
||||||
|
return boostValue != null;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getSuperAbilityToolOriginalDigSpeed(@NotNull ItemStack itemStack) {
|
||||||
|
//Get container from entity
|
||||||
|
ItemMeta itemMeta = itemStack.getItemMeta();
|
||||||
|
|
||||||
|
if(itemMeta == null)
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
PersistentDataContainer dataContainer = itemMeta.getPersistentDataContainer();
|
||||||
|
|
||||||
|
if(dataContainer.get(superAbilityBoosted, PersistentDataType.INTEGER) == null) {
|
||||||
|
mcMMO.p.getLogger().severe("Value should never be null for a boosted item");
|
||||||
|
return 0;
|
||||||
|
} else {
|
||||||
|
//Too lazy to make a custom data type for this stuff
|
||||||
|
Integer boostValue = dataContainer.get(superAbilityBoosted, PersistentDataType.INTEGER);
|
||||||
|
return Math.max(boostValue, 0);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void removeBonusDigSpeedOnSuperAbilityTool(@NotNull ItemStack itemStack) {
|
||||||
|
int originalSpeed = getSuperAbilityToolOriginalDigSpeed(itemStack);
|
||||||
|
ItemMeta itemMeta = itemStack.getItemMeta();
|
||||||
|
|
||||||
|
//TODO: can be optimized
|
||||||
|
if(itemMeta.hasEnchant(Enchantment.DIG_SPEED)) {
|
||||||
|
itemMeta.removeEnchant(Enchantment.DIG_SPEED);
|
||||||
|
}
|
||||||
|
|
||||||
|
if(originalSpeed > 0) {
|
||||||
|
itemMeta.addEnchant(Enchantment.DIG_SPEED, originalSpeed, true);
|
||||||
|
}
|
||||||
|
|
||||||
|
PersistentDataContainer dataContainer = itemMeta.getPersistentDataContainer();
|
||||||
|
dataContainer.remove(superAbilityBoosted); //Remove persistent data
|
||||||
|
|
||||||
|
//TODO: needed?
|
||||||
|
itemStack.setItemMeta(itemMeta);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -3,7 +3,13 @@ package com.gmail.nossr50.util.compat.layers.persistentdata;
|
|||||||
import com.gmail.nossr50.datatypes.meta.UUIDMeta;
|
import com.gmail.nossr50.datatypes.meta.UUIDMeta;
|
||||||
import com.gmail.nossr50.mcMMO;
|
import com.gmail.nossr50.mcMMO;
|
||||||
import org.bukkit.block.Furnace;
|
import org.bukkit.block.Furnace;
|
||||||
|
import org.bukkit.enchantments.Enchantment;
|
||||||
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
import org.bukkit.inventory.meta.ItemMeta;
|
||||||
|
import org.bukkit.inventory.meta.tags.CustomItemTagContainer;
|
||||||
|
import org.bukkit.inventory.meta.tags.ItemTagType;
|
||||||
import org.bukkit.metadata.Metadatable;
|
import org.bukkit.metadata.Metadatable;
|
||||||
|
import org.jetbrains.annotations.NotNull;
|
||||||
|
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
|
|
||||||
@ -20,7 +26,7 @@ public class SpigotTemporaryDataLayer extends AbstractPersistentDataLayer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public UUID getFurnaceOwner(Furnace furnace) {
|
public UUID getFurnaceOwner(@NotNull Furnace furnace) {
|
||||||
Metadatable metadatable = (Metadatable) furnace;
|
Metadatable metadatable = (Metadatable) furnace;
|
||||||
|
|
||||||
if(metadatable.getMetadata(FURNACE_OWNER_METADATA_KEY).size() > 0) {
|
if(metadatable.getMetadata(FURNACE_OWNER_METADATA_KEY).size() > 0) {
|
||||||
@ -32,7 +38,7 @@ public class SpigotTemporaryDataLayer extends AbstractPersistentDataLayer {
|
|||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void setFurnaceOwner(Furnace furnace, UUID uuid) {
|
public void setFurnaceOwner(@NotNull Furnace furnace, @NotNull UUID uuid) {
|
||||||
Metadatable metadatable = (Metadatable) furnace;
|
Metadatable metadatable = (Metadatable) furnace;
|
||||||
|
|
||||||
if(metadatable.getMetadata(FURNACE_OWNER_METADATA_KEY).size() > 0) {
|
if(metadatable.getMetadata(FURNACE_OWNER_METADATA_KEY).size() > 0) {
|
||||||
@ -41,4 +47,65 @@ public class SpigotTemporaryDataLayer extends AbstractPersistentDataLayer {
|
|||||||
|
|
||||||
metadatable.setMetadata(FURNACE_OWNER_METADATA_KEY, new UUIDMeta(mcMMO.p, uuid));
|
metadatable.setMetadata(FURNACE_OWNER_METADATA_KEY, new UUIDMeta(mcMMO.p, uuid));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void setSuperAbilityBoostedItem(@NotNull ItemStack itemStack, int originalDigSpeed) {
|
||||||
|
ItemMeta itemMeta = itemStack.getItemMeta();
|
||||||
|
|
||||||
|
if(itemMeta == null) {
|
||||||
|
mcMMO.p.getLogger().severe("Item meta should never be null for a super boosted item!");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
itemMeta.getCustomTagContainer().setCustomTag(superAbilityBoosted, ItemTagType.INTEGER, originalDigSpeed);
|
||||||
|
itemStack.setItemMeta(itemMeta);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public boolean isSuperAbilityBoosted(@NotNull ItemStack itemStack) {
|
||||||
|
ItemMeta itemMeta = itemStack.getItemMeta();
|
||||||
|
|
||||||
|
if(itemMeta == null)
|
||||||
|
return false;
|
||||||
|
|
||||||
|
CustomItemTagContainer tagContainer = itemMeta.getCustomTagContainer();
|
||||||
|
return tagContainer.hasCustomTag(superAbilityBoosted, ItemTagType.INTEGER);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getSuperAbilityToolOriginalDigSpeed(@NotNull ItemStack itemStack) {
|
||||||
|
ItemMeta itemMeta = itemStack.getItemMeta();
|
||||||
|
|
||||||
|
if(itemMeta == null)
|
||||||
|
return 0;
|
||||||
|
|
||||||
|
CustomItemTagContainer tagContainer = itemMeta.getCustomTagContainer();
|
||||||
|
|
||||||
|
if(tagContainer.hasCustomTag(superAbilityBoosted , ItemTagType.INTEGER)) {
|
||||||
|
return tagContainer.getCustomTag(superAbilityBoosted, ItemTagType.INTEGER);
|
||||||
|
} else {
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void removeBonusDigSpeedOnSuperAbilityTool(@NotNull ItemStack itemStack) {
|
||||||
|
int originalSpeed = getSuperAbilityToolOriginalDigSpeed(itemStack);
|
||||||
|
ItemMeta itemMeta = itemStack.getItemMeta();
|
||||||
|
|
||||||
|
if(itemMeta == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
if(itemMeta.hasEnchant(Enchantment.DIG_SPEED)) {
|
||||||
|
itemMeta.removeEnchant(Enchantment.DIG_SPEED);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
if(originalSpeed > 0) {
|
||||||
|
itemMeta.addEnchant(Enchantment.DIG_SPEED, originalSpeed, true);
|
||||||
|
}
|
||||||
|
|
||||||
|
//TODO: needed?
|
||||||
|
itemStack.setItemMeta(itemMeta);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -208,7 +208,7 @@ public final class CombatUtils {
|
|||||||
|
|
||||||
//Only execute bonuses if the player is not spamming
|
//Only execute bonuses if the player is not spamming
|
||||||
if (unarmedManager.canUseIronArm()) {
|
if (unarmedManager.canUseIronArm()) {
|
||||||
finalDamage+=(unarmedManager.calculateIronArmDamage() * mmoPlayer.getAttackStrength());
|
finalDamage+=(unarmedManager.calculateSteelArmStyleDamage() * mmoPlayer.getAttackStrength());
|
||||||
}
|
}
|
||||||
|
|
||||||
if (unarmedManager.canUseBerserk()) {
|
if (unarmedManager.canUseBerserk()) {
|
||||||
|
@ -16,6 +16,7 @@ import com.gmail.nossr50.util.ItemUtils;
|
|||||||
import com.gmail.nossr50.util.Misc;
|
import com.gmail.nossr50.util.Misc;
|
||||||
import com.gmail.nossr50.util.StringUtils;
|
import com.gmail.nossr50.util.StringUtils;
|
||||||
import com.gmail.nossr50.util.experience.MMOExperienceBarManager;
|
import com.gmail.nossr50.util.experience.MMOExperienceBarManager;
|
||||||
|
import com.gmail.nossr50.util.compat.layers.persistentdata.AbstractPersistentDataLayer;
|
||||||
import com.gmail.nossr50.util.player.NotificationManager;
|
import com.gmail.nossr50.util.player.NotificationManager;
|
||||||
import org.bukkit.Bukkit;
|
import org.bukkit.Bukkit;
|
||||||
import org.bukkit.Location;
|
import org.bukkit.Location;
|
||||||
@ -29,10 +30,10 @@ import org.bukkit.inventory.ShapelessRecipe;
|
|||||||
import org.bukkit.inventory.meta.ItemMeta;
|
import org.bukkit.inventory.meta.ItemMeta;
|
||||||
import org.bukkit.potion.PotionEffect;
|
import org.bukkit.potion.PotionEffect;
|
||||||
import org.bukkit.potion.PotionEffectType;
|
import org.bukkit.potion.PotionEffectType;
|
||||||
|
import org.jetbrains.annotations.NotNull;
|
||||||
|
import org.jetbrains.annotations.Nullable;
|
||||||
|
|
||||||
import java.util.ArrayList;
|
|
||||||
import java.util.Iterator;
|
import java.util.Iterator;
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
public class SkillUtils {
|
public class SkillUtils {
|
||||||
|
|
||||||
@ -147,23 +148,24 @@ public class SkillUtils {
|
|||||||
if (HiddenConfig.getInstance().useEnchantmentBuffs()) {
|
if (HiddenConfig.getInstance().useEnchantmentBuffs()) {
|
||||||
ItemStack heldItem = player.getInventory().getItemInMainHand();
|
ItemStack heldItem = player.getInventory().getItemInMainHand();
|
||||||
|
|
||||||
if (heldItem == null || heldItem.getType() == Material.AIR) {
|
if(heldItem == null)
|
||||||
|
return;
|
||||||
|
|
||||||
|
if (!ItemUtils.canBeSuperAbilityDigBoosted(heldItem)) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
int efficiencyLevel = heldItem.getEnchantmentLevel(Enchantment.DIG_SPEED);
|
int originalDigSpeed = heldItem.getEnchantmentLevel(Enchantment.DIG_SPEED);
|
||||||
ItemMeta itemMeta = heldItem.getItemMeta();
|
|
||||||
List<String> itemLore = new ArrayList<>();
|
|
||||||
|
|
||||||
if (itemMeta.hasLore()) {
|
//Add dig speed
|
||||||
itemLore = itemMeta.getLore();
|
|
||||||
}
|
|
||||||
|
|
||||||
itemLore.add("mcMMO Ability Tool");
|
//Lore no longer gets added, no point to it afaik
|
||||||
itemMeta.addEnchant(Enchantment.DIG_SPEED, efficiencyLevel + AdvancedConfig.getInstance().getEnchantBuff(), true);
|
//ItemUtils.addAbilityLore(heldItem); //lore can be a secondary failsafe for 1.13 and below
|
||||||
|
ItemUtils.addDigSpeedToItem(heldItem, heldItem.getEnchantmentLevel(Enchantment.DIG_SPEED));
|
||||||
|
|
||||||
itemMeta.setLore(itemLore);
|
//1.13.2+ will have persistent metadata for this item
|
||||||
heldItem.setItemMeta(itemMeta);
|
AbstractPersistentDataLayer compatLayer = mcMMO.getCompatibilityManager().getPersistentDataLayer();
|
||||||
|
compatLayer.setSuperAbilityBoostedItem(heldItem, originalDigSpeed);
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
int duration = 0;
|
int duration = 0;
|
||||||
@ -206,39 +208,41 @@ public class SkillUtils {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void handleAbilitySpeedDecrease(Player player) {
|
public static void removeAbilityBoostsFromInventory(@NotNull Player player) {
|
||||||
if (!HiddenConfig.getInstance().useEnchantmentBuffs()) {
|
if (!HiddenConfig.getInstance().useEnchantmentBuffs()) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
for (ItemStack item : player.getInventory().getContents()) {
|
for (ItemStack itemStack : player.getInventory().getContents()) {
|
||||||
removeAbilityBuff(item);
|
removeAbilityBuff(itemStack);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void removeAbilityBuff(ItemStack item) {
|
public static void removeAbilityBuff(@Nullable ItemStack itemStack) {
|
||||||
if (item == null || item.getType() == Material.AIR || (!ItemUtils.isPickaxe(item) && !ItemUtils.isShovel(item)) || !item.containsEnchantment(Enchantment.DIG_SPEED)) {
|
if(itemStack == null)
|
||||||
return;
|
return;
|
||||||
|
|
||||||
|
if(!ItemUtils.canBeSuperAbilityDigBoosted(itemStack))
|
||||||
|
return;
|
||||||
|
|
||||||
|
|
||||||
|
//1.13.2+ will have persistent metadata for this itemStack
|
||||||
|
AbstractPersistentDataLayer compatLayer = mcMMO.getCompatibilityManager().getPersistentDataLayer();
|
||||||
|
|
||||||
|
if(compatLayer.isLegacyAbilityTool(itemStack)) {
|
||||||
|
ItemMeta itemMeta = itemStack.getItemMeta();
|
||||||
|
|
||||||
|
//TODO: can be optimized
|
||||||
|
if(itemMeta.hasEnchant(Enchantment.DIG_SPEED)) {
|
||||||
|
itemMeta.removeEnchant(Enchantment.DIG_SPEED);
|
||||||
|
}
|
||||||
|
|
||||||
|
itemStack.setItemMeta(itemMeta);
|
||||||
|
ItemUtils.removeAbilityLore(itemStack);
|
||||||
}
|
}
|
||||||
|
|
||||||
ItemMeta itemMeta = item.getItemMeta();
|
if(compatLayer.isSuperAbilityBoosted(itemStack)) {
|
||||||
|
compatLayer.removeBonusDigSpeedOnSuperAbilityTool(itemStack);
|
||||||
if (itemMeta.hasLore()) {
|
|
||||||
List<String> itemLore = itemMeta.getLore();
|
|
||||||
|
|
||||||
if (itemLore.remove("mcMMO Ability Tool")) {
|
|
||||||
int efficiencyLevel = item.getEnchantmentLevel(Enchantment.DIG_SPEED);
|
|
||||||
|
|
||||||
if (efficiencyLevel <= AdvancedConfig.getInstance().getEnchantBuff()) {
|
|
||||||
itemMeta.removeEnchant(Enchantment.DIG_SPEED);
|
|
||||||
}
|
|
||||||
else {
|
|
||||||
itemMeta.addEnchant(Enchantment.DIG_SPEED, efficiencyLevel - AdvancedConfig.getInstance().getEnchantBuff(), true);
|
|
||||||
}
|
|
||||||
|
|
||||||
itemMeta.setLore(itemLore);
|
|
||||||
item.setItemMeta(itemMeta);
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -495,7 +495,7 @@ Taming.Summon.COTW.BreedingDisallowed=[[GREEN]](Call Of The Wild) [[RED]]You can
|
|||||||
Taming.Summon.COTW.NeedMoreItems=[[GREEN]](Call Of The Wild) [[GRAY]]You need [[YELLOW]]{0}[[GRAY]] more [[DARK_AQUA]]{1}[[GRAY]](s)
|
Taming.Summon.COTW.NeedMoreItems=[[GREEN]](Call Of The Wild) [[GRAY]]You need [[YELLOW]]{0}[[GRAY]] more [[DARK_AQUA]]{1}[[GRAY]](s)
|
||||||
Taming.Summon.Name.Format=[[GOLD]](COTW) [[WHITE]]{0}'s {1}
|
Taming.Summon.Name.Format=[[GOLD]](COTW) [[WHITE]]{0}'s {1}
|
||||||
#UNARMED
|
#UNARMED
|
||||||
Unarmed.Ability.Bonus.0=Iron Arm Style
|
Unarmed.Ability.Bonus.0=Steel Arm Style
|
||||||
Unarmed.Ability.Bonus.1=+{0} DMG Upgrade
|
Unarmed.Ability.Bonus.1=+{0} DMG Upgrade
|
||||||
Unarmed.Ability.IronGrip.Attacker=Your opponent has an iron grip!
|
Unarmed.Ability.IronGrip.Attacker=Your opponent has an iron grip!
|
||||||
Unarmed.Ability.IronGrip.Defender=[[GREEN]]Your iron grip kept you from being disarmed!
|
Unarmed.Ability.IronGrip.Defender=[[GREEN]]Your iron grip kept you from being disarmed!
|
||||||
@ -510,8 +510,8 @@ Unarmed.SubSkill.Disarm.Stat=Disarm Chance
|
|||||||
Unarmed.SubSkill.UnarmedLimitBreak.Name=Unarmed Limit Break
|
Unarmed.SubSkill.UnarmedLimitBreak.Name=Unarmed Limit Break
|
||||||
Unarmed.SubSkill.UnarmedLimitBreak.Description=Breaking your limits. Increased damage against tough opponents. Intended for PVP, up to server settings for whether or not it will boost damage in PVE.
|
Unarmed.SubSkill.UnarmedLimitBreak.Description=Breaking your limits. Increased damage against tough opponents. Intended for PVP, up to server settings for whether or not it will boost damage in PVE.
|
||||||
Unarmed.SubSkill.UnarmedLimitBreak.Stat=Limit Break Max DMG
|
Unarmed.SubSkill.UnarmedLimitBreak.Stat=Limit Break Max DMG
|
||||||
Unarmed.SubSkill.IronArmStyle.Name=Iron Arm Style
|
Unarmed.SubSkill.SteelArmStyle.Name=Steel Arm Style
|
||||||
Unarmed.SubSkill.IronArmStyle.Description=Hardens your arm over time
|
Unarmed.SubSkill.SteelArmStyle.Description=Hardens your arm over time
|
||||||
Unarmed.SubSkill.ArrowDeflect.Name=Arrow Deflect
|
Unarmed.SubSkill.ArrowDeflect.Name=Arrow Deflect
|
||||||
Unarmed.SubSkill.ArrowDeflect.Description=Deflect arrows
|
Unarmed.SubSkill.ArrowDeflect.Description=Deflect arrows
|
||||||
Unarmed.SubSkill.ArrowDeflect.Stat=Arrow Deflect Chance
|
Unarmed.SubSkill.ArrowDeflect.Stat=Arrow Deflect Chance
|
||||||
@ -975,7 +975,7 @@ Guides.Taming.Section.8=[[DARK_AQUA]]How does Fast Food Service work?\n[[YELLOW]
|
|||||||
##Unarmed
|
##Unarmed
|
||||||
Guides.Unarmed.Section.0=[[DARK_AQUA]]About Unarmed:\n[[YELLOW]]Unarmed will give players various combat bonuses when using\n[[YELLOW]]your fists as a weapon. \n\n[[DARK_AQUA]]XP GAIN:\n[[YELLOW]]XP is gained based on the amount of damage dealt to mobs \n[[YELLOW]]or other players when unarmed.
|
Guides.Unarmed.Section.0=[[DARK_AQUA]]About Unarmed:\n[[YELLOW]]Unarmed will give players various combat bonuses when using\n[[YELLOW]]your fists as a weapon. \n\n[[DARK_AQUA]]XP GAIN:\n[[YELLOW]]XP is gained based on the amount of damage dealt to mobs \n[[YELLOW]]or other players when unarmed.
|
||||||
Guides.Unarmed.Section.1=[[DARK_AQUA]]How does Berserk work?\n[[YELLOW]]Beserk is an active ability that is activated by\n[[YELLOW]]right-clicking. While in Beserk mode, you deal 50% more\n[[YELLOW]]damage and you can break weak materials instantly, such as\n[[YELLOW]]Dirt and Grass.
|
Guides.Unarmed.Section.1=[[DARK_AQUA]]How does Berserk work?\n[[YELLOW]]Beserk is an active ability that is activated by\n[[YELLOW]]right-clicking. While in Beserk mode, you deal 50% more\n[[YELLOW]]damage and you can break weak materials instantly, such as\n[[YELLOW]]Dirt and Grass.
|
||||||
Guides.Unarmed.Section.2=[[DARK_AQUA]]How does Iron Arm work?\n[[YELLOW]]Iron Arm increases the damage dealt when hitting mobs or\n[[YELLOW]]players with your fists.
|
Guides.Unarmed.Section.2=[[DARK_AQUA]]How does Steel Arm Style work?\n[[YELLOW]]Steel Arm Style increases the damage dealt when hitting mobs or\n[[YELLOW]]players with your fists.
|
||||||
Guides.Unarmed.Section.3=[[DARK_AQUA]]How does Arrow Deflect work?\n[[YELLOW]]Arrow Deflect is a passive ability that gives you a chance\n[[YELLOW]]to deflect arrows shot by Skeletons or other players.\n[[YELLOW]]The arrow will fall harmlessly to the ground.
|
Guides.Unarmed.Section.3=[[DARK_AQUA]]How does Arrow Deflect work?\n[[YELLOW]]Arrow Deflect is a passive ability that gives you a chance\n[[YELLOW]]to deflect arrows shot by Skeletons or other players.\n[[YELLOW]]The arrow will fall harmlessly to the ground.
|
||||||
Guides.Unarmed.Section.4=[[DARK_AQUA]]How does Iron Grip work?\n[[YELLOW]]Iron Grip is a passive ability that counters disarm. As your\n[[YELLOW]]unarmed level increases, the chance of preventing a disarm increases.
|
Guides.Unarmed.Section.4=[[DARK_AQUA]]How does Iron Grip work?\n[[YELLOW]]Iron Grip is a passive ability that counters disarm. As your\n[[YELLOW]]unarmed level increases, the chance of preventing a disarm increases.
|
||||||
Guides.Unarmed.Section.5=[[DARK_AQUA]]How does Disarm work?\n[[YELLOW]]This passive ability allows players to disarm other players,\n[[YELLOW]]causing the target's equipped item to fall to the ground.
|
Guides.Unarmed.Section.5=[[DARK_AQUA]]How does Disarm work?\n[[YELLOW]]This passive ability allows players to disarm other players,\n[[YELLOW]]causing the target's equipped item to fall to the ground.
|
||||||
|
@ -138,7 +138,7 @@ Acrobatics.SubSkill.Roll.Name=Gurul\u00E1s
|
|||||||
Acrobatics.SubSkill.Roll.Description=Es\u00E9s strat\u00E9gi\u00E1val cs\u00F6kkenti a sebz\u00E9st.
|
Acrobatics.SubSkill.Roll.Description=Es\u00E9s strat\u00E9gi\u00E1val cs\u00F6kkenti a sebz\u00E9st.
|
||||||
Acrobatics.SubSkill.Roll.Chance=Es\u00E9ly Gurul\u00E1sra: [[YELLOW]]{0}
|
Acrobatics.SubSkill.Roll.Chance=Es\u00E9ly Gurul\u00E1sra: [[YELLOW]]{0}
|
||||||
Acrobatics.SubSkill.Roll.GraceChance=Es\u00E9ly Kecses Gurul\u00E1sra: [[YELLOW]]{0}
|
Acrobatics.SubSkill.Roll.GraceChance=Es\u00E9ly Kecses Gurul\u00E1sra: [[YELLOW]]{0}
|
||||||
Acrobatics.SubSkill.Roll.Mechanics=[[GRAY]]A Gurul\u00E1s egy akt\u00EDv alk\u00E9pess\u00E9g passz\u00EDv komponenssel\nHa es\u00E9sk\u00E1rosod\u00E1s \u00E9r, akkor lehet\u0151s\u00E9ged van arra, hogy teljesen elutas\u00EDtsd a szakk\u00E9pzetts\u00E9gi szinteden alapul\u00F3 s\u00E9r\u00FCl\u00E9sed, az 50-es szintt\u0151l [[YELLOW]]{0}%[[GRAY]] es\u00E9lyed van a s\u00E9r\u00FCl\u00E9sek megel\u0151z\u00E9s\u00E9re, \u00E9s [[YELLOW]]{1}%[[GRAY]] ha aktiv\u00E1lod a Kecses Gurul\u00E1st.\nA siker es\u00E9lye egy line\u00E1ris g\u00F6rbe, ami a szintedhez igazodik eddig a szintig [[YELLOW]]{2}[[GRAY]], ahol az Akrobatika minden szintje add neked [[YELLOW]]{3}%[[GRAY]] es\u00E9lyt a sikerre.\nA guggol\u00E1s billenty\u0171 megnyom\u00E1s\u00E1val megdupl\u00E1zhatod az es\u00E9lyeid, hogy elker\u00FCld az es\u00E9s s\u00E9r\u00FCl\u00E9st, \u00E9s elker\u00FCld az es\u00E9s s\u00E9r\u00FCl\u00E9s k\u00E9tszeres\u00E9t! A guggol\u00E1s megtart\u00E1sa a norm\u00E1l gurul\u00E1st Kecses Gurul\u00E1ss\u00E1 alak\u00EDtja.\nA Gurul\u00E1s megakad\u00E1lyoz [[RED]]{4}[[GRAY]] s\u00E9r\u00FCl\u00E9st. A Kecses Gurul\u00E1s megakad\u00E1lyoz [[GREEN]]{5}[[GRAY]] s\u00E9r\u00FCl\u00E9st.
|
Acrobatics.SubSkill.Roll.Mechanics=[[GRAY]]A Gurul\u00E1s egy akt\u00EDv alk\u00E9pess\u00E9g passz\u00EDv komponenssel\nHa es\u00E9sk\u00E1rosod\u00E1s \u00E9r, akkor lehet\u0151s\u00E9ged van arra, hogy teljesen elutas\u00EDtsd a szakk\u00E9pzetts\u00E9gi szinteden alapul\u00F3 s\u00E9r\u00FCl\u00E9sed, az [[YELLOW]]{6}%[[GRAY]]. szintt\u0151l [[YELLOW]]{0}%[[GRAY]] es\u00E9lyed van a s\u00E9r\u00FCl\u00E9sek megel\u0151z\u00E9s\u00E9re, \u00E9s [[YELLOW]]{1}%[[GRAY]] ha aktiv\u00E1lod a Kecses Gurul\u00E1st.\nA siker es\u00E9lye egy line\u00E1ris g\u00F6rbe, ami a szintedhez igazodik eddig a szintig [[YELLOW]]{2}[[GRAY]], ahol az Akrobatika minden szintje add neked [[YELLOW]]{3}%[[GRAY]] es\u00E9lyt a sikerre.\nA guggol\u00E1s billenty\u0171 megnyom\u00E1s\u00E1val megdupl\u00E1zhatod az es\u00E9lyeid, hogy elker\u00FCld az es\u00E9s s\u00E9r\u00FCl\u00E9st, \u00E9s elker\u00FCld az es\u00E9s s\u00E9r\u00FCl\u00E9s k\u00E9tszeres\u00E9t! A guggol\u00E1s megtart\u00E1sa a norm\u00E1l gurul\u00E1st Kecses Gurul\u00E1ss\u00E1 alak\u00EDtja.\nA Gurul\u00E1s megakad\u00E1lyoz [[RED]]{4}[[GRAY]] s\u00E9r\u00FCl\u00E9st. A Kecses Gurul\u00E1s megakad\u00E1lyoz [[GREEN]]{5}[[GRAY]] s\u00E9r\u00FCl\u00E9st.
|
||||||
Acrobatics.SubSkill.GracefulRoll.Name=Kecses Gurul\u00E1s
|
Acrobatics.SubSkill.GracefulRoll.Name=Kecses Gurul\u00E1s
|
||||||
Acrobatics.SubSkill.GracefulRoll.Description=K\u00E9tszer olyan effekt\u00EDv, mint egy egyszer\u0171 Gurul\u00E1s
|
Acrobatics.SubSkill.GracefulRoll.Description=K\u00E9tszer olyan effekt\u00EDv, mint egy egyszer\u0171 Gurul\u00E1s
|
||||||
Acrobatics.SubSkill.Dodge.Name=Kit\u00E9r\u00E9s
|
Acrobatics.SubSkill.Dodge.Name=Kit\u00E9r\u00E9s
|
||||||
@ -165,8 +165,8 @@ Archery.SubSkill.SkillShot.Name=L\u00F6v\u00E9s K\u00E9pess\u00E9g
|
|||||||
Archery.SubSkill.SkillShot.Description=N\u00F6veli az \u00EDjakkal okozott sebz\u00E9st
|
Archery.SubSkill.SkillShot.Description=N\u00F6veli az \u00EDjakkal okozott sebz\u00E9st
|
||||||
Archery.SubSkill.SkillShot.Stat=K\u00E9pess\u00E9gi L\u00F6v\u00E9s B\u00F3nusz Sebz\u00E9s
|
Archery.SubSkill.SkillShot.Stat=K\u00E9pess\u00E9gi L\u00F6v\u00E9s B\u00F3nusz Sebz\u00E9s
|
||||||
Archery.SubSkill.Daze.Name=K\u00E1b\u00EDt\u00E1s
|
Archery.SubSkill.Daze.Name=K\u00E1b\u00EDt\u00E1s
|
||||||
Archery.SubSkill.Daze.Stat=Es\u00E9ly K\u00E1b\u00EDt\u00E1sra
|
|
||||||
Archery.SubSkill.Daze.Description=\u00D6sszezavarja az ellenfeleket \u00E9s extra sebz\u00E9st okoz
|
Archery.SubSkill.Daze.Description=\u00D6sszezavarja az ellenfeleket \u00E9s extra sebz\u00E9st okoz
|
||||||
|
Archery.SubSkill.Daze.Stat=Es\u00E9ly K\u00E1b\u00EDt\u00E1sra
|
||||||
Archery.SubSkill.ArrowRetrieval.Name=Nyilak Visszaszerz\u00E9se
|
Archery.SubSkill.ArrowRetrieval.Name=Nyilak Visszaszerz\u00E9se
|
||||||
Archery.SubSkill.ArrowRetrieval.Description=Es\u00E9ly a nyilak visszaszerz\u00E9sre a hull\u00E1kb\u00F3l
|
Archery.SubSkill.ArrowRetrieval.Description=Es\u00E9ly a nyilak visszaszerz\u00E9sre a hull\u00E1kb\u00F3l
|
||||||
Archery.SubSkill.ArrowRetrieval.Stat=Ny\u00EDl helyre\u00E1ll\u00EDt\u00E1si es\u00E9ly
|
Archery.SubSkill.ArrowRetrieval.Stat=Ny\u00EDl helyre\u00E1ll\u00EDt\u00E1si es\u00E9ly
|
||||||
@ -489,7 +489,7 @@ Taming.Summon.COTW.BreedingDisallowed=[[GREEN]](A Vadon Szava) [[RED]]Nem szapor
|
|||||||
Taming.Summon.COTW.NeedMoreItems=[[GREEN]](A Vadon Szava) [[GRAY]]Sz\u00FCks\u00E9g van [[YELLOW]]{0}[[GRAY]] t\u00F6bb [[DARK_AQUA]]{1}[[GRAY]](m)
|
Taming.Summon.COTW.NeedMoreItems=[[GREEN]](A Vadon Szava) [[GRAY]]Sz\u00FCks\u00E9g van [[YELLOW]]{0}[[GRAY]] t\u00F6bb [[DARK_AQUA]]{1}[[GRAY]](m)
|
||||||
Taming.Summon.Name.Format=[[GOLD]](COTW) [[WHITE]]{0} \u00E1llata {1}
|
Taming.Summon.Name.Format=[[GOLD]](COTW) [[WHITE]]{0} \u00E1llata {1}
|
||||||
#UNARMED
|
#UNARMED
|
||||||
Unarmed.Ability.Bonus.0=Vas-\u00D6k\u00F6l St\u00EDlus
|
Unarmed.Ability.Bonus.0=Ac\u00E9l-\u00D6k\u00F6l St\u00EDlus
|
||||||
Unarmed.Ability.Bonus.1=+{0} Sebz\u00E9s Fejleszt\u00E9s
|
Unarmed.Ability.Bonus.1=+{0} Sebz\u00E9s Fejleszt\u00E9s
|
||||||
Unarmed.Ability.IronGrip.Attacker=Az ellenfeled Vas-Markol\u00E1ssal rendelkezik!
|
Unarmed.Ability.IronGrip.Attacker=Az ellenfeled Vas-Markol\u00E1ssal rendelkezik!
|
||||||
Unarmed.Ability.IronGrip.Defender=[[GREEN]]A Vas-Markol\u00E1sodnak h\u00E1la nem lett\u00E9l Lefegyverezve!
|
Unarmed.Ability.IronGrip.Defender=[[GREEN]]A Vas-Markol\u00E1sodnak h\u00E1la nem lett\u00E9l Lefegyverezve!
|
||||||
@ -504,8 +504,8 @@ Unarmed.SubSkill.Disarm.Stat=Es\u00E9ly Lefegyverz\u00E9sre
|
|||||||
Unarmed.SubSkill.UnarmedLimitBreak.Name=Pusztakezek Korl\u00E1t \u00C1tl\u00E9p\u00E9s
|
Unarmed.SubSkill.UnarmedLimitBreak.Name=Pusztakezek Korl\u00E1t \u00C1tl\u00E9p\u00E9s
|
||||||
Unarmed.SubSkill.UnarmedLimitBreak.Description=L\u00E9pj t\u00FAl a korl\u00E1taidon. Megn\u00F6vekedett sebz\u00E9s a kem\u00E9ny ellenfelek ellen. A PVP-hez tervezt\u00E9k att\u00F3l f\u00FCggetlen\u00FCl, hogy a szerver be\u00E1ll\u00EDt\u00E1si n\u00F6velik-e, vagy sem a PVE sebz\u00E9st.
|
Unarmed.SubSkill.UnarmedLimitBreak.Description=L\u00E9pj t\u00FAl a korl\u00E1taidon. Megn\u00F6vekedett sebz\u00E9s a kem\u00E9ny ellenfelek ellen. A PVP-hez tervezt\u00E9k att\u00F3l f\u00FCggetlen\u00FCl, hogy a szerver be\u00E1ll\u00EDt\u00E1si n\u00F6velik-e, vagy sem a PVE sebz\u00E9st.
|
||||||
Unarmed.SubSkill.UnarmedLimitBreak.Stat=Max Sebz\u00E9s Korl\u00E1t \u00C1tl\u00E9p\u00E9ssel
|
Unarmed.SubSkill.UnarmedLimitBreak.Stat=Max Sebz\u00E9s Korl\u00E1t \u00C1tl\u00E9p\u00E9ssel
|
||||||
Unarmed.SubSkill.IronArmStyle.Name=Vas-\u00D6k\u00F6l St\u00EDlus
|
Unarmed.SubSkill.SteelArmStyle.Name=Ac\u00E9l-\u00D6k\u00F6l St\u00EDlus
|
||||||
Unarmed.SubSkill.IronArmStyle.Description=Id\u0151vel megkem\u00E9ny\u00EDti az \u00F6kleidet
|
Unarmed.SubSkill.SteelArmStyle.Description=Id\u0151vel megkem\u00E9ny\u00EDti az \u00F6kleidet
|
||||||
Unarmed.SubSkill.ArrowDeflect.Name=Nyilak Kit\u00E9r\u00EDt\u00E9se
|
Unarmed.SubSkill.ArrowDeflect.Name=Nyilak Kit\u00E9r\u00EDt\u00E9se
|
||||||
Unarmed.SubSkill.ArrowDeflect.Description=Nyilak Kit\u00E9r\u00EDt\u00E9se
|
Unarmed.SubSkill.ArrowDeflect.Description=Nyilak Kit\u00E9r\u00EDt\u00E9se
|
||||||
Unarmed.SubSkill.ArrowDeflect.Stat=Es\u00E9ly Nyilak Kit\u00E9r\u00EDt\u00E9s\u00E9re
|
Unarmed.SubSkill.ArrowDeflect.Stat=Es\u00E9ly Nyilak Kit\u00E9r\u00EDt\u00E9s\u00E9re
|
||||||
@ -699,6 +699,8 @@ Commands.Scoreboard.Help.2=[[DARK_AQUA]]/mcscoreboard[[AQUA]] keep [[WHITE]] - a
|
|||||||
Commands.Scoreboard.Help.3=[[DARK_AQUA]]/mcscoreboard[[AQUA]] time [n] [[WHITE]] - az mcMMO scoreboard elt\u00FCntet\u00E9se [[LIGHT_PURPLE]]n[[WHITE]] m\u00E1sodperc m\u00FAlva.
|
Commands.Scoreboard.Help.3=[[DARK_AQUA]]/mcscoreboard[[AQUA]] time [n] [[WHITE]] - az mcMMO scoreboard elt\u00FCntet\u00E9se [[LIGHT_PURPLE]]n[[WHITE]] m\u00E1sodperc m\u00FAlva.
|
||||||
Commands.Scoreboard.Tip.Keep=[[GOLD]]Tipp: Haszn\u00E1ld a [[RED]]/mcscoreboard keep[[GOLD]] parancsot, m\u00EDg l\u00E1that\u00F3 a scoreboard, hogy ne t\u0171nj\u00F6n el.
|
Commands.Scoreboard.Tip.Keep=[[GOLD]]Tipp: Haszn\u00E1ld a [[RED]]/mcscoreboard keep[[GOLD]] parancsot, m\u00EDg l\u00E1that\u00F3 a scoreboard, hogy ne t\u0171nj\u00F6n el.
|
||||||
Commands.Scoreboard.Tip.Clear=[[GOLD]]Tipp: Haszn\u00E1ld a [[RED]]/mcscoreboard clear[[GOLD]] parancsot, hogy elt\u00FCntesd a scoreboard-ot.
|
Commands.Scoreboard.Tip.Clear=[[GOLD]]Tipp: Haszn\u00E1ld a [[RED]]/mcscoreboard clear[[GOLD]] parancsot, hogy elt\u00FCntesd a scoreboard-ot.
|
||||||
|
Commands.XPBar.Reset=[[GOLD]]Az XP s\u00E1v be\u00E1ll\u00EDt\u00E1sok az mcMMO-hoz vissza\u00E1ll\u00EDtva.
|
||||||
|
Commands.XPBar.SettingChanged=[[GOLD]]XP s\u00E1v be\u00E1ll\u00EDt\u00E1sok [[GREEN]]{0}[[GOLD]]-nak/nek be\u00E1ll\u00EDtve erre [[GREEN]]{1}
|
||||||
Commands.Skill.Invalid=Ez nem l\u00E9tez\u0151 k\u00E9pess\u00E9g n\u00E9v!
|
Commands.Skill.Invalid=Ez nem l\u00E9tez\u0151 k\u00E9pess\u00E9g n\u00E9v!
|
||||||
Commands.Skill.ChildSkill=Alk\u00E9pess\u00E9gek nem haszn\u00E1lhat\u00F3k ehhez a parancshoz!
|
Commands.Skill.ChildSkill=Alk\u00E9pess\u00E9gek nem haszn\u00E1lhat\u00F3k ehhez a parancshoz!
|
||||||
Commands.Skill.Leaderboard=--mcMMO [[BLUE]]{0}[[YELLOW]] Toplista--
|
Commands.Skill.Leaderboard=--mcMMO [[BLUE]]{0}[[YELLOW]] Toplista--
|
||||||
@ -721,8 +723,8 @@ Commands.Usage.Skill=skill
|
|||||||
Commands.Usage.SubSkill=subskill
|
Commands.Usage.SubSkill=subskill
|
||||||
Commands.Usage.XP=xp
|
Commands.Usage.XP=xp
|
||||||
Commands.Description.mmoinfo=Olvasd el a r\u00E9szleteket a k\u00E9pess\u00E9gekr\u0151l vagy mechanik\u00E1kr\u00F3l.
|
Commands.Description.mmoinfo=Olvasd el a r\u00E9szleteket a k\u00E9pess\u00E9gekr\u0151l vagy mechanik\u00E1kr\u00F3l.
|
||||||
Commands.MmoInfo.NoMatch=Ez az alk\u00E9pess\u00E9g nem l\u00E9tezik!
|
|
||||||
Commands.MmoInfo.Mystery=[[GRAY]]M\u00E9g nem oldottad fel ezt a k\u00E9pess\u00E9get, de ha igen, akkor el tudod olvasni a r\u00E9szleteket itt!
|
Commands.MmoInfo.Mystery=[[GRAY]]M\u00E9g nem oldottad fel ezt a k\u00E9pess\u00E9get, de ha igen, akkor el tudod olvasni a r\u00E9szleteket itt!
|
||||||
|
Commands.MmoInfo.NoMatch=Ez az alk\u00E9pess\u00E9g nem l\u00E9tezik!
|
||||||
Commands.MmoInfo.Header=[[DARK_AQUA]]-=[]=====[][[GOLD]] MMO Inf\u00F3 [[DARK_AQUA]][]=====[]=-
|
Commands.MmoInfo.Header=[[DARK_AQUA]]-=[]=====[][[GOLD]] MMO Inf\u00F3 [[DARK_AQUA]][]=====[]=-
|
||||||
Commands.MmoInfo.SubSkillHeader=[[GOLD]]N\u00E9v:[[YELLOW]] {0}
|
Commands.MmoInfo.SubSkillHeader=[[GOLD]]N\u00E9v:[[YELLOW]] {0}
|
||||||
Commands.MmoInfo.DetailsHeader=[[DARK_AQUA]]-=[]=====[][[GREEN]] R\u00E9szletek [[DARK_AQUA]][]=====[]=-
|
Commands.MmoInfo.DetailsHeader=[[DARK_AQUA]]-=[]=====[][[GREEN]] R\u00E9szletek [[DARK_AQUA]][]=====[]=-
|
||||||
@ -945,7 +947,7 @@ Guides.Taming.Section.8=[[DARK_AQUA]]Hogyan m\u0171k\u00F6dik a Gyors\u00E9tterm
|
|||||||
##Unarmed
|
##Unarmed
|
||||||
Guides.Unarmed.Section.0=[[DARK_AQUA]]A Felfegyverzetlenr\u0151l:\n[[YELLOW]]A Felfegyverzetlen k\u00FCl\u00F6nb\u00F6z\u0151 harci b\u00F3nuszokkal l\u00E1t el, ha\n[[YELLOW]]az \u00F6kleidet haszn\u00E1lod fegyverk\u00E9nt. \n\n[[DARK_AQUA]]TAPASZTALAT SZERZ\u00C9S:\n[[YELLOW]]Harcolj \u00E9l\u0151l\u00E9nyekkel vagy j\u00E1t\u00E9kosokkal pusztak\u00E9zzel.
|
Guides.Unarmed.Section.0=[[DARK_AQUA]]A Felfegyverzetlenr\u0151l:\n[[YELLOW]]A Felfegyverzetlen k\u00FCl\u00F6nb\u00F6z\u0151 harci b\u00F3nuszokkal l\u00E1t el, ha\n[[YELLOW]]az \u00F6kleidet haszn\u00E1lod fegyverk\u00E9nt. \n\n[[DARK_AQUA]]TAPASZTALAT SZERZ\u00C9S:\n[[YELLOW]]Harcolj \u00E9l\u0151l\u00E9nyekkel vagy j\u00E1t\u00E9kosokkal pusztak\u00E9zzel.
|
||||||
Guides.Unarmed.Section.1=[[DARK_AQUA]]Hogyan m\u0171k\u00F6dik a Vadul\u00E1s?\n[[YELLOW]]A Vadul\u00E1s egy jobb klikkel\u00E9ssel aktiv\u00E1lhat\u00F3 k\u00E9pess\u00E9g. \n[[YELLOW]]Ebben a m\u00F3dban 50%-kal t\u00F6bb sebz\u00E9st okozol, \u00E9s \n[[YELLOW]]a gyenge anyagokat, mint a f\u00F6ld \u00E9s f\u00FCves blokk, instant ki\u00FCtheted.
|
Guides.Unarmed.Section.1=[[DARK_AQUA]]Hogyan m\u0171k\u00F6dik a Vadul\u00E1s?\n[[YELLOW]]A Vadul\u00E1s egy jobb klikkel\u00E9ssel aktiv\u00E1lhat\u00F3 k\u00E9pess\u00E9g. \n[[YELLOW]]Ebben a m\u00F3dban 50%-kal t\u00F6bb sebz\u00E9st okozol, \u00E9s \n[[YELLOW]]a gyenge anyagokat, mint a f\u00F6ld \u00E9s f\u00FCves blokk, instant ki\u00FCtheted.
|
||||||
Guides.Unarmed.Section.2=[[DARK_AQUA]]Hogyan m\u0171k\u00F6dik a Vas-\u00D6k\u00F6l St\u00EDlus?\n[[YELLOW]]A Vas-\u00D6k\u00F6l St\u00EDlus b\u00F3nusz sebz\u00E9st biztos\u00EDt \u00E9l\u0151l\u00E9nyek \u00E9s j\u00E1t\u00E9kosok ellen\n[[YELLOW]]ha csak az \u00F6kleidet haszn\u00E1lod.
|
Guides.Unarmed.Section.2=[[DARK_AQUA]]Hogyan m\u0171k\u00F6dik az Ac\u00E9l-\u00D6k\u00F6l St\u00EDlus?\n[[YELLOW]]Az Ac\u00E9l-\u00D6k\u00F6l St\u00EDlus b\u00F3nusz sebz\u00E9st biztos\u00EDt \u00E9l\u0151l\u00E9nyek \u00E9s j\u00E1t\u00E9kosok ellen\n[[YELLOW]]ha csak az \u00F6kleidet haszn\u00E1lod.
|
||||||
Guides.Unarmed.Section.3=[[DARK_AQUA]]Hogyan m\u0171k\u00F6dik a Nyilak Kit\u00E9r\u00EDt\u00E9se?\n[[YELLOW]]A Nyilak Kit\u00E9r\u00EDt\u00E9se egy passz\u00EDv k\u00E9pess\u00E9g, amely lehet\u0151v\u00E9 teszi, \n[[YELLOW]]hogy elh\u00E1r\u00EDtsd a fel\u00E9d \u00E9rkez\u0151 nyilakat.\n[[YELLOW]]A nyilak leesnek a f\u00F6ldre.
|
Guides.Unarmed.Section.3=[[DARK_AQUA]]Hogyan m\u0171k\u00F6dik a Nyilak Kit\u00E9r\u00EDt\u00E9se?\n[[YELLOW]]A Nyilak Kit\u00E9r\u00EDt\u00E9se egy passz\u00EDv k\u00E9pess\u00E9g, amely lehet\u0151v\u00E9 teszi, \n[[YELLOW]]hogy elh\u00E1r\u00EDtsd a fel\u00E9d \u00E9rkez\u0151 nyilakat.\n[[YELLOW]]A nyilak leesnek a f\u00F6ldre.
|
||||||
Guides.Unarmed.Section.4=[[DARK_AQUA]]Hogyan m\u0171k\u00F6dik a Vas-Markol\u00E1s?\n[[YELLOW]]A Vas-Markol\u00E1s a Lefegyverz\u00E9st akad\u00E1lyozza meg. Min\u00E9l nagyobb a \n[[YELLOW]]Felfegyverzetlen szinted, ann\u00E1l nagyobb es\u00E9llyel \u00E1llsz ellen a Lefegyverz\u00E9snek.
|
Guides.Unarmed.Section.4=[[DARK_AQUA]]Hogyan m\u0171k\u00F6dik a Vas-Markol\u00E1s?\n[[YELLOW]]A Vas-Markol\u00E1s a Lefegyverz\u00E9st akad\u00E1lyozza meg. Min\u00E9l nagyobb a \n[[YELLOW]]Felfegyverzetlen szinted, ann\u00E1l nagyobb es\u00E9llyel \u00E1llsz ellen a Lefegyverz\u00E9snek.
|
||||||
Guides.Unarmed.Section.5=[[DARK_AQUA]]Hogyan m\u0171k\u00F6dik a Lefegyverz\u00E9s?\n[[YELLOW]]A Lefegyverz\u00E9s lehet\u0151v\u00E9 teszi, hogy lefegyverezd az ellens\u00E9ged,\n[[YELLOW]]ez\u00E1ltal az kidobja a fegyver\u00E9t a f\u00F6ldre.
|
Guides.Unarmed.Section.5=[[DARK_AQUA]]Hogyan m\u0171k\u00F6dik a Lefegyverz\u00E9s?\n[[YELLOW]]A Lefegyverz\u00E9s lehet\u0151v\u00E9 teszi, hogy lefegyverezd az ellens\u00E9ged,\n[[YELLOW]]ez\u00E1ltal az kidobja a fegyver\u00E9t a f\u00F6ldre.
|
||||||
@ -979,6 +981,7 @@ Skills.Child=[[GOLD]](ALK\u00C9PESS\u00C9G)
|
|||||||
Skills.Disarmed=[[DARK_RED]]Lefegyvereztek!
|
Skills.Disarmed=[[DARK_RED]]Lefegyvereztek!
|
||||||
Skills.Header=-----[] [[GREEN]]{0}[[RED]] []-----
|
Skills.Header=-----[] [[GREEN]]{0}[[RED]] []-----
|
||||||
Skills.NeedMore=[[DARK_RED]]T\u00F6bb[[GRAY]]{0}-ra/re van sz\u00FCks\u00E9ged
|
Skills.NeedMore=[[DARK_RED]]T\u00F6bb[[GRAY]]{0}-ra/re van sz\u00FCks\u00E9ged
|
||||||
|
Skills.NeedMore.Extra=[[DARK_RED]]T\u00F6bbre van sz\u00FCks\u00E9ged [[GRAY]]{0}{1}
|
||||||
Skills.Parents= ANYAK\u00C9PESS\u00C9G
|
Skills.Parents= ANYAK\u00C9PESS\u00C9G
|
||||||
Skills.Stats={0}[[GREEN]]{1}[[DARK_AQUA]] XP([[GRAY]]{2}[[DARK_AQUA]]/[[GRAY]]{3}[[DARK_AQUA]])
|
Skills.Stats={0}[[GREEN]]{1}[[DARK_AQUA]] XP([[GRAY]]{2}[[DARK_AQUA]]/[[GRAY]]{3}[[DARK_AQUA]])
|
||||||
Skills.ChildStats={0}[[GREEN]]{1}
|
Skills.ChildStats={0}[[GREEN]]{1}
|
||||||
@ -1109,4 +1112,7 @@ LevelCap.PowerLevel=[[GOLD]]([[GREEN]]mcMMO[[GOLD]]) [[YELLOW]]El\u00E9rted ezt
|
|||||||
LevelCap.Skill=[[GOLD]]([[GREEN]]mcMMO[[GOLD]]) [[YELLOW]]El\u00E9rted ezt a szintet [[RED]]{0}[[YELLOW]] ebben [[GOLD]]{1}[[YELLOW]]. Ezen a ponton megsz\u0171nik a k\u00E9pess\u00E9g szintje.
|
LevelCap.Skill=[[GOLD]]([[GREEN]]mcMMO[[GOLD]]) [[YELLOW]]El\u00E9rted ezt a szintet [[RED]]{0}[[YELLOW]] ebben [[GOLD]]{1}[[YELLOW]]. Ezen a ponton megsz\u0171nik a k\u00E9pess\u00E9g szintje.
|
||||||
Commands.XPBar.Usage=Proper usage is /mmoxpbar <skillname | reset> <show | hide>
|
Commands.XPBar.Usage=Proper usage is /mmoxpbar <skillname | reset> <show | hide>
|
||||||
Commands.Description.mmoxpbar=Player settings for mcMMO XP bars
|
Commands.Description.mmoxpbar=Player settings for mcMMO XP bars
|
||||||
Commands.Description.mmocompat=Information about mcMMO and whether or not its in compatibility mode or fully functional.
|
Commands.Description.mmocompat=Inform\u00E1ci\u00F3 az mcMMO-r\u00F3l \u00E9s arr\u00F3l, hogy kompatibilit\u00E1si m\u00F3dban van-e, vagy teljesen m\u0171k\u00F6d\u0151k\u00E9pes-e.
|
||||||
|
Compatibility.Layer.Unsupported=[[GOLD]]A kompatibilit\u00E1s ezen a Minecraft verzi\u00F3n [[GREEN]]{0}[[GOLD]] nem t\u00E1mogatott.
|
||||||
|
Compatibility.Layer.PartialSupport=[[GOLD]]A kompatibilit\u00E1s ezen a Minecraft verzi\u00F3n [[GREEN]]{0}[[GOLD]] nem teljesen t\u00E1mogatott, de az mcMMO egy m\u00E1sodlagos rendszert futtat n\u00E9h\u00E1ny hi\u00E1nyz\u00F3 funkci\u00F3 emul\u00E1l\u00E1s\u00E1ra.
|
||||||
|
Commands.XPBar.DisableAll=[[GOLD]] Most az \u00F6sszes mcMMO XP s\u00E1v le van tiltva, haszn\u00E1ld a /mmoxpbar reset parancsot az alap\u00E9rtelmezett be\u00E1ll\u00EDt\u00E1sok vissza\u00E1ll\u00EDt\u00E1s\u00E1hoz.
|
||||||
|
@ -672,7 +672,7 @@ permissions:
|
|||||||
children:
|
children:
|
||||||
mcmmo.ability.unarmed.berserk: true
|
mcmmo.ability.unarmed.berserk: true
|
||||||
mcmmo.ability.unarmed.blockcracker: true
|
mcmmo.ability.unarmed.blockcracker: true
|
||||||
mcmmo.ability.unarmed.ironarmstyle: true
|
mcmmo.ability.unarmed.steelarmstyle: true
|
||||||
mcmmo.ability.unarmed.arrowdeflect: true
|
mcmmo.ability.unarmed.arrowdeflect: true
|
||||||
mcmmo.ability.unarmed.disarm: true
|
mcmmo.ability.unarmed.disarm: true
|
||||||
mcmmo.ability.unarmed.irongrip: true
|
mcmmo.ability.unarmed.irongrip: true
|
||||||
@ -683,8 +683,8 @@ permissions:
|
|||||||
description: Allows access to the Berserker sub-skill
|
description: Allows access to the Berserker sub-skill
|
||||||
mcmmo.ability.unarmed.blockcracker:
|
mcmmo.ability.unarmed.blockcracker:
|
||||||
description: Allows access to the Block Cracker sub-skill
|
description: Allows access to the Block Cracker sub-skill
|
||||||
mcmmo.ability.unarmed.ironarmstyle:
|
mcmmo.ability.unarmed.steelarmstyle:
|
||||||
description: Allows bonus damage from the Iron Arm sub-skill
|
description: Allows bonus damage from the Steel Arm Style ability
|
||||||
mcmmo.ability.unarmed.arrowdeflect:
|
mcmmo.ability.unarmed.arrowdeflect:
|
||||||
description: Allows access to the Arrow Deflect sub-skill
|
description: Allows access to the Arrow Deflect sub-skill
|
||||||
mcmmo.ability.unarmed.disarm:
|
mcmmo.ability.unarmed.disarm:
|
||||||
|
@ -546,19 +546,50 @@ Unarmed:
|
|||||||
Rank_1: 60
|
Rank_1: 60
|
||||||
RetroMode:
|
RetroMode:
|
||||||
Rank_1: 600
|
Rank_1: 600
|
||||||
IronArmStyle:
|
SteelArmStyle:
|
||||||
Standard:
|
Standard:
|
||||||
Rank_1: 1
|
Rank_1: 1
|
||||||
Rank_2: 25
|
Rank_2: 10
|
||||||
Rank_3: 50
|
Rank_3: 15
|
||||||
Rank_4: 75
|
Rank_4: 20
|
||||||
Rank_5: 100
|
Rank_5: 25
|
||||||
|
Rank_6: 30
|
||||||
|
Rank_7: 35
|
||||||
|
Rank_8: 40
|
||||||
|
Rank_9: 45
|
||||||
|
Rank_10: 50
|
||||||
|
Rank_11: 55
|
||||||
|
Rank_12: 60
|
||||||
|
Rank_13: 65
|
||||||
|
Rank_14: 70
|
||||||
|
Rank_15: 75
|
||||||
|
Rank_16: 80
|
||||||
|
Rank_17: 85
|
||||||
|
Rank_18: 90
|
||||||
|
Rank_19: 95
|
||||||
|
Rank_20: 100
|
||||||
RetroMode:
|
RetroMode:
|
||||||
Rank_1: 1
|
Rank_1: 1
|
||||||
Rank_2: 250
|
Rank_2: 100
|
||||||
Rank_3: 500
|
Rank_3: 150
|
||||||
Rank_4: 750
|
Rank_4: 200
|
||||||
Rank_5: 1000lo
|
Rank_5: 250
|
||||||
|
Rank_6: 300
|
||||||
|
Rank_7: 350
|
||||||
|
Rank_8: 400
|
||||||
|
Rank_9: 450
|
||||||
|
Rank_10: 500
|
||||||
|
Rank_11: 550
|
||||||
|
Rank_12: 600
|
||||||
|
Rank_13: 650
|
||||||
|
Rank_14: 700
|
||||||
|
Rank_15: 750
|
||||||
|
Rank_16: 800
|
||||||
|
Rank_17: 850
|
||||||
|
Rank_18: 900
|
||||||
|
Rank_19: 950
|
||||||
|
Rank_20: 1000
|
||||||
|
|
||||||
Woodcutting:
|
Woodcutting:
|
||||||
Splinter:
|
Splinter:
|
||||||
Standard:
|
Standard:
|
||||||
|
Loading…
Reference in New Issue
Block a user