mirror of
https://github.com/Sollace/Unicopia.git
synced 2024-11-23 21:38:00 +01:00
Only regenerate when the pegasus has reached the ground. Fixes #356
This commit is contained in:
parent
c09b02d8c8
commit
2cdce6504c
1 changed files with 3 additions and 3 deletions
|
@ -99,13 +99,13 @@ class ManaContainer implements MagicReserves, Tickable, NbtSerialisable, Copyabl
|
||||||
energy.addPercent(-1);
|
energy.addPercent(-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (pony.getCompositeRace().canFly() && !pony.getPhysics().isFlying()) {
|
if (pony.getCompositeRace().canFly() && !pony.getPhysics().isFlying() && pony.asEntity().isOnGround()) {
|
||||||
exhaustion.multiply(0.8F);
|
exhaustion.multiply(0.99F);
|
||||||
} else {
|
} else {
|
||||||
exhaustion.addPercent(-1);
|
exhaustion.addPercent(-1);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!pony.getCompositeRace().canFly() || !pony.getPhysics().isFlying()) {
|
if (!pony.getCompositeRace().canFly() || (!pony.getPhysics().isFlying() && pony.asEntity().isOnGround())) {
|
||||||
if (mana.getPercentFill() < 1 && mana.getShadowFill(1) <= mana.getPercentFill(1)) {
|
if (mana.getPercentFill() < 1 && mana.getShadowFill(1) <= mana.getPercentFill(1)) {
|
||||||
mana.addPercent(MathHelper.clamp(1 + pony.getLevel().get(), 1, 50) / 4F);
|
mana.addPercent(MathHelper.clamp(1 + pony.getLevel().get(), 1, 50) / 4F);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue