Fix Salvage, Swords and Unarmed command

This commit is contained in:
nossr50 2019-09-23 13:30:21 -07:00
parent efbd9d52c3
commit 57c30bac98
4 changed files with 7 additions and 16 deletions

View File

@ -3,7 +3,6 @@ package com.gmail.nossr50.commands.skills;
import com.gmail.nossr50.datatypes.skills.PrimarySkillType;
import com.gmail.nossr50.datatypes.skills.SubSkillType;
import com.gmail.nossr50.mcMMO;
import com.gmail.nossr50.skills.salvage.Salvage;
import com.gmail.nossr50.skills.salvage.SalvageManager;
import net.md_5.bungee.api.chat.TextComponent;
import org.bukkit.entity.Player;
@ -48,11 +47,11 @@ public class SalvageCommand extends SkillCommand {
String.valueOf(salvageManager.getArcaneSalvageRank()),
String.valueOf(pluginRef.getRankTools().getHighestRank(SubSkillType.SALVAGE_ARCANE_SALVAGE))));
if (Salvage.arcaneSalvageEnchantLoss) {
if (pluginRef.getDynamicSettingsManager().getSkillBehaviourManager().getSalvageBehaviour().isArcaneSalvageEnchantLoss()) {
messages.add(pluginRef.getLocaleManager().getString("Ability.Generic.Template", pluginRef.getLocaleManager().getString("Salvage.Arcane.ExtractFull"), percent.format(salvageManager.getExtractFullEnchantChance() / 100)));
}
if (Salvage.arcaneSalvageDowngrades) {
if (pluginRef.getDynamicSettingsManager().getSkillBehaviourManager().getSalvageBehaviour().isArcaneSalvageDowngrades()) {
messages.add(pluginRef.getLocaleManager().getString("Ability.Generic.Template", pluginRef.getLocaleManager().getString("Salvage.Arcane.ExtractPartial"), percent.format(salvageManager.getExtractPartialEnchantChance() / 100)));
}
}

View File

@ -16,9 +16,9 @@ public class SkillGuideCommand implements CommandExecutor {
private String invalidPage;
private final mcMMO pluginRef;
public SkillGuideCommand(PrimarySkillType skill, mcMMO pluginRef) {
header = pluginRef.getLocaleManager().getString("Guides.Header", skill.getLocalizedSkillName());
guide = getGuide(skill);
public SkillGuideCommand(PrimarySkillType primarySkillType, mcMMO pluginRef) {
header = pluginRef.getLocaleManager().getString("Guides.Header", pluginRef.getSkillTools().getLocalizedSkillName(primarySkillType));
guide = getGuide(primarySkillType);
invalidPage = pluginRef.getLocaleManager().getString("Guides.Page.Invalid");
this.pluginRef = pluginRef;
}

View File

@ -98,11 +98,7 @@ public class SwordsCommand extends SkillCommand {
if (canUseSubSkill(player, SubSkillType.SWORDS_SWORDS_LIMIT_BREAK)) {
messages.add(getStatMessage(SubSkillType.SWORDS_SWORDS_LIMIT_BREAK,
<<<<<<< HEAD
String.valueOf(pluginRef.getCombatTools().getLimitBreakDamage(player, SubSkillType.SWORDS_SWORDS_LIMIT_BREAK))));
=======
String.valueOf(CombatUtils.getLimitBreakDamageAgainstQuality(player, SubSkillType.SWORDS_SWORDS_LIMIT_BREAK, 1000))));
>>>>>>> 308e3a4b1f46e9e3de28d6d540dd055a540ed4d5
String.valueOf(pluginRef.getCombatTools().getLimitBreakDamageAgainstQuality(player, SubSkillType.SWORDS_SWORDS_LIMIT_BREAK, 1000))));
}
return messages;

View File

@ -110,11 +110,7 @@ public class UnarmedCommand extends SkillCommand {
if (canUseSubSkill(player, SubSkillType.UNARMED_UNARMED_LIMIT_BREAK)) {
messages.add(getStatMessage(SubSkillType.UNARMED_UNARMED_LIMIT_BREAK,
<<<<<<< HEAD
String.valueOf(pluginRef.getCombatTools().getLimitBreakDamage(player, SubSkillType.UNARMED_UNARMED_LIMIT_BREAK))));
=======
String.valueOf(CombatUtils.getLimitBreakDamageAgainstQuality(player, SubSkillType.UNARMED_UNARMED_LIMIT_BREAK, 1000))));
>>>>>>> 308e3a4b1f46e9e3de28d6d540dd055a540ed4d5
String.valueOf(pluginRef.getCombatTools().getLimitBreakDamageAgainstQuality(player, SubSkillType.UNARMED_UNARMED_LIMIT_BREAK, 1000))));
}
return messages;