mirror of
https://github.com/mcMMO-Dev/mcMMO.git
synced 2024-11-22 13:16:45 +01:00
Update to Beast Lore
Removed movement speed information for llamas, and added jump strength info for horses. Also added another locale string to display this information.
This commit is contained in:
parent
d6eefac065
commit
98f8e049f3
@ -256,9 +256,13 @@ public class TamingManager extends SkillManager {
|
||||
|
||||
message = message.concat(LocaleLoader.getString("Combat.BeastLoreHealth", target.getHealth(), target.getMaxHealth()));
|
||||
|
||||
if (beast instanceof AbstractHorse) {
|
||||
AbstractHorse horse = (AbstractHorse) beast;
|
||||
message = message.concat("\n" + LocaleLoader.getString("Combat.BeastLoreHorseSpeed", horse.getAttribute(Attribute.GENERIC_MOVEMENT_SPEED).getValue() * 43));
|
||||
if (beast instanceof Horse) {
|
||||
Horse horse = (Horse) beast;
|
||||
double jumpStrength = horse.getAttribute(Attribute.HORSE_JUMP_STRENGTH).getValue();
|
||||
// Taken from https://minecraft.gamepedia.com/Horse#Jump_strength
|
||||
jumpStrength = -0.1817584952 * Math.pow(jumpStrength, 3) + 3.689713992 * Math.pow(jumpStrength, 2) + 2.128599134 * jumpStrength - 0.343930367;
|
||||
message = message.concat("\n" + LocaleLoader.getString("Combat.BeastLoreHorseSpeed", horse.getAttribute(Attribute.GENERIC_MOVEMENT_SPEED).getValue() * 43))
|
||||
.concat("\n" + LocaleLoader.getString("Combat.BeastLoreHorseJumpStrength", jumpStrength));
|
||||
}
|
||||
|
||||
player.sendMessage(message);
|
||||
|
@ -556,6 +556,7 @@ Combat.BeastLore=[[GREEN]]**BEAST LORE**
|
||||
Combat.BeastLoreHealth=[[DARK_AQUA]]Health ([[GREEN]]{0}[[DARK_AQUA]]/{1})
|
||||
Combat.BeastLoreOwner=[[DARK_AQUA]]Owner ([[RED]]{0}[[DARK_AQUA]])
|
||||
Combat.BeastLoreHorseSpeed=[[DARK_AQUA]]Horse Movement Speed ([[GREEN]]{0} blocks/s[[DARK_AQUA]])
|
||||
Combat.BeastLoreHorseJumpStrength=[[DARK_AQUA]]Horse Jump Strength ([[GREEN]]Max {0} blocks[[DARK_AQUA]])
|
||||
Combat.Gore=[[GREEN]]**GORED**
|
||||
Combat.StruckByGore=**YOU HAVE BEEN GORED**
|
||||
Combat.TargetDazed=Target was [[DARK_RED]]Dazed
|
||||
|
Loading…
Reference in New Issue
Block a user