MCPcopy Create free account
hub / github.com/DGVPSH/SlackOpen / onLanded

Method onLanded

src/main/java/net/minecraft/block/BlockSlime.java:46–56  ·  view source on GitHub ↗

Called when an Entity lands on this Block. This method must update motionY because the entity will not do that on its own

(World worldIn, Entity entityIn)

Source from the content-addressed store, hash-verified

44 * on its own
45 */
46 public void onLanded(World worldIn, Entity entityIn)
47 {
48 if (entityIn.isSneaking())
49 {
50 super.onLanded(worldIn, entityIn);
51 }
52 else if (entityIn.motionY < 0.0D)
53 {
54 entityIn.motionY = -entityIn.motionY;
55 }
56 }
57
58 /**
59 * Triggered whenever an entity collides with this block (enters into the block)

Callers

nothing calls this directly

Calls 1

isSneakingMethod · 0.45

Tested by

no test coverage detected