mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-22 13:16:45 +01:00
Tend toward the smaller values, and configurable maximum for horse jump strength
This commit is contained in:
parent
5a68c7a335
commit
29f2525b58
@ -526,6 +526,9 @@ public class AdvancedConfig extends AutoUpdateConfigLoader {
|
|||||||
reason.add("Skills.Taming.SharpenedClaws.Bonus should be at least 1!");
|
reason.add("Skills.Taming.SharpenedClaws.Bonus should be at least 1!");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (getMaxHorseJumpStrength() < 0 || getMaxHorseJumpStrength() > 2) {
|
||||||
|
reason.add("Skills.Taming.CallOfTheWild.MaxHorseJumpStrength should be between 0 and 2!");
|
||||||
|
}
|
||||||
|
|
||||||
/* UNARMED */
|
/* UNARMED */
|
||||||
if (getDisarmChanceMax() < 1) {
|
if (getDisarmChanceMax() < 1) {
|
||||||
@ -764,6 +767,8 @@ public class AdvancedConfig extends AutoUpdateConfigLoader {
|
|||||||
public int getSharpenedClawsUnlock() { return config.getInt("Skills.Taming.SharpenedClaws.UnlockLevel", 750); }
|
public int getSharpenedClawsUnlock() { return config.getInt("Skills.Taming.SharpenedClaws.UnlockLevel", 750); }
|
||||||
public double getSharpenedClawsBonus() { return config.getDouble("Skills.Taming.SharpenedClaws.Bonus", 2.0D); }
|
public double getSharpenedClawsBonus() { return config.getDouble("Skills.Taming.SharpenedClaws.Bonus", 2.0D); }
|
||||||
|
|
||||||
|
public double getMaxHorseJumpStrength() { return config.getDouble("Skills.Taming.CallOfTheWild.MaxHorseJumpStrength", 2.0D); }
|
||||||
|
|
||||||
/* UNARMED */
|
/* UNARMED */
|
||||||
public double getDisarmChanceMax() { return config.getDouble("Skills.Unarmed.Disarm.ChanceMax", 33.0D); }
|
public double getDisarmChanceMax() { return config.getDouble("Skills.Unarmed.Disarm.ChanceMax", 33.0D); }
|
||||||
public int getDisarmMaxBonusLevel() { return config.getInt("Skills.Unarmed.Disarm.MaxBonusLevel", 1000); }
|
public int getDisarmMaxBonusLevel() { return config.getInt("Skills.Unarmed.Disarm.MaxBonusLevel", 1000); }
|
||||||
|
@ -11,6 +11,7 @@ import org.bukkit.entity.Wolf;
|
|||||||
import org.bukkit.inventory.ItemStack;
|
import org.bukkit.inventory.ItemStack;
|
||||||
|
|
||||||
import com.gmail.nossr50.mcMMO;
|
import com.gmail.nossr50.mcMMO;
|
||||||
|
import com.gmail.nossr50.config.AdvancedConfig;
|
||||||
import com.gmail.nossr50.config.Config;
|
import com.gmail.nossr50.config.Config;
|
||||||
import com.gmail.nossr50.datatypes.player.McMMOPlayer;
|
import com.gmail.nossr50.datatypes.player.McMMOPlayer;
|
||||||
import com.gmail.nossr50.datatypes.skills.SkillType;
|
import com.gmail.nossr50.datatypes.skills.SkillType;
|
||||||
@ -240,7 +241,7 @@ public class TamingManager extends SkillManager {
|
|||||||
entity.setHealth(entity.getMaxHealth());
|
entity.setHealth(entity.getMaxHealth());
|
||||||
horse.setColor(Horse.Color.values()[Misc.getRandom().nextInt(Horse.Color.values().length)]);
|
horse.setColor(Horse.Color.values()[Misc.getRandom().nextInt(Horse.Color.values().length)]);
|
||||||
horse.setStyle(Horse.Style.values()[Misc.getRandom().nextInt(Horse.Style.values().length)]);
|
horse.setStyle(Horse.Style.values()[Misc.getRandom().nextInt(Horse.Style.values().length)]);
|
||||||
horse.setJumpStrength(Misc.getRandom().nextDouble() * 2);
|
horse.setJumpStrength(Math.min(Math.min(Misc.getRandom().nextDouble(), Misc.getRandom().nextDouble()) * 2, AdvancedConfig.getInstance().getMaxHorseJumpStrength());
|
||||||
//TODO: setSpeed, once available
|
//TODO: setSpeed, once available
|
||||||
break;
|
break;
|
||||||
|
|
||||||
|
@ -447,6 +447,10 @@ Skills:
|
|||||||
# Bonus: This bonus will get added to the damage caused
|
# Bonus: This bonus will get added to the damage caused
|
||||||
UnlockLevel: 750
|
UnlockLevel: 750
|
||||||
Bonus: 2.0
|
Bonus: 2.0
|
||||||
|
|
||||||
|
CallOfTheWild:
|
||||||
|
# MaxHorseJumpStrength: The maximum jump strength a summoned horse can have
|
||||||
|
MaxHorseJumpStrength: 2.0
|
||||||
#
|
#
|
||||||
# Settings for Unarmed
|
# Settings for Unarmed
|
||||||
###
|
###
|
||||||
|
Loading…
Reference in New Issue
Block a user