Use hasImpulse vs hurtMarked for setVelocity

This will prevent projectiles from using the less accurate path for updating motion when interfaced with the API. However, hasImpulse is the more proper way of marking that the entity needs its velocity updated anyways.

This seems to be fairly unused logic in vanilla
This commit is contained in:
Owen1212055
2025-06-23 22:39:41 -04:00
parent 068a1ccda1
commit daa4fe5fb5

View File

@@ -200,7 +200,7 @@ public abstract class CraftEntity implements org.bukkit.entity.Entity {
}
// Paper end
this.entity.setDeltaMovement(CraftVector.toVec3(velocity));
this.entity.hurtMarked = true;
this.entity.hasImpulse = true;
}
/**