Fixed inverted flight controls when flying as a pegasus

This commit is contained in:
Sollace 2020-10-11 11:15:07 +02:00
parent c83dedb0a4
commit a3b833cafa
2 changed files with 4 additions and 2 deletions

View file

@ -253,7 +253,9 @@ public class PlayerPhysics extends EntityPhysics<Pony> implements Tickable, Moti
velocity.y += (direction.y * 2.45 + Math.abs(direction.y) * 10) * getGravitySignum();
if (player.isSneaking()) {
velocity.y += (0.4 - 0.25) * getGravitySignum();
if (!isGravityNegative()) {
velocity.y += 0.4 - 0.25;
}
if (pony.sneakingChanged()) {
velocity.y += 0.75 * getGravitySignum();
}

View file

@ -25,7 +25,7 @@ abstract class MixinKeyboardInput extends Input {
movementSideways = -movementSideways;
if (player.getMaster().abilities.flying || player.getPhysics().isFlying()) {
if (player.getMaster().abilities.flying && !player.getPhysics().isFlying()) {
tmp = jumping;
jumping = sneaking;
sneaking = tmp;