Returns a NBTTagCompound that can be used to store custom data for this entity.
It will be written, and read from disc, so it persists over world saves.
Returns:
A NBTTagCompound
shouldRiderSit
defaultbooleanshouldRiderSit()
Used in model rendering to determine if the entity riding this entity should be in the 'sitting' position.
Returns:
false to prevent an entity that is mounted to this entity from displaying the 'sitting' animation.
forSpawnCount - If this is being invoked to check spawn count caps.
Returns:
If the creature is of the type provided
isAddedToWorld
booleanisAddedToWorld()
Gets whether this entity has been added to a world (for tracking). Specifically
between the times when an entity is added to a world and the entity being removed
from the world's tracked lists.
Returns:
True if this entity is being tracked by a world
onAddedToWorld
voidonAddedToWorld()
Called after the entity has been added to the world's
ticking list. Can be overriden, but needs to call super
to prevent MC-136995.
onRemovedFromWorld
voidonRemovedFromWorld()
Called after the entity has been removed to the world's
ticking list. Can be overriden, but needs to call super
to prevent MC-136995.
revive
voidrevive()
Revives an entity that has been removed from a world.
Used as replacement for entity.removed = true. Having it as a function allows
the entity to react to being revived.
isMultipartEntity
defaultbooleanisMultipartEntity()
This is used to specify that your entity has multiple individual parts, such as the Vanilla Ender Dragon.
See EnderDragon for an example implementation.
Gets the individual sub parts that make up this entity.
The entities returned by this method are NOT saved to the world in nay way, they exist as an extension
of their host entity. The child entity does not track its server-side(or client-side) counterpart, and
the host entity is responsible for moving and managing these children.
Only used if isMultipartEntity() returns true.
See EnderDragon for an example implementation.
Returns:
The child parts of this entity. The value to be returned here should be cached.
getStepHeight
defaultfloatgetStepHeight()
Returns:
Return the height in blocks the Entity can step up without needing to jump
This is the sum of vanilla's Entity.maxUpStep field and the current value
of the ForgeMod.STEP_HEIGHT_ADDITION attribute
(if this Entity is a LivingEntity and has the attribute), clamped at 0.