Fix items never falling after being on ground (#8768)

This commit is contained in:
Hannes Greule 2023-01-07 13:05:13 +01:00
parent 18e27e77fd
commit 78bd0e8518
2 changed files with 3 additions and 3 deletions

View File

@ -740,8 +740,8 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
+ +
} }
// Add a little performance juice to active entities. Skip 1/4 if not immune. // Add a little performance juice to active entities. Skip 1/4 if not immune.
- } else if ( !entity.defaultActivationState && (entity.tickCount + entity.getId()) % 4 == 3 && !ActivationRange.checkEntityImmunities( entity ) ) // Paper - Ensure checking item movement is offset from Spigot's entity activation range check - } else if ( !entity.defaultActivationState && (entity.tickCount + entity.getId()) % 4 == 0 && !ActivationRange.checkEntityImmunities( entity ) ) // Paper - Ensure checking item movement is offset from Spigot's entity activation range check
+ } else if ( (entity.tickCount + entity.getId()) % 4 == 3 && ActivationRange.checkEntityImmunities( entity ) < 0 ) // Paper + } else if ( (entity.tickCount + entity.getId()) % 4 == 0 && ActivationRange.checkEntityImmunities( entity ) < 0 ) // Paper
{ {
isActive = false; isActive = false;
} }

View File

@ -36,7 +36,7 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
} }
// Add a little performance juice to active entities. Skip 1/4 if not immune. // Add a little performance juice to active entities. Skip 1/4 if not immune.
- } else if ( !entity.defaultActivationState && entity.tickCount % 4 == 0 && !ActivationRange.checkEntityImmunities( entity ) ) - } else if ( !entity.defaultActivationState && entity.tickCount % 4 == 0 && !ActivationRange.checkEntityImmunities( entity ) )
+ } else if ( !entity.defaultActivationState && (entity.tickCount + entity.getId()) % 4 == 3 && !ActivationRange.checkEntityImmunities( entity ) ) // Paper - Ensure checking item movement is offset from Spigot's entity activation range check + } else if ( !entity.defaultActivationState && (entity.tickCount + entity.getId()) % 4 == 0 && !ActivationRange.checkEntityImmunities( entity ) ) // Paper - Ensure checking item movement is offset from Spigot's entity activation range check
{ {
isActive = false; isActive = false;
} }