mirror of
https://github.com/KAMKEEL/CustomNPC-Plus.git
synced 2026-11-18 04:35:03 +00:00
Refine mount GUI layout and flight handling
This commit is contained in:
1 parent
9744209938
commit
c33ac04d11
4 files changed
+63
-9
No files matched your search
@@ -107,6 +107,8 @@ public abstract class EntityNPCFlying extends EntityNPCInterface {
|
||||
return;
|
||||
}
|
||||
|
||||
boolean flightModeActive = isMountFlightModeActive();
|
||||
|
||||
boolean aboveLimit = false;
|
||||
double heightOffGround = this.posY - this.worldObj.getTopSolidOrLiquidBlock((int) this.posX, (int) this.posZ);
|
||||
if (heightOffGround < 0) {
|
||||
@@ -132,6 +134,12 @@ public abstract class EntityNPCFlying extends EntityNPCInterface {
|
||||
this.flyLimitAllow = true;
|
||||
setNpcFlyingState(true);
|
||||
|
||||
if (flightModeActive) {
|
||||
super.performMountedMovement(strafe, forward, moveSpeed);
|
||||
this.velocityChanged = true;
|
||||
return;
|
||||
}
|
||||
|
||||
double d3 = this.motionY;
|
||||
super.performMountedMovement(strafe, forward, moveSpeed);
|
||||
this.motionY = d3;
|
||||
|
||||
Reference in new issue
Block a user