mirror of
https://github.com/NoCheatPlus/NoCheatPlus.git
synced 2024-09-29 23:17:41 +02:00
Let fly speed apply with flying upwards.
Might be different with earlier versions of MC. Can be made version-dependent on request.
This commit is contained in:
parent
5e17ce05ff
commit
83c8d52631
@ -131,6 +131,11 @@ public class CreativeFly extends Check {
|
||||
// TODO: max descending speed ! [max fall speed, use maximum with speed or added ?]
|
||||
double limitV = model.vMod / 100D * ModelFlying.VERTICAL_SPEED; // * data.jumpAmplifier;
|
||||
|
||||
if (flying && yDistance > 0.0) {
|
||||
// Let fly speed apply with moving upwards.
|
||||
limitV *= data.flySpeed / 0.1;
|
||||
}
|
||||
|
||||
if (data.lastYDist != Double.MAX_VALUE) {
|
||||
// (Disregard gravity.)
|
||||
double frictionDist = data.lastYDist * SurvivalFly.FRICTION_MEDIUM_AIR;
|
||||
|
Loading…
Reference in New Issue
Block a user