Home Commands Examples Getting Started With Scripts Global Keywords 1.21 Migration Guide
BracketDumpers BracketHandlers BracketValidators ResourceLocationBracketHandler

LivingEntity

Importing the class

If you need to reference this type directly, like when casting an Array, or as a parameter, you will need to import it. Simply add the import at the top of the file.

script.zs
import crafttweaker.api.entity.LivingEntity;

Extends

LivingEntity extends Entity.

Implements

LivingEntity implements the following interfaces:

Nameable,EntityAccess,CommandSource,IAttachmentHolder

Undocumented Interfaces

Attackable,ILivingEntityExtension,SyncedDataHolder,ScoreHolder,IEntityExtension,INBTSerializable<CompoundTag>

Members

Getter
Gets the absorption amount for this entity.
script.zs
// LivingEntity.absorptionAmount as float
myLivingEntity.absorptionAmount

Return Type: float

absorptionAmount() as float
Gets the absorption amount for this entity.

Returns: The absorption amount.

script.zs
// LivingEntity.absorptionAmount() as float;
myLivingEntity.absorptionAmount();

Return Type: float

Getter
Checks if the commands from this source should return failure messages
script.zs
// LivingEntity.acceptsFailure as bool
myLivingEntity.acceptsFailure

Return Type: bool

acceptsFailure() as bool
Checks if the commands from this source should return failure messages

Returns: True if the commands from this source should return failure messages, false otherwise.

script.zs
// LivingEntity.acceptsFailure() as bool;
myLivingEntity.acceptsFailure();

Return Type: bool

Getter
Checks if the commands from this source should return successful messages
script.zs
// LivingEntity.acceptsSuccess as bool
myLivingEntity.acceptsSuccess

Return Type: bool

acceptsSuccess() as bool
Checks if the commands from this source should return successful messages

Returns: True if the commands from this source should return successful messages, false otherwise.

script.zs
// LivingEntity.acceptsSuccess() as bool;
myLivingEntity.acceptsSuccess();

Return Type: bool

Getter
Gets the active effects.
script.zs
// LivingEntity.activeEffects as Collection<MobEffectInstance>
myLivingEntity.activeEffects

Return Type: Collection<MobEffectInstance>

activeEffects() as Collection<MobEffectInstance>
Gets the active effects.

Returns: The active effects.

script.zs
// LivingEntity.activeEffects() as Collection<MobEffectInstance>;
myLivingEntity.activeEffects();

Return Type: Collection<MobEffectInstance>

Getter
Gets a map of active effects.
script.zs
// LivingEntity.activeEffectsMap as MobEffectInstance[MobEffect]
myLivingEntity.activeEffectsMap

Return Type: MobEffectInstance[MobEffect]

activeEffectsMap() as MobEffectInstance[MobEffect]
Gets a map of active effects.

Returns: The active effects map.

script.zs
// LivingEntity.activeEffectsMap() as MobEffectInstance[MobEffect];
myLivingEntity.activeEffectsMap();

Return Type: MobEffectInstance[MobEffect]

addEffect(effectInstance as MobEffectInstance) as bool
Adds an effect to this entity.

Returns: True if the effect was added, false otherwise.

script.zs
// LivingEntity.addEffect(effectInstance as MobEffectInstance) as bool;
myLivingEntity.addEffect(myMobEffectInstance);

Parameters:

effectInstance Type: MobEffectInstance - The effect to add.

Return Type: bool

addEffect(effectInstance as MobEffectInstance, entity as Entity) as bool
Adds an effect to this entity.

Returns: True if the effect was added, false otherwise.

script.zs
// LivingEntity.addEffect(effectInstance as MobEffectInstance, entity as Entity) as bool;
myLivingEntity.addEffect(myMobEffectInstance, myEntity);

Parameters:

effectInstance Type: MobEffectInstance - The effect to add.
entity Type: Entity - The entity that is the source of the effect.

Return Type: bool

addTag(tagName as string) as bool
Adds a tag to the entity, returning false if the entity has over 1024

Returns: true if the tag was added.

script.zs
// LivingEntity.addTag(tagName as string) as bool;
myLivingEntity.addTag(myString);

Parameters:

tagName Type: string - The name of the tag to add.

Return Type: bool

Getter
Gets the current air supply of the entity.
script.zs
// LivingEntity.airSupply as int
myLivingEntity.airSupply

Return Type: int

airSupply() as int
Gets the current air supply of the entity.

Returns: The current air supply of the entity.

script.zs
// LivingEntity.airSupply() as int;
myLivingEntity.airSupply();

Return Type: int

Getter
Gets all slots.
script.zs
// LivingEntity.allSlots as Iterable<ItemStack>
myLivingEntity.allSlots

Return Type: Iterable<ItemStack>

allSlots() as Iterable<ItemStack>
Gets all slots.

Returns: An iterable of item stacks representing all slots.

script.zs
// LivingEntity.allSlots() as Iterable<ItemStack>;
myLivingEntity.allSlots();

Return Type: Iterable<ItemStack>

Getter
Checks if the command source always accepts.
script.zs
// LivingEntity.alwaysAccepts as bool
myLivingEntity.alwaysAccepts

Return Type: bool

alwaysAccepts() as bool
Checks if the command source always accepts.

Returns: True if the command source always accepts, false otherwise.

script.zs
// LivingEntity.alwaysAccepts() as bool;
myLivingEntity.alwaysAccepts();

Return Type: bool

Getter
Gets the armor cover percentage for this entity.
This is a value from 0 to 1 that represents the percentage of the entity's body that is covered by armor.
script.zs
// LivingEntity.armorCoverPercentage as float
myLivingEntity.armorCoverPercentage

Return Type: float

armorCoverPercentage() as float
Gets the armor cover percentage for this entity.
This is a value from 0 to 1 that represents the percentage of the entity's body that is covered by armor.

Returns: The armor cover percentage.

script.zs
// LivingEntity.armorCoverPercentage() as float;
myLivingEntity.armorCoverPercentage();

Return Type: float

Getter
Gets this entity's armor items.
script.zs
// LivingEntity.armorSlots as Iterable<ItemStack>
myLivingEntity.armorSlots

Return Type: Iterable<ItemStack>

armorSlots() as Iterable<ItemStack>
Gets this entity's armor items.

Returns: An iterable of item stacks representing the armor items.

script.zs
// LivingEntity.armorSlots() as Iterable<ItemStack>;
myLivingEntity.armorSlots();

Return Type: Iterable<ItemStack>

Getter
Gets the armor value for this entity.
script.zs
// LivingEntity.armorValue as int
myLivingEntity.armorValue

Return Type: int

armorValue() as int
Gets the armor value for this entity.

Returns: The armor value.

script.zs
// LivingEntity.armorValue() as int;
myLivingEntity.armorValue();

Return Type: int

Getter
Gets how many arrows are currently in this entity.
script.zs
// LivingEntity.arrowCount as int
myLivingEntity.arrowCount

Return Type: int

arrowCount() as int
Gets how many arrows are currently in this entity.

Returns: The arrow count.

script.zs
// LivingEntity.arrowCount() as int;
myLivingEntity.arrowCount();

Return Type: int

Getter
Checks if the entity is attackable.
script.zs
// LivingEntity.attackable as bool
myLivingEntity.attackable

Return Type: bool

attackable() as bool
Checks if the entity is attackable.

Returns: True if the entity is attackable, false otherwise.

script.zs
// LivingEntity.attackable() as bool;
myLivingEntity.attackable();

Return Type: bool

Getter
Gets the height of the bounding box of the entity.
script.zs
// LivingEntity.bbHeight as float
myLivingEntity.bbHeight

Return Type: float

bbHeight() as float
Gets the height of the bounding box of the entity.

Returns: The height of the bounding box of the entity.

script.zs
// LivingEntity.bbHeight() as float;
myLivingEntity.bbHeight();

Return Type: float

Getter
Gets the width of the bounding box of the entity.
script.zs
// LivingEntity.bbWidth as float
myLivingEntity.bbWidth

Return Type: float

bbWidth() as float
Gets the width of the bounding box of the entity.

Returns: The width of the bounding box of the entity.

script.zs
// LivingEntity.bbWidth() as float;
myLivingEntity.bbWidth();

Return Type: float

Getter
Gets the orientation of the bed that the entity is sleeping on.
script.zs
// LivingEntity.bedOrientation as Direction
myLivingEntity.bedOrientation

Return Type: Direction

bedOrientation() as Direction
Gets the orientation of the bed that the entity is sleeping on.

Returns: The orientation of the bed that the entity is sleeping on.

script.zs
// LivingEntity.bedOrientation() as Direction;
myLivingEntity.bedOrientation();

Return Type: Direction

Getter
Gets the BlockPos of the entity.
script.zs
// LivingEntity.blockPosiion as BlockPos
myLivingEntity.blockPosiion

Return Type: BlockPos

blockPosiion() as BlockPos
Gets the BlockPos of the entity.

Returns: The BlockPos of the entity.

script.zs
// LivingEntity.blockPosiion() as BlockPos;
myLivingEntity.blockPosiion();

Return Type: BlockPos

Getter
Gets the position of the entity.
script.zs
// LivingEntity.blockPosition as BlockPos
myLivingEntity.blockPosition

Return Type: BlockPos

blockPosition() as BlockPos
Gets the position of the entity.

Returns: The block position of the entity.

script.zs
// LivingEntity.blockPosition() as BlockPos;
myLivingEntity.blockPosition();

Return Type: BlockPos

Getter
Gets the x coordinate of the entity.
script.zs
// LivingEntity.blockX as int
myLivingEntity.blockX

Return Type: int

blockX() as int
Gets the x coordinate of the entity.

Returns: The x coordinate of the entity.

script.zs
// LivingEntity.blockX() as int;
myLivingEntity.blockX();

Return Type: int

Getter
Gets the y coordinate of the entity.
script.zs
// LivingEntity.blockY as int
myLivingEntity.blockY

Return Type: int

blockY() as int
Gets the y coordinate of the entity.

Returns: The y coordinate of the entity.

script.zs
// LivingEntity.blockY() as int;
myLivingEntity.blockY();

Return Type: int

Getter
Gets the z coordinate of the entity.
script.zs
// LivingEntity.blockZ as int
myLivingEntity.blockZ

Return Type: int

blockZ() as int
Gets the z coordinate of the entity.

Returns: The z coordinate of the entity.

script.zs
// LivingEntity.blockZ() as int;
myLivingEntity.blockZ();

Return Type: int

Getter
Gets the bounding box of the entity.
script.zs
// LivingEntity.boundingBox as AABB
myLivingEntity.boundingBox

Return Type: AABB

boundingBox() as AABB
Gets the bounding box of the entity.

Returns: The bounding box of the entity.

script.zs
// LivingEntity.boundingBox() as AABB;
myLivingEntity.boundingBox();

Return Type: AABB

Getter
Gets the bounding box for culling of the entity.
script.zs
// LivingEntity.boundingBoxForCulling as AABB
myLivingEntity.boundingBoxForCulling

Return Type: AABB

boundingBoxForCulling() as AABB
Gets the bounding box for culling of the entity.

Returns: The bounding box for culling of the entity.

script.zs
// LivingEntity.boundingBoxForCulling() as AABB;
myLivingEntity.boundingBoxForCulling();

Return Type: AABB

canAttack(target as LivingEntity) as bool
Checks if this entity can attack a target.

Returns: True if this entity can attack the target, false otherwise.

script.zs
// LivingEntity.canAttack(target as LivingEntity) as bool;
myLivingEntity.canAttack(myLivingEntity);

Parameters:

target Type: LivingEntity - The target to check if this entity can attack.

Return Type: bool

canBeAffected(effectInstance as MobEffectInstance) as bool
Checks if this entity can be affected by a specific effect.

Returns: True if this entity can be affected by the effect, false otherwise.

script.zs
// LivingEntity.canBeAffected(effectInstance as MobEffectInstance) as bool;
myLivingEntity.canBeAffected(myMobEffectInstance);

Parameters:

effectInstance Type: MobEffectInstance - The effect to check if this entity can be affected by.

Return Type: bool

Getter
Checks if the entity can be collided with.
script.zs
// LivingEntity.canBeCollidedWith as bool
myLivingEntity.canBeCollidedWith

Return Type: bool

canBeCollidedWith() as bool
Checks if the entity can be collided with.

Returns: true if the entity can be collided with.

script.zs
// LivingEntity.canBeCollidedWith() as bool;
myLivingEntity.canBeCollidedWith();

Return Type: bool

Getter
Checks if this entity can be seen as an enemy. Some things this checks are if this entity is a player and it is in creative mode, or if this entity is an axolotl if it is playing dead.
script.zs
// LivingEntity.canBeSeenAsEnemy as bool
myLivingEntity.canBeSeenAsEnemy

Return Type: bool

canBeSeenAsEnemy() as bool
Checks if this entity can be seen as an enemy. Some things this checks are if this entity is a player and it is in creative mode, or if this entity is an axolotl if it is playing dead.

Returns: True if this entity can be seen as an enemy, false otherwise.

script.zs
// LivingEntity.canBeSeenAsEnemy() as bool;
myLivingEntity.canBeSeenAsEnemy();

Return Type: bool

Getter
Checks if this entity can be seen by anyone.
script.zs
// LivingEntity.canBeSeenByAnyone as bool
myLivingEntity.canBeSeenByAnyone

Return Type: bool

canBeSeenByAnyone() as bool
Checks if this entity can be seen by anyone.

Returns: True if this entity can be seen by anyone, false otherwise.

script.zs
// LivingEntity.canBeSeenByAnyone() as bool;
myLivingEntity.canBeSeenByAnyone();

Return Type: bool

Getter
Checks if this entity can breathe underwater.
script.zs
// LivingEntity.canBreatheUnderwater as bool
myLivingEntity.canBreatheUnderwater

Return Type: bool

canBreatheUnderwater() as bool
Checks if this entity can breathe underwater.

Returns: True if the entity can breathe underwater, false otherwise.

script.zs
// LivingEntity.canBreatheUnderwater() as bool;
myLivingEntity.canBreatheUnderwater();

Return Type: bool

canCollideWith(other as Entity) as bool
Checks if the entity can collide with the given entity.

Returns: true if the entity can collide with the given entity.

script.zs
// LivingEntity.canCollideWith(other as Entity) as bool;
myLivingEntity.canCollideWith(myEntity);

Parameters:

other Type: Entity - The entity to check if the entity can collide with.

Return Type: bool

Getter
Checks if the entity can freeze.
script.zs
// LivingEntity.canFreeze as bool
myLivingEntity.canFreeze

Return Type: bool

canFreeze() as bool
Checks if the entity can freeze.

Returns: Whether the entity can freeze.

script.zs
// LivingEntity.canFreeze() as bool;
myLivingEntity.canFreeze();

Return Type: bool

canStandOnFluid(fluid as Fluid) as bool
Checks if the entity can stand on a specific fluid.

Returns: True if the entity can stand on the fluid, false otherwise.

script.zs
// LivingEntity.canStandOnFluid(fluid as Fluid) as bool;
myLivingEntity.canStandOnFluid(myFluid);

Parameters:

fluid Type: Fluid - The fluid to check.

Return Type: bool

canTakeItem(stack as ItemStack) as bool
Checks if the item can be worn as armor.

Returns: True if the item can be worn as armor, false otherwise.

script.zs
// LivingEntity.canTakeItem(stack as ItemStack) as bool;
myLivingEntity.canTakeItem(myItemStack);

Parameters:

stack Type: ItemStack - The item to check.

Return Type: bool

clearFire()
Clears the fire of the entity.
script.zs
// LivingEntity.clearFire();
myLivingEntity.clearFire();
clearSleepingPos()
Clears the position that the entity is sleeping at.
script.zs
// LivingEntity.clearSleepingPos();
myLivingEntity.clearSleepingPos();
closerThan(other as Entity, distance as double) as bool
Checks if the entity is closer than the given distance to another entity.

Returns: true if the entity is closer than the given distance to the other entity.

script.zs
// LivingEntity.closerThan(other as Entity, distance as double) as bool;
myLivingEntity.closerThan(myEntity, myDouble);

Parameters:

other Type: Entity - The other entity to check the distance to.
distance Type: double - The distance to check.

Return Type: bool

Getter
Gets the Level used when sending commands as this entity.
script.zs
// LivingEntity.commandSenderWorld as Level
myLivingEntity.commandSenderWorld

Return Type: Level

commandSenderWorld() as Level
Gets the Level used when sending commands as this entity.

Returns: The Level used when sending commands as this entity.

script.zs
// LivingEntity.commandSenderWorld() as Level;
myLivingEntity.commandSenderWorld();

Return Type: Level

Getter
Gets the controlling passenger of the entity.
script.zs
// LivingEntity.controllingPassenger as Entity
myLivingEntity.controllingPassenger

Return Type: Entity

controllingPassenger() as Entity
Gets the controlling passenger of the entity.

Returns: The controlling passenger of the entity.

script.zs
// LivingEntity.controllingPassenger() as Entity;
myLivingEntity.controllingPassenger();

Return Type: Entity

Getter
Gets the custom NBT data for this Entity.
script.zs
// LivingEntity.customData as MapData
myLivingEntity.customData

Return Type: MapData

customData() as MapData
Gets the custom NBT data for this Entity.

Returns: The custom data for this Entity.

script.zs
// LivingEntity.customData() as MapData;
myLivingEntity.customData();

Return Type: MapData

Getter
Gets the custom name of the entity.
script.zs
// LivingEntity.customName as Component
myLivingEntity.customName

Return Type: Component

Getter
script.zs
// LivingEntity.customName as Component
myLivingEntity.customName

Return Type: Component

customName() as Component
Gets the custom name of the entity.

Returns: The custom name of the entity.

script.zs
// LivingEntity.customName() as Component;
myLivingEntity.customName();

Return Type: Component

customName() as Component
script.zs
// LivingEntity.customName() as Component;
myLivingEntity.customName();

Return Type: Component

Getter
Checks if the entity dampens vibrations, such as net.minecraft.world.entity.item.ItemEntitys who's item is in the dampens_vibrations item tag.
script.zs
// LivingEntity.dampensVibrations as bool
myLivingEntity.dampensVibrations

Return Type: bool

dampensVibrations() as bool
Checks if the entity dampens vibrations, such as net.minecraft.world.entity.item.ItemEntitys who's item is in the dampens_vibrations item tag.

Returns: true if the entity dampens vibrations.

script.zs
// LivingEntity.dampensVibrations() as bool;
myLivingEntity.dampensVibrations();

Return Type: bool

Getter
Gets the NBT data of this Entity.
script.zs
// LivingEntity.data as MapData
myLivingEntity.data

Return Type: MapData

data() as MapData
Gets the NBT data of this Entity.

Returns: The NBT data of this Entity.

script.zs
// LivingEntity.data() as MapData;
myLivingEntity.data();

Return Type: MapData

Getter
Gets the delta movement of the entity.
script.zs
// LivingEntity.deltaMovement as Vec3
myLivingEntity.deltaMovement

Return Type: Vec3

Setter
Sets the delta movement of the entity.
script.zs
// LivingEntity.deltaMovement = (deltaMovement as Vec3);
myLivingEntity.deltaMovement = myVec3;

Parameters:

deltaMovement Type: Vec3 - The delta movement to set.
deltaMovement() as Vec3
Gets the delta movement of the entity.

Returns: The delta movement of the entity.

script.zs
// LivingEntity.deltaMovement() as Vec3;
myLivingEntity.deltaMovement();

Return Type: Vec3

deltaMovement(deltaMovement as Vec3)
Sets the delta movement of the entity.
script.zs
// LivingEntity.deltaMovement(deltaMovement as Vec3);
myLivingEntity.deltaMovement(myVec3);

Parameters:

deltaMovement Type: Vec3 - The delta movement to set.
die(source as DamageSource)
Kills this entity.
script.zs
// LivingEntity.die(source as DamageSource);
myLivingEntity.die(myDamageSource);

Parameters:

source Type: DamageSource - The damage source that killed this entity.
Getter
Gets the dimension changing delay of the entity.
script.zs
// LivingEntity.dimensionChangingDelay as int
myLivingEntity.dimensionChangingDelay

Return Type: int

dimensionChangingDelay() as int
Gets the dimension changing delay of the entity.

Returns: The dimension changing delay of the entity.

script.zs
// LivingEntity.dimensionChangingDelay() as int;
myLivingEntity.dimensionChangingDelay();

Return Type: int

Getter
Gets the direction of the entity.
script.zs
// LivingEntity.direction as Direction
myLivingEntity.direction

Return Type: Direction

direction() as Direction
Gets the direction of the entity.

Returns: The direction of the entity.

script.zs
// LivingEntity.direction() as Direction;
myLivingEntity.direction();

Return Type: Direction

discard()
Discards the entity.
script.zs
// LivingEntity.discard();
myLivingEntity.discard();
Getter
Checks if the entity dismounts underwater.
script.zs
// LivingEntity.dismountsUnderwater as bool
myLivingEntity.dismountsUnderwater

Return Type: bool

dismountsUnderwater() as bool
Checks if the entity dismounts underwater.

Returns: true if the entity dismounts underwater.

script.zs
// LivingEntity.dismountsUnderwater() as bool;
myLivingEntity.dismountsUnderwater();

Return Type: bool

Getter
Gets the display name of the entity.
script.zs
// LivingEntity.displayName as Component
myLivingEntity.displayName

Return Type: Component

Getter
script.zs
// LivingEntity.displayName as Component
myLivingEntity.displayName

Return Type: Component

displayName() as Component
Gets the display name of the entity.

Returns: The display name of the entity.

script.zs
// LivingEntity.displayName() as Component;
myLivingEntity.displayName();

Return Type: Component

displayName() as Component
script.zs
// LivingEntity.displayName() as Component;
myLivingEntity.displayName();

Return Type: Component

distanceTo(entity as Entity) as float
Gets the distance to the given entity.

Returns: The distance to the given entity.

script.zs
// LivingEntity.distanceTo(entity as Entity) as float;
myLivingEntity.distanceTo(myEntity);

Parameters:

entity Type: Entity - The entity to get the distance to.

Return Type: float

distanceToSqr(x as double, y as double, z as double) as double
Gets the squared distance to the given position.

Returns: The squared distance to the given position.

script.zs
// LivingEntity.distanceToSqr(x as double, y as double, z as double) as double;
myLivingEntity.distanceToSqr(myDouble, myDouble, myDouble);

Parameters:

x Type: double - The x position to get the squared distance to.
y Type: double - The y position to get the squared distance to.
z Type: double - The z position to get the squared distance to.

Return Type: double

distanceToSqr(entity as Entity) as double
Gets the squared distance to the given entity.

Returns: The squared distance to the given entity.

script.zs
// LivingEntity.distanceToSqr(entity as Entity) as double;
myLivingEntity.distanceToSqr(myEntity);

Parameters:

entity Type: Entity - The entity to get the squared distance to.

Return Type: double

distanceToSqr(vec as Vec3) as double
Gets the squared distance to the given vector.

Returns: The squared distance to the given vector.

script.zs
// LivingEntity.distanceToSqr(vec as Vec3) as double;
myLivingEntity.distanceToSqr(myVec3);

Parameters:

vec Type: Vec3 - The vector to get the squared distance to.

Return Type: double

doHurtTarget(entity as Entity) as bool
script.zs
// LivingEntity.doHurtTarget(entity as Entity) as bool;
myLivingEntity.doHurtTarget(myEntity);

Parameters:

entity Type: Entity

Return Type: bool

eat(level as Level, stack as ItemStack) as ItemStack
Eats an item.

Returns: The item that the entity ate.

script.zs
// LivingEntity.eat(level as Level, stack as ItemStack) as ItemStack;
myLivingEntity.eat(myLevel, myItemStack);

Parameters:

level Type: Level - The level that the entity is in.
stack Type: ItemStack - The item to eat.

Return Type: ItemStack

ejectPassengers()
Ejects the passengers of the entity.
script.zs
// LivingEntity.ejectPassengers();
myLivingEntity.ejectPassengers();
Getter
Gets the eye height of the entity.
script.zs
// LivingEntity.eyeHeight as float
myLivingEntity.eyeHeight

Return Type: float

eyeHeight() as float
Gets the eye height of the entity.

Returns: The eye height of the entity.

script.zs
// LivingEntity.eyeHeight() as float;
myLivingEntity.eyeHeight();

Return Type: float

Getter
Gets the eye position of the entity.
script.zs
// LivingEntity.eyePosition as Vec3
myLivingEntity.eyePosition

Return Type: Vec3

eyePosition() as Vec3
Gets the eye position of the entity.

Returns: The eye position of the entity.

script.zs
// LivingEntity.eyePosition() as Vec3;
myLivingEntity.eyePosition();

Return Type: Vec3

Getter
Gets the y coordinate of the entity's eyes.
script.zs
// LivingEntity.eyeY as double
myLivingEntity.eyeY

Return Type: double

eyeY() as double
Gets the y coordinate of the entity's eyes.

Returns: The y coordinate of the entity's eyes.

script.zs
// LivingEntity.eyeY() as double;
myLivingEntity.eyeY();

Return Type: double

Getter
Gets the ticks that the entity has been flying with an elytra.
script.zs
// LivingEntity.fallFlyingTicks as int
myLivingEntity.fallFlyingTicks

Return Type: int

fallFlyingTicks() as int
Gets the ticks that the entity has been flying with an elytra.

Returns: The ticks that the entity has been flying with an elytra.

script.zs
// LivingEntity.fallFlyingTicks() as int;
myLivingEntity.fallFlyingTicks();

Return Type: int

Getter
Checks if the entity is fire immune.
script.zs
// LivingEntity.fireImmune as bool
myLivingEntity.fireImmune

Return Type: bool

fireImmune() as bool
Checks if the entity is fire immune.

Returns: true if the entity is fire immune.

script.zs
// LivingEntity.fireImmune() as bool;
myLivingEntity.fireImmune();

Return Type: bool

Getter
Gets the remaining fire ticks of the entity.
script.zs
// LivingEntity.fireTicks as int
myLivingEntity.fireTicks

Return Type: int

Setter
Sets the remaining fire ticks of the entity.
script.zs
// LivingEntity.fireTicks = (ticks as int);
myLivingEntity.fireTicks = myInt;

Parameters:

ticks Type: int - The number of ticks to set the remaining fire ticks to.
fireTicks(ticks as int)
Sets the remaining fire ticks of the entity.
script.zs
// LivingEntity.fireTicks(ticks as int);
myLivingEntity.fireTicks(myInt);

Parameters:

ticks Type: int - The number of ticks to set the remaining fire ticks to.
fireTicks() as int
Gets the remaining fire ticks of the entity.

Returns: The remaining fire ticks of the entity.

script.zs
// LivingEntity.fireTicks() as int;
myLivingEntity.fireTicks();

Return Type: int

Getter
Gets the first passenger of the entity.
script.zs
// LivingEntity.firstPassenger as Entity
myLivingEntity.firstPassenger

Return Type: Entity

firstPassenger() as Entity
Gets the first passenger of the entity.

Returns: The first passenger of the entity.

script.zs
// LivingEntity.firstPassenger() as Entity;
myLivingEntity.firstPassenger();

Return Type: Entity

Getter
Gets the fluid jump threshold of the entity.
script.zs
// LivingEntity.fluidJumpThreshold as double
myLivingEntity.fluidJumpThreshold

Return Type: double

fluidJumpThreshold() as double
Gets the fluid jump threshold of the entity.

Returns: The fluid jump threshold of the entity.

script.zs
// LivingEntity.fluidJumpThreshold() as double;
myLivingEntity.fluidJumpThreshold();

Return Type: double

forceAddEffect(effectInstance as MobEffectInstance, entity as Entity)
Forces this entity to have a specific effect, this does not force effects that can't affect this entity.
script.zs
// LivingEntity.forceAddEffect(effectInstance as MobEffectInstance, entity as Entity);
myLivingEntity.forceAddEffect(myMobEffectInstance, myEntity);

Parameters:

effectInstance Type: MobEffectInstance - The effect to force this entity to have.
entity Type: Entity - The entity that is the source of the effect.
Getter
Gets the forward vector of the entity.
script.zs
// LivingEntity.forward as Vec3
myLivingEntity.forward

Return Type: Vec3

forward() as Vec3
Gets the forward vector of the entity.

Returns: The forward vector of the entity.

script.zs
// LivingEntity.forward() as Vec3;
myLivingEntity.forward();

Return Type: Vec3

getAttachmentData(type as AttachmentType<T>) as T
script.zs
// LivingEntity.getAttachmentData<T>(type as AttachmentType<T>) as T;
myLivingEntity.getAttachmentData<T>(myAttachmentType);

Parameters:

type Type: AttachmentType<T>

Return Type: T

getAttachmentData(type as Supplier<AttachmentType<T>>) as T
script.zs
// LivingEntity.getAttachmentData<T>(type as Supplier<AttachmentType<T>>) as T;
myLivingEntity.getAttachmentData<T>(mySupplier);

Parameters:

type Type: Supplier<AttachmentType<T>>

Return Type: T

getAttribute(attribute as Attribute) as AttributeInstance
Gets the attribute for this entity.

Returns: The attribute.

script.zs
// LivingEntity.getAttribute(attribute as Attribute) as AttributeInstance;
myLivingEntity.getAttribute(myAttribute);

Parameters:

attribute Type: Attribute - The attribute to get.

Return Type: AttributeInstance

getAttributeBaseValue(attribute as Attribute) as double
Gets the base attribute value for this entity.

Returns: The base attribute value.

script.zs
// LivingEntity.getAttributeBaseValue(attribute as Attribute) as double;
myLivingEntity.getAttributeBaseValue(myAttribute);

Parameters:

attribute Type: Attribute - The attribute to get the base value of.

Return Type: double

getAttributeValue(attribute as Attribute) as double
Gets the attribute value for this entity.

Returns: The attribute value.

script.zs
// LivingEntity.getAttributeValue(attribute as Attribute) as double;
myLivingEntity.getAttributeValue(myAttribute);

Parameters:

attribute Type: Attribute - The attribute to get the value of.

Return Type: double

getEffect(effect as MobEffect) as MobEffectInstance
Gets the MobEffectInstance for the given effect on this entity.

Returns: The effect instance.

script.zs
// LivingEntity.getEffect(effect as MobEffect) as MobEffectInstance;
myLivingEntity.getEffect(myMobEffect);

Parameters:

effect Type: MobEffect - The effect to get.

Return Type: MobEffectInstance

getEyePosition(partialTicks as float) as Vec3
Gets the eye position of the entity.

Returns: The eye position of the entity.

script.zs
// LivingEntity.getEyePosition(partialTicks as float) as Vec3;
myLivingEntity.getEyePosition(myFloat);

Parameters:

partialTicks Type: float - The partial ticks to get the eye position for.

Return Type: Vec3

getItemBySlot(slot as EquipmentSlot) as ItemStack
Gets the item in a specific slot.

Returns: The item in the slot.

script.zs
// LivingEntity.getItemBySlot(slot as EquipmentSlot) as ItemStack;
myLivingEntity.getItemBySlot(myEquipmentSlot);

Parameters:

slot Type: EquipmentSlot - The slot to get the item from.

Return Type: ItemStack

getItemInHand(hand as InteractionHand) as ItemStack
Gets the item in the entity's hand.

Returns: The item in the hand.

script.zs
// LivingEntity.getItemInHand(hand as InteractionHand) as ItemStack;
myLivingEntity.getItemInHand(myInteractionHand);

Parameters:

hand Type: InteractionHand - The hand to get the item from.

Return Type: ItemStack

getPosition(partialTicks as float) as Vec3
Gets the position of the entity.

Returns: The position of the entity.

script.zs
// LivingEntity.getPosition(partialTicks as float) as Vec3;
myLivingEntity.getPosition(myFloat);

Parameters:

partialTicks Type: float - The partial ticks to get the position for.

Return Type: Vec3

getSwimAmount(partialTicks as float) as float
Gets the swim amount.

Returns: The swim amount.

script.zs
// LivingEntity.getSwimAmount(partialTicks as float) as float;
myLivingEntity.getSwimAmount(myFloat);

Parameters:

partialTicks Type: float - The partial ticks to get the swim amount for.

Return Type: float

getUpVector(partialTicks as float) as Vec3
Gets the up vector of the entity.

Returns: The up vector of the entity.

script.zs
// LivingEntity.getUpVector(partialTicks as float) as Vec3;
myLivingEntity.getUpVector(myFloat);

Parameters:

partialTicks Type: float - The partial ticks to get the up vector for.

Return Type: Vec3

getViewVector(partialTicks as float) as Vec3
Gets the view vector of the entity.

Returns: The view vector of the entity.

script.zs
// LivingEntity.getViewVector(partialTicks as float) as Vec3;
myLivingEntity.getViewVector(myFloat);

Parameters:

partialTicks Type: float - The partial ticks to get the view vector for.

Return Type: Vec3

getVisibilityPercent(lookingEntity as Entity) as double
Gets the visibility percent for this entity.

Returns: The visibility percent.

script.zs
// LivingEntity.getVisibilityPercent(lookingEntity as Entity) as double;
myLivingEntity.getVisibilityPercent(myEntity);

Parameters:

lookingEntity Type: Entity - The entity that is looking at this entity.

Return Type: double

getX(scale as double) as double
Gets the x coordinate of the entity with the given scale.

Returns: The x coordinate of the entity.

script.zs
// LivingEntity.getX(scale as double) as double;
myLivingEntity.getX(myDouble);

Parameters:

scale Type: double - The scale to get the x coordinate of the entity.

Return Type: double

getY(scale as double) as double
Gets the y coordinate of the entity with the given scale.

Returns: The y coordinate of the entity.

script.zs
// LivingEntity.getY(scale as double) as double;
myLivingEntity.getY(myDouble);

Parameters:

scale Type: double - The scale to get the y coordinate of the entity.

Return Type: double

getZ(scale as double) as double
Gets the z coordinate of the entity with the given scale.

Returns: The z coordinate of the entity.

script.zs
// LivingEntity.getZ(scale as double) as double;
myLivingEntity.getZ(myDouble);

Parameters:

scale Type: double - The scale to get the z coordinate of the entity.

Return Type: double

Getter
Gets this entity's held items.
script.zs
// LivingEntity.handSlots as Iterable<ItemStack>
myLivingEntity.handSlots

Return Type: Iterable<ItemStack>

handSlots() as Iterable<ItemStack>
Gets this entity's held items.

Returns: An iterable of item stacks representing the held items.

script.zs
// LivingEntity.handSlots() as Iterable<ItemStack>;
myLivingEntity.handSlots();

Return Type: Iterable<ItemStack>

hasAttachmentData(type as AttachmentType<T>) as bool
script.zs
// LivingEntity.hasAttachmentData<T>(type as AttachmentType<T>) as bool;
myLivingEntity.hasAttachmentData<T>(myAttachmentType);

Parameters:

type Type: AttachmentType<T>

Return Type: bool

hasAttachmentData(type as Supplier<AttachmentType<T>>) as bool
script.zs
// LivingEntity.hasAttachmentData<T>(type as Supplier<AttachmentType<T>>) as bool;
myLivingEntity.hasAttachmentData<T>(mySupplier);

Parameters:

type Type: Supplier<AttachmentType<T>>

Return Type: bool

Getter
Checks if the entity has a custom name.
script.zs
// LivingEntity.hasCustomName as bool
myLivingEntity.hasCustomName

Return Type: bool

Getter
script.zs
// LivingEntity.hasCustomName as bool
myLivingEntity.hasCustomName

Return Type: bool

hasCustomName() as bool
Checks if the entity has a custom name.

Returns: true if the entity has a custom name.

script.zs
// LivingEntity.hasCustomName() as bool;
myLivingEntity.hasCustomName();

Return Type: bool

hasCustomName() as bool
script.zs
// LivingEntity.hasCustomName() as bool;
myLivingEntity.hasCustomName();

Return Type: bool

hasEffect(effect as MobEffect) as bool
Checks if this entity has a specific effect.

Returns: True if this entity has the effect, false otherwise.

script.zs
// LivingEntity.hasEffect(effect as MobEffect) as bool;
myLivingEntity.hasEffect(myMobEffect);

Parameters:

effect Type: MobEffect - The effect to check if this entity has.

Return Type: bool

Getter
Checks if the entity has exactly one player passenger.
script.zs
// LivingEntity.hasExactlyOnePlayerPassenger as bool
myLivingEntity.hasExactlyOnePlayerPassenger

Return Type: bool

hasExactlyOnePlayerPassenger() as bool
Checks if the entity has exactly one player passenger.

Returns: true if the entity has exactly one player passenger.

script.zs
// LivingEntity.hasExactlyOnePlayerPassenger() as bool;
myLivingEntity.hasExactlyOnePlayerPassenger();

Return Type: bool

Getter
Checks if the entity is currently glowing.
script.zs
// LivingEntity.hasGlowingTag as bool
myLivingEntity.hasGlowingTag

Return Type: bool

hasGlowingTag() as bool
Checks if the entity is currently glowing.

Returns: true if the entity is currently glowing.

script.zs
// LivingEntity.hasGlowingTag() as bool;
myLivingEntity.hasGlowingTag();

Return Type: bool

hasIndirectPassenger(entity as Entity) as bool
Checks if the entity has an indirect passenger.

Returns: true if the entity has an indirect passenger.

script.zs
// LivingEntity.hasIndirectPassenger(entity as Entity) as bool;
myLivingEntity.hasIndirectPassenger(myEntity);

Parameters:

entity Type: Entity - The entity to check.

Return Type: bool

hasItemInSlot(slot as EquipmentSlot) as bool
Checks if the entity has an item in a specific slot.

Returns: True if the entity has an item in the slot, false otherwise.

script.zs
// LivingEntity.hasItemInSlot(slot as EquipmentSlot) as bool;
myLivingEntity.hasItemInSlot(myEquipmentSlot);

Parameters:

slot Type: EquipmentSlot - The slot to check.

Return Type: bool

hasLineOfSight(entity as Entity) as bool
Checks if this entity has a line of sight to a specific entity.

Returns: True if the entity has a line of sight to the entity, false otherwise.

script.zs
// LivingEntity.hasLineOfSight(entity as Entity) as bool;
myLivingEntity.hasLineOfSight(myEntity);

Parameters:

entity Type: Entity - The entity to check the line of sight to.

Return Type: bool

hasPassenger(entity as Entity) as bool
Checks if the entity has a passenger.

Returns: true if the entity has the given passenger.

script.zs
// LivingEntity.hasPassenger(entity as Entity) as bool;
myLivingEntity.hasPassenger(myEntity);

Parameters:

entity Type: Entity - The entity to check.

Return Type: bool

hasPassenger(predicate as function(t as Entity) as bool) as bool
Checks if the entity has a passenger that matches the given predicate.

Returns: true if the entity has a passenger that matches the predicate.

script.zs
// LivingEntity.hasPassenger(predicate as function(t as Entity) as bool) as bool;
myLivingEntity.hasPassenger(myPredicate);

Parameters:

predicate Type: function(t as Entity) as bool - The predicate to check.

Return Type: bool

heal(amount as float)
Heals this entity.
script.zs
// LivingEntity.heal(amount as float);
myLivingEntity.heal(myFloat);

Parameters:

amount Type: float - The amount to heal.
Getter
Gets the health of this entity.
script.zs
// LivingEntity.health as float
myLivingEntity.health

Return Type: float

health() as float
Gets the health of this entity.

Returns: The health of this entity.

script.zs
// LivingEntity.health() as float;
myLivingEntity.health();

Return Type: float

hurt(source as DamageSource, amount as float) as bool
Hurts the entity with the given DamageSource and amount.

Returns: true if the entity was hurt.

script.zs
// LivingEntity.hurt(source as DamageSource, amount as float) as bool;
myLivingEntity.hurt(myDamageSource, myFloat);

Parameters:

source Type: DamageSource - The DamageSource to hurt the entity with.
amount Type: float - The amount of damage to deal.

Return Type: bool

Getter
Gets the ID of the entity.
script.zs
// LivingEntity.id as int
myLivingEntity.id

Return Type: int

id() as int
Gets the ID of the entity.

Returns: The ID of the entity.

script.zs
// LivingEntity.id() as int;
myLivingEntity.id();

Return Type: int

Getter
Gets the BlockState that this entity is currently inside.
script.zs
// LivingEntity.inBlockState as BlockState
myLivingEntity.inBlockState

Return Type: BlockState

inBlockState() as BlockState
Gets the BlockState that this entity is currently inside.

Returns: The block state that this entity is currently inside

script.zs
// LivingEntity.inBlockState() as BlockState;
myLivingEntity.inBlockState();

Return Type: BlockState

Getter
Checks if the entity is affected by potions, entities such as armor stands are not affected by potions.
script.zs
// LivingEntity.isAffectedByPotions as bool
myLivingEntity.isAffectedByPotions

Return Type: bool

isAffectedByPotions() as bool
Checks if the entity is affected by potions, entities such as armor stands are not affected by potions.

Returns: True if the entity is affected by potions, false otherwise.

script.zs
// LivingEntity.isAffectedByPotions() as bool;
myLivingEntity.isAffectedByPotions();

Return Type: bool

Getter
Checks if the entity is alive.
script.zs
// LivingEntity.isAlive as bool
myLivingEntity.isAlive

Return Type: bool

isAlive() as bool
Checks if the entity is alive.

Returns: true if the entity is alive.

script.zs
// LivingEntity.isAlive() as bool;
myLivingEntity.isAlive();

Return Type: bool

Getter
Checks if the entity is always ticking.
script.zs
// LivingEntity.isAlwaysTicking as bool
myLivingEntity.isAlwaysTicking

Return Type: bool

isAlwaysTicking() as bool
Checks if the entity is always ticking.

Returns: true if the entity is always ticking.

script.zs
// LivingEntity.isAlwaysTicking() as bool;
myLivingEntity.isAlwaysTicking();

Return Type: bool

Getter
Checks if the entity is attackable.
script.zs
// LivingEntity.isAttackable as bool
myLivingEntity.isAttackable

Return Type: bool

isAttackable() as bool
Checks if the entity is attackable.

Returns: true if the entity is attackable.

script.zs
// LivingEntity.isAttackable() as bool;
myLivingEntity.isAttackable();

Return Type: bool

Getter
Checks if this entity is performing an auto spin attack.
script.zs
// LivingEntity.isAutoSpinAttack as bool
myLivingEntity.isAutoSpinAttack

Return Type: bool

isAutoSpinAttack() as bool
Checks if this entity is performing an auto spin attack.

Returns: True if the entity is performing an auto spin attack, false otherwise.

script.zs
// LivingEntity.isAutoSpinAttack() as bool;
myLivingEntity.isAutoSpinAttack();

Return Type: bool

Getter
Checks if this entity is a baby.
script.zs
// LivingEntity.isBaby as bool
myLivingEntity.isBaby

Return Type: bool

isBaby() as bool
Checks if this entity is a baby.

Returns: True if the entity is a baby, false otherwise.

script.zs
// LivingEntity.isBaby() as bool;
myLivingEntity.isBaby();

Return Type: bool

Getter
Checks if the entity is blocking.
script.zs
// LivingEntity.isBlocking as bool
myLivingEntity.isBlocking

Return Type: bool

isBlocking() as bool
Checks if the entity is blocking.

Returns: True if the entity is blocking, false otherwise.

script.zs
// LivingEntity.isBlocking() as bool;
myLivingEntity.isBlocking();

Return Type: bool

isColliding(pos as BlockPos, state as BlockState) as bool
Checks if this entity is colliding with the given BlockState at the given BlockPos.

Returns: true if the entity is colliding with the block.

script.zs
// LivingEntity.isColliding(pos as BlockPos, state as BlockState) as bool;
myLivingEntity.isColliding(myBlockPos, myBlockState);

Parameters:

pos Type: BlockPos - The position of the block to check.
state Type: BlockState - The state of the block to check.

Return Type: bool

Getter
Checks if the entity is crouching.
script.zs
// LivingEntity.isCrouching as bool
myLivingEntity.isCrouching

Return Type: bool

isCrouching() as bool
Checks if the entity is crouching.

Returns: true if the entity is crouching.

script.zs
// LivingEntity.isCrouching() as bool;
myLivingEntity.isCrouching();

Return Type: bool

Getter
Checks if the entity is currently glowing.
script.zs
// LivingEntity.isCurrentlyGlowing as bool
myLivingEntity.isCurrentlyGlowing

Return Type: bool

isCurrentlyGlowing() as bool
Checks if the entity is currently glowing.

Returns: True if the entity is currently glowing, false otherwise.

script.zs
// LivingEntity.isCurrentlyGlowing() as bool;
myLivingEntity.isCurrentlyGlowing();

Return Type: bool

Getter
Checks if the custom name of the entity is visible.
script.zs
// LivingEntity.isCustomNameVisible as bool
myLivingEntity.isCustomNameVisible

Return Type: bool

isCustomNameVisible() as bool
Checks if the custom name of the entity is visible.

Returns: true if the custom name is visible.

script.zs
// LivingEntity.isCustomNameVisible() as bool;
myLivingEntity.isCustomNameVisible();

Return Type: bool

isDamageSourceBlocked(source as DamageSource) as bool
Determines whether the entity can block the damage source based on the damage source's location, whether the damage source is blockable, and whether the entity is blocking.

Returns: True if the entity can block the damage source, false otherwise.

script.zs
// LivingEntity.isDamageSourceBlocked(source as DamageSource) as bool;
myLivingEntity.isDamageSourceBlocked(myDamageSource);

Parameters:

source Type: DamageSource - The damage source to check.

Return Type: bool

Getter
Checks if this entity is dead or dying.
script.zs
// LivingEntity.isDeadOrDying as bool
myLivingEntity.isDeadOrDying

Return Type: bool

isDeadOrDying() as bool
Checks if this entity is dead or dying.

Returns: True if this entity is dead or dying, false otherwise.

script.zs
// LivingEntity.isDeadOrDying() as bool;
myLivingEntity.isDeadOrDying();

Return Type: bool

Getter
Checks if the entity is descending.
script.zs
// LivingEntity.isDescending as bool
myLivingEntity.isDescending

Return Type: bool

isDescending() as bool
Checks if the entity is descending.

Returns: true if the entity is descending.

script.zs
// LivingEntity.isDescending() as bool;
myLivingEntity.isDescending();

Return Type: bool

Getter
Checks if the entity is being discrete.
script.zs
// LivingEntity.isDiscrete as bool
myLivingEntity.isDiscrete

Return Type: bool

isDiscrete() as bool
Checks if the entity is being discrete.

Returns: true if the entity is being discrete.

script.zs
// LivingEntity.isDiscrete() as bool;
myLivingEntity.isDiscrete();

Return Type: bool

Getter
Checks if the entity is flying with an elytra.
script.zs
// LivingEntity.isFallFlying as bool
myLivingEntity.isFallFlying

Return Type: bool

isFallFlying() as bool
Checks if the entity is flying with an elytra.

Returns: True if the entity is flying with an elytra, false otherwise.

script.zs
// LivingEntity.isFallFlying() as bool;
myLivingEntity.isFallFlying();

Return Type: bool

isFree(x as double, y as double, z as double) as bool
Checks if the offset position from the entity's current position has a collision with a block or a liquid.

Returns: true if the entity is free to move in the given position.

script.zs
// LivingEntity.isFree(x as double, y as double, z as double) as bool;
myLivingEntity.isFree(myDouble, myDouble, myDouble);

Parameters:

x Type: double - The x position to check.
y Type: double - The y position to check.
z Type: double - The z position to check.

Return Type: bool

Getter
Checks if the entity is fully frozen.
script.zs
// LivingEntity.isFullyFrozen as bool
myLivingEntity.isFullyFrozen

Return Type: bool

isFullyFrozen() as bool
Checks if the entity is fully frozen.

Returns: true if the entity is fully frozen.

script.zs
// LivingEntity.isFullyFrozen() as bool;
myLivingEntity.isFullyFrozen();

Return Type: bool

isHolding(item as Item) as bool
Checks if the entity is holding an item in their hand.

Returns: True if the entity is holding the item, false otherwise.

script.zs
// LivingEntity.isHolding(item as ItemDefinition) as bool;
myLivingEntity.isHolding(myItem);

Parameters:

item Type: ItemDefinition - The item to check.

Return Type: bool

isHolding(predicate as function(t as ItemStack) as bool) as bool
Checks if the entity is holding an item in their hand.

Returns: True if the entity is holding the item, false otherwise.

script.zs
// LivingEntity.isHolding(predicate as function(t as ItemStack) as bool) as bool;
myLivingEntity.isHolding(myPredicate);

Parameters:

predicate Type: function(t as ItemStack) as bool - The predicate to check.

Return Type: bool

Getter
Checks if the entity is in lava.
script.zs
// LivingEntity.isInLava as bool
myLivingEntity.isInLava

Return Type: bool

isInLava() as bool
Checks if the entity is in lava.

Returns: true if the entity is in lava.

script.zs
// LivingEntity.isInLava() as bool;
myLivingEntity.isInLava();

Return Type: bool

Getter
Checks if this entity is inverted for heal and harm. This usually happens for undead mobs where potions of healing with harm them.
script.zs
// LivingEntity.isInvertedHealAndHarm as bool
myLivingEntity.isInvertedHealAndHarm

Return Type: bool

isInvertedHealAndHarm() as bool
Checks if this entity is inverted for heal and harm. This usually happens for undead mobs where potions of healing with harm them.

Returns: True if this entity is inverted for heal and harm, false otherwise.

script.zs
// LivingEntity.isInvertedHealAndHarm() as bool;
myLivingEntity.isInvertedHealAndHarm();

Return Type: bool

Getter
Checks if the entity is invisible.
script.zs
// LivingEntity.isInvisible as bool
myLivingEntity.isInvisible

Return Type: bool

isInvisible() as bool
Checks if the entity is invisible.

Returns: true if the entity is invisible.

script.zs
// LivingEntity.isInvisible() as bool;
myLivingEntity.isInvisible();

Return Type: bool

isInvisibleTo(player as Player) as bool
Checks if the entity is invisible to the given Player.

Returns: true if the entity is invisible to the player.

script.zs
// LivingEntity.isInvisibleTo(player as Player) as bool;
myLivingEntity.isInvisibleTo(myPlayer);

Parameters:

player Type: Player - The player to check.

Return Type: bool

Getter
Checks if the entity is invulnerable.
script.zs
// LivingEntity.isInvulnerable as bool
myLivingEntity.isInvulnerable

Return Type: bool

isInvulnerable() as bool
Checks if the entity is invulnerable.

Returns: true if the entity is invulnerable.

script.zs
// LivingEntity.isInvulnerable() as bool;
myLivingEntity.isInvulnerable();

Return Type: bool

isInvulnerableTo(source as DamageSource) as bool
Checks if the entity is invulnerable to the given DamageSource.

Returns: true if the entity is invulnerable to the damage source.

script.zs
// LivingEntity.isInvulnerableTo(source as DamageSource) as bool;
myLivingEntity.isInvulnerableTo(myDamageSource);

Parameters:

source Type: DamageSource - The damage source to check.

Return Type: bool

Getter
Checks if the entity is in a wall.
script.zs
// LivingEntity.isInWall as bool
myLivingEntity.isInWall

Return Type: bool

isInWall() as bool
Checks if the entity is in a wall.

Returns: true if the entity is in a wall.

script.zs
// LivingEntity.isInWall() as bool;
myLivingEntity.isInWall();

Return Type: bool

Getter
Checks if the entity is in water.
script.zs
// LivingEntity.isInWater as bool
myLivingEntity.isInWater

Return Type: bool

isInWater() as bool
Checks if the entity is in water.

Returns: true if the entity is in water.

script.zs
// LivingEntity.isInWater() as bool;
myLivingEntity.isInWater();

Return Type: bool

Getter
Checks if the entity is in water or a bubble column.
script.zs
// LivingEntity.isInWaterOrBubble as bool
myLivingEntity.isInWaterOrBubble

Return Type: bool

isInWaterOrBubble() as bool
Checks if the entity is in water or a bubble column.

Returns: true if the entity is in water or a bubble column.

script.zs
// LivingEntity.isInWaterOrBubble() as bool;
myLivingEntity.isInWaterOrBubble();

Return Type: bool

Getter
Checks if the entity is in water or rain.
script.zs
// LivingEntity.isInWaterOrRain as bool
myLivingEntity.isInWaterOrRain

Return Type: bool

isInWaterOrRain() as bool
Checks if the entity is in water or rain.

Returns: true if the entity is in water or rain.

script.zs
// LivingEntity.isInWaterOrRain() as bool;
myLivingEntity.isInWaterOrRain();

Return Type: bool

Getter
Checks if the entity is in water or rain or a bubble column.
script.zs
// LivingEntity.isInWaterRainOrBubble as bool
myLivingEntity.isInWaterRainOrBubble

Return Type: bool

isInWaterRainOrBubble() as bool
Checks if the entity is in water or rain or a bubble column.

Returns: true if the entity is in water or rain or a bubble column.

script.zs
// LivingEntity.isInWaterRainOrBubble() as bool;
myLivingEntity.isInWaterRainOrBubble();

Return Type: bool

Getter
Checks if the entity has no gravity.
script.zs
// LivingEntity.isNoGravity as bool
myLivingEntity.isNoGravity

Return Type: bool

isNoGravity() as bool
Checks if the entity has no gravity.

Returns: true if the entity has no gravity.

script.zs
// LivingEntity.isNoGravity() as bool;
myLivingEntity.isNoGravity();

Return Type: bool

Getter
Checks if the entity is on fire.
script.zs
// LivingEntity.isOnFire as bool
myLivingEntity.isOnFire

Return Type: bool

isOnFire() as bool
Checks if the entity is on fire.

Returns: true if the entity is on fire.

script.zs
// LivingEntity.isOnFire() as bool;
myLivingEntity.isOnFire();

Return Type: bool

Getter
Checks if the entity is on portal cooldown.
script.zs
// LivingEntity.isOnPortalCooldown as bool
myLivingEntity.isOnPortalCooldown

Return Type: bool

isOnPortalCooldown() as bool
Checks if the entity is on portal cooldown.

Returns: true if the entity is on portal cooldown.

script.zs
// LivingEntity.isOnPortalCooldown() as bool;
myLivingEntity.isOnPortalCooldown();

Return Type: bool

Getter
Checks if the entity is a passenger.
script.zs
// LivingEntity.isPassenger as bool
myLivingEntity.isPassenger

Return Type: bool

isPassenger() as bool
Checks if the entity is a passenger.

Returns: true if the entity is a passenger.

script.zs
// LivingEntity.isPassenger() as bool;
myLivingEntity.isPassenger();

Return Type: bool

isPassengerOfSameVehicle(entity as Entity) as bool
Checks if the entity is a passenger of the same vehicle.

Returns: true if the entity is a passenger of the same vehicle.

script.zs
// LivingEntity.isPassengerOfSameVehicle(entity as Entity) as bool;
myLivingEntity.isPassengerOfSameVehicle(myEntity);

Parameters:

entity Type: Entity - The entity to check.

Return Type: bool

Getter
Checks if the entity is pickable.
script.zs
// LivingEntity.isPickable as bool
myLivingEntity.isPickable

Return Type: bool

isPickable() as bool
Checks if the entity is pickable.

Returns: true if the entity is pickable.

script.zs
// LivingEntity.isPickable() as bool;
myLivingEntity.isPickable();

Return Type: bool

Getter
Checks if the entity is pushable.
script.zs
// LivingEntity.isPushable as bool
myLivingEntity.isPushable

Return Type: bool

isPushable() as bool
Checks if the entity is pushable.

Returns: true if the entity is pushable.

script.zs
// LivingEntity.isPushable() as bool;
myLivingEntity.isPushable();

Return Type: bool

Getter
Checks if the entity is pushed by fluid.
script.zs
// LivingEntity.isPushedByFluid as bool
myLivingEntity.isPushedByFluid

Return Type: bool

isPushedByFluid() as bool
Checks if the entity is pushed by fluid.

Returns: true if the entity is pushed by fluid.

script.zs
// LivingEntity.isPushedByFluid() as bool;
myLivingEntity.isPushedByFluid();

Return Type: bool

Getter
Checks if the entity has been removed.
script.zs
// LivingEntity.isRemoved as bool
myLivingEntity.isRemoved

Return Type: bool

isRemoved() as bool
Checks if the entity has been removed.

Returns: Whether the entity has been removed.

script.zs
// LivingEntity.isRemoved() as bool;
myLivingEntity.isRemoved();

Return Type: bool

Getter
Checks if this entity is sensitive to water, meaning that it will take damage from being in water.
script.zs
// LivingEntity.isSensitiveToWater as bool
myLivingEntity.isSensitiveToWater

Return Type: bool

isSensitiveToWater() as bool
Checks if this entity is sensitive to water, meaning that it will take damage from being in water.

Returns: True if the entity is sensitive to water, false otherwise.

script.zs
// LivingEntity.isSensitiveToWater() as bool;
myLivingEntity.isSensitiveToWater();

Return Type: bool

Getter
Checks if the shift key is down.
script.zs
// LivingEntity.isShiftKeyDown as bool
myLivingEntity.isShiftKeyDown

Return Type: bool

isShiftKeyDown() as bool
Checks if the shift key is down.

Returns: true if the shift key is down.

script.zs
// LivingEntity.isShiftKeyDown() as bool;
myLivingEntity.isShiftKeyDown();

Return Type: bool

Getter
Checks if the entity is silent, meaning it won't play any sounds.
script.zs
// LivingEntity.isSilent as bool
myLivingEntity.isSilent

Return Type: bool

isSilent() as bool
Checks if the entity is silent, meaning it won't play any sounds.

Returns: true if the entity is silent.

script.zs
// LivingEntity.isSilent() as bool;
myLivingEntity.isSilent();

Return Type: bool

Getter
Checks if the entity is sleeping.
script.zs
// LivingEntity.isSleeping as bool
myLivingEntity.isSleeping

Return Type: bool

isSleeping() as bool
Checks if the entity is sleeping.

Returns: True if the entity is sleeping, false otherwise.

script.zs
// LivingEntity.isSleeping() as bool;
myLivingEntity.isSleeping();

Return Type: bool

Getter
Checks if the entity is a spectator.
script.zs
// LivingEntity.isSpectator as bool
myLivingEntity.isSpectator

Return Type: bool

isSpectator() as bool
Checks if the entity is a spectator.

Returns: true if the entity is a spectator.

script.zs
// LivingEntity.isSpectator() as bool;
myLivingEntity.isSpectator();

Return Type: bool

Getter
Checks if the entity is sprinting.
script.zs
// LivingEntity.isSprinting as bool
myLivingEntity.isSprinting

Return Type: bool

isSprinting() as bool
Checks if the entity is sprinting.

Returns: true if the entity is sprinting.

script.zs
// LivingEntity.isSprinting() as bool;
myLivingEntity.isSprinting();

Return Type: bool

Getter
Checks if the entity is stepping carefully.
script.zs
// LivingEntity.isSteppingCarefully as bool
myLivingEntity.isSteppingCarefully

Return Type: bool

isSteppingCarefully() as bool
Checks if the entity is stepping carefully.

Returns: true if the entity is stepping carefully.

script.zs
// LivingEntity.isSteppingCarefully() as bool;
myLivingEntity.isSteppingCarefully();

Return Type: bool

Getter
Checks if the entity is suppressing bounce.
script.zs
// LivingEntity.isSuppressingBounce as bool
myLivingEntity.isSuppressingBounce

Return Type: bool

isSuppressingBounce() as bool
Checks if the entity is suppressing bounce.

Returns: true if the entity is suppressing bounce.

script.zs
// LivingEntity.isSuppressingBounce() as bool;
myLivingEntity.isSuppressingBounce();

Return Type: bool

Getter
Checks if the entity is suppressing sliding down a ladder, such as sneaking while on a ladder.
script.zs
// LivingEntity.isSuppressingSlidingDownLadder as bool
myLivingEntity.isSuppressingSlidingDownLadder

Return Type: bool

isSuppressingSlidingDownLadder() as bool
Checks if the entity is suppressing sliding down a ladder, such as sneaking while on a ladder.

Returns: True if the entity is suppressing sliding down a ladder, false otherwise.

script.zs
// LivingEntity.isSuppressingSlidingDownLadder() as bool;
myLivingEntity.isSuppressingSlidingDownLadder();

Return Type: bool

Getter
Checks if the entity is swimming.
script.zs
// LivingEntity.isSwimming as bool
myLivingEntity.isSwimming

Return Type: bool

isSwimming() as bool
Checks if the entity is swimming.

Returns: true if the entity is swimming.

script.zs
// LivingEntity.isSwimming() as bool;
myLivingEntity.isSwimming();

Return Type: bool

Getter
Checks if the entity is underwater.
script.zs
// LivingEntity.isUnderWater as bool
myLivingEntity.isUnderWater

Return Type: bool

isUnderWater() as bool
Checks if the entity is underwater.

Returns: true if the entity is underwater.

script.zs
// LivingEntity.isUnderWater() as bool;
myLivingEntity.isUnderWater();

Return Type: bool

Getter
Checks if this entity is using an item.
script.zs
// LivingEntity.isUsingItem as bool
myLivingEntity.isUsingItem

Return Type: bool

isUsingItem() as bool
Checks if this entity is using an item.

Returns: True if the entity is using an item, false otherwise.

script.zs
// LivingEntity.isUsingItem() as bool;
myLivingEntity.isUsingItem();

Return Type: bool

Getter
Checks if the entity is a vehicle.
script.zs
// LivingEntity.isVehicle as bool
myLivingEntity.isVehicle

Return Type: bool

isVehicle() as bool
Checks if the entity is a vehicle.

Returns: true if the entity is a vehicle.

script.zs
// LivingEntity.isVehicle() as bool;
myLivingEntity.isVehicle();

Return Type: bool

Getter
Checks if the entity is visually crawling.
script.zs
// LivingEntity.isVisuallyCrawling as bool
myLivingEntity.isVisuallyCrawling

Return Type: bool

isVisuallyCrawling() as bool
Checks if the entity is visually crawling.

Returns: true if the entity is visually crawling.

script.zs
// LivingEntity.isVisuallyCrawling() as bool;
myLivingEntity.isVisuallyCrawling();

Return Type: bool

Getter
Checks if the entity is visually swimming.
script.zs
// LivingEntity.isVisuallySwimming as bool
myLivingEntity.isVisuallySwimming

Return Type: bool

isVisuallySwimming() as bool
Checks if the entity is visually swimming.

Returns: True if the entity is visually swimming, false otherwise.

script.zs
// LivingEntity.isVisuallySwimming() as bool;
myLivingEntity.isVisuallySwimming();

Return Type: bool

Getter
Gets the jump boost power for this entity.
script.zs
// LivingEntity.jumpBoostPower as double
myLivingEntity.jumpBoostPower

Return Type: double

jumpBoostPower() as double
Gets the jump boost power for this entity.

Returns: The jump boost power.

script.zs
// LivingEntity.jumpBoostPower() as double;
myLivingEntity.jumpBoostPower();

Return Type: double

kill()
Kills the entity.
script.zs
// LivingEntity.kill();
myLivingEntity.kill();
Getter
Gets the kill credit for this entity. If this entity was last hit by a player, then it will be that player, otherwise it will be the last mob that hit this entity.
script.zs
// LivingEntity.killCredit as LivingEntity
myLivingEntity.killCredit

Return Type: LivingEntity

killCredit() as LivingEntity
Gets the kill credit for this entity. If this entity was last hit by a player, then it will be that player, otherwise it will be the last mob that hit this entity.

Returns: The kill credit.

script.zs
// LivingEntity.killCredit() as LivingEntity;
myLivingEntity.killCredit();

Return Type: LivingEntity

knockback(x as double, y as double, z as double)
Knocks back this entity.
script.zs
// LivingEntity.knockback(x as double, y as double, z as double);
myLivingEntity.knockback(myDouble, myDouble, myDouble);

Parameters:

x Type: double - The x coordinate to knock back to.
y Type: double - The y coordinate to knock back to.
z Type: double - The z coordinate to knock back to.
Getter
Gets the last climbable position for this entity.
script.zs
// LivingEntity.lastClimbablePos as BlockPos
myLivingEntity.lastClimbablePos

Return Type: BlockPos

lastClimbablePos() as BlockPos
Gets the last climbable position for this entity.

Returns: The last climbable position.

script.zs
// LivingEntity.lastClimbablePos() as BlockPos;
myLivingEntity.lastClimbablePos();

Return Type: BlockPos

Getter
Gets the last damage source for this entity.
script.zs
// LivingEntity.lastDamageSource as DamageSource
myLivingEntity.lastDamageSource

Return Type: DamageSource

lastDamageSource() as DamageSource
Gets the last damage source for this entity.

Returns: The last damage source.

script.zs
// LivingEntity.lastDamageSource() as DamageSource;
myLivingEntity.lastDamageSource();

Return Type: DamageSource

Getter
Gets the last entity that hurt this entity.
script.zs
// LivingEntity.lastHurtByMob as LivingEntity
myLivingEntity.lastHurtByMob

Return Type: LivingEntity

lastHurtByMob() as LivingEntity
Gets the last entity that hurt this entity.

Returns: The last entity that hurt this entity.

script.zs
// LivingEntity.lastHurtByMob() as LivingEntity;
myLivingEntity.lastHurtByMob();

Return Type: LivingEntity

Getter
Gets the timestamp when this entity was last hurt by a mob.
script.zs
// LivingEntity.lastHurtByMobTimestamp as int
myLivingEntity.lastHurtByMobTimestamp

Return Type: int

lastHurtByMobTimestamp() as int
Gets the timestamp when this entity was last hurt by a mob.

Returns: The timestamp when this entity was last hurt by a mob.

script.zs
// LivingEntity.lastHurtByMobTimestamp() as int;
myLivingEntity.lastHurtByMobTimestamp();

Return Type: int

Getter
Gets the last entity that this entity hurt.
script.zs
// LivingEntity.lastHurtMob as LivingEntity
myLivingEntity.lastHurtMob

Return Type: LivingEntity

lastHurtMob() as LivingEntity
Gets the last entity that this entity hurt.

Returns: The last entity that this entity hurt.

script.zs
// LivingEntity.lastHurtMob() as LivingEntity;
myLivingEntity.lastHurtMob();

Return Type: LivingEntity

Getter
Gets the timestamp when this entity last hurt a mob.
script.zs
// LivingEntity.lastHurtMobTimestamp as int
myLivingEntity.lastHurtMobTimestamp

Return Type: int

lastHurtMobTimestamp() as int
Gets the timestamp when this entity last hurt a mob.

Returns: The timestamp when this entity last hurt a mob.

script.zs
// LivingEntity.lastHurtMobTimestamp() as int;
myLivingEntity.lastHurtMobTimestamp();

Return Type: int

lavaHurt()
Causes the entity to take damage from lava.
script.zs
// LivingEntity.lavaHurt();
myLivingEntity.lavaHurt();
Getter
Gets the Level of the entity.
script.zs
// LivingEntity.level as Level
myLivingEntity.level

Return Type: Level

Getter
Gets the look angle of the entity.
script.zs
// LivingEntity.lookAngle as Vec3
myLivingEntity.lookAngle

Return Type: Vec3

lookAngle() as Vec3
Gets the look angle of the entity.

Returns: The look angle of the entity.

script.zs
// LivingEntity.lookAngle() as Vec3;
myLivingEntity.lookAngle();

Return Type: Vec3

Getter
Gets the loot table for this entity.
script.zs
// LivingEntity.lootTable as ResourceLocation
myLivingEntity.lootTable

Return Type: ResourceLocation

lootTable() as ResourceLocation
Gets the loot table for this entity.

Returns: The loot table.

script.zs
// LivingEntity.lootTable() as ResourceLocation;
myLivingEntity.lootTable();

Return Type: ResourceLocation

Getter
Gets the seed used when generating loot from this entity.
script.zs
// LivingEntity.lootTableSeed as long
myLivingEntity.lootTableSeed

Return Type: long

Getter
Gets the main arm for this entity.
script.zs
// LivingEntity.mainArm as HumanoidArm
myLivingEntity.mainArm

Return Type: HumanoidArm

mainArm() as HumanoidArm
Gets the main arm for this entity.

Returns: The main arm.

script.zs
// LivingEntity.mainArm() as HumanoidArm;
myLivingEntity.mainArm();

Return Type: HumanoidArm

Getter
Gets the main hand item for this entity.
script.zs
// LivingEntity.mainHandItem as ItemStack
myLivingEntity.mainHandItem

Return Type: ItemStack

mainHandItem() as ItemStack
Gets the main hand item for this entity.

Returns: The main hand item.

script.zs
// LivingEntity.mainHandItem() as ItemStack;
myLivingEntity.mainHandItem();

Return Type: ItemStack

Getter
Gets the maximum air supply of the entity.
script.zs
// LivingEntity.maxAirSupply as int
myLivingEntity.maxAirSupply

Return Type: int

maxAirSupply() as int
Gets the maximum air supply of the entity.

Returns: The maximum air supply of the entity.

script.zs
// LivingEntity.maxAirSupply() as int;
myLivingEntity.maxAirSupply();

Return Type: int

Getter
Gets the maximum fall distance of the entity.
script.zs
// LivingEntity.maxFallDistance as int
myLivingEntity.maxFallDistance

Return Type: int

maxFallDistance() as int
Gets the maximum fall distance of the entity.

Returns: The maximum fall distance of the entity.

script.zs
// LivingEntity.maxFallDistance() as int;
myLivingEntity.maxFallDistance();

Return Type: int

Getter
Gets the maximum health for this entity.
script.zs
// LivingEntity.maxHealth as float
myLivingEntity.maxHealth

Return Type: float

maxHealth() as float
Gets the maximum health for this entity.

Returns: The maximum health.

script.zs
// LivingEntity.maxHealth() as float;
myLivingEntity.maxHealth();

Return Type: float

Getter
Gets the motion direction of the entity.
script.zs
// LivingEntity.motionDirection as Direction
myLivingEntity.motionDirection

Return Type: Direction

motionDirection() as Direction
Gets the motion direction of the entity.

Returns: The motion direction of the entity.

script.zs
// LivingEntity.motionDirection() as Direction;
myLivingEntity.motionDirection();

Return Type: Direction

moveRelative(amount as float, relative as Vec3)
Moves the entity relative to its current position.
script.zs
// LivingEntity.moveRelative(amount as float, relative as Vec3);
myLivingEntity.moveRelative(myFloat, myVec3);

Parameters:

amount Type: float - The amount to move the entity by.
relative Type: Vec3 - The relative position to move the entity by.
moveTo(vec as Vec3)
Moves the entity to the given position.
script.zs
// LivingEntity.moveTo(vec as Vec3);
myLivingEntity.moveTo(myVec3);

Parameters:

vec Type: Vec3 - The position to move the entity to.
moveTo(x as double, y as double, z as double)
Moves the entity to the given position.
script.zs
// LivingEntity.moveTo(x as double, y as double, z as double);
myLivingEntity.moveTo(myDouble, myDouble, myDouble);

Parameters:

x Type: double - The x position to move the entity to.
y Type: double - The y position to move the entity to.
z Type: double - The z position to move the entity to.
moveTo(pos as BlockPos, yaw as float, pitch as float)
Moves the entity to the given position.
script.zs
// LivingEntity.moveTo(pos as BlockPos, yaw as float, pitch as float);
myLivingEntity.moveTo(myBlockPos, myFloat, myFloat);

Parameters:

pos Type: BlockPos - The position to move the entity to.
yaw Type: float - The yaw to move the entity to.
pitch Type: float - The pitch to move the entity to.
moveTo(x as double, y as double, z as double, yaw as float, pitch as float)
Moves the entity to the given position.
script.zs
// LivingEntity.moveTo(x as double, y as double, z as double, yaw as float, pitch as float);
myLivingEntity.moveTo(myDouble, myDouble, myDouble, myFloat, myFloat);

Parameters:

x Type: double - The x position to move the entity to.
y Type: double - The y position to move the entity to.
z Type: double - The z position to move the entity to.
yaw Type: float - The yaw to move the entity to.
pitch Type: float - The pitch to move the entity to.
Getter
Gets the name of the entity.
script.zs
// LivingEntity.name as Component
myLivingEntity.name

Return Type: Component

Getter
script.zs
// LivingEntity.name as Component
myLivingEntity.name

Return Type: Component

name() as Component
Gets the name of the entity.

Returns: The name of the entity.

script.zs
// LivingEntity.name() as Component;
myLivingEntity.name();

Return Type: Component

name() as Component
script.zs
// LivingEntity.name() as Component;
myLivingEntity.name();

Return Type: Component

Getter
Gets the time since this entity last performed an action.
script.zs
// LivingEntity.noActionTime as int
myLivingEntity.noActionTime

Return Type: int

noActionTime() as int
Gets the time since this entity last performed an action.

Returns: The time since this entity last performed an action.

script.zs
// LivingEntity.noActionTime() as int;
myLivingEntity.noActionTime();

Return Type: int

Getter
Gets the offhand item for this entity.
script.zs
// LivingEntity.offHandItem as ItemStack
myLivingEntity.offHandItem

Return Type: ItemStack

offHandItem() as ItemStack
Gets the offhand item for this entity.

Returns: The offhand item.

script.zs
// LivingEntity.offHandItem() as ItemStack;
myLivingEntity.offHandItem();

Return Type: ItemStack

Getter
Checks if the entity is on the ground.
script.zs
// LivingEntity.onGround as bool
myLivingEntity.onGround

Return Type: bool

Getter
Gets the position of the entity on the ground.
script.zs
// LivingEntity.onPos as BlockPos
myLivingEntity.onPos

Return Type: BlockPos

onPos() as BlockPos
Gets the position of the entity on the ground.

Returns: The position of the entity on the ground.

script.zs
// LivingEntity.onPos() as BlockPos;
myLivingEntity.onPos();

Return Type: BlockPos

Getter
Gets the passengers of the entity.
script.zs
// LivingEntity.passengers as List<Entity>
myLivingEntity.passengers

Return Type: List<Entity>

passengers() as List<Entity>
Gets the passengers of the entity.

Returns: The passengers of the entity.

script.zs
// LivingEntity.passengers() as List<Entity>;
myLivingEntity.passengers();

Return Type: List<Entity>

Getter
Gets the percent the entity is frozen.
script.zs
// LivingEntity.percentFrozen as float
myLivingEntity.percentFrozen

Return Type: float

percentFrozen() as float
Gets the percent the entity is frozen.

Returns: The percent the entity is frozen.

script.zs
// LivingEntity.percentFrozen() as float;
myLivingEntity.percentFrozen();

Return Type: float

Getter
Gets the piston push reaction of the entity.
script.zs
// LivingEntity.pistonPushReaction as PushReaction
myLivingEntity.pistonPushReaction

Return Type: PushReaction

pistonPushReaction() as PushReaction
Gets the piston push reaction of the entity.

Returns: The piston push reaction of the entity.

script.zs
// LivingEntity.pistonPushReaction() as PushReaction;
myLivingEntity.pistonPushReaction();

Return Type: PushReaction

playSound(sound as SoundEvent, volume as float, pitch as float)
Plays a sound at the entity's location.
script.zs
// LivingEntity.playSound(sound as SoundEvent, volume as float, pitch as float);
myLivingEntity.playSound(mySoundEvent, myFloat, myFloat);

Parameters:

sound Type: SoundEvent - The sound to play.
volume Type: float - The volume of the sound.
pitch Type: float - The pitch of the sound.
Getter
Gets the position of the entity.
script.zs
// LivingEntity.position as Vec3
myLivingEntity.position

Return Type: Vec3

position() as Vec3
Gets the position of the entity.

Returns: The position of the entity.

script.zs
// LivingEntity.position() as Vec3;
myLivingEntity.position();

Return Type: Vec3

positionRider(entity as Entity)
Positions the rider of the entity.
script.zs
// LivingEntity.positionRider(entity as Entity);
myLivingEntity.positionRider(myEntity);

Parameters:

entity Type: Entity - The entity to position the rider of.
Getter
Gets this entity's random source.
script.zs
// LivingEntity.random as RandomSource
myLivingEntity.random

Return Type: RandomSource

random() as RandomSource
Gets this entity's random source.

Returns: The random source for the entity.

script.zs
// LivingEntity.random() as RandomSource;
myLivingEntity.random();

Return Type: RandomSource

Getter
Gets the registry name of the entity.
script.zs
// LivingEntity.registryName as ResourceLocation
myLivingEntity.registryName

Return Type: ResourceLocation

registryName() as ResourceLocation
Gets the registry name of the entity.

Returns: The registry name of the entity.

script.zs
// LivingEntity.registryName() as ResourceLocation;
myLivingEntity.registryName();

Return Type: ResourceLocation

releaseUsingItem()
Releases the item that the entity is using.
script.zs
// LivingEntity.releaseUsingItem();
myLivingEntity.releaseUsingItem();
removeAllEffects() as bool
Removes all effects from this entity.

Returns: True if all effects were removed, false otherwise.

script.zs
// LivingEntity.removeAllEffects() as bool;
myLivingEntity.removeAllEffects();

Return Type: bool

removeEffect(effect as MobEffect) as bool
Removes an effect from this entity.

Returns: True if the effect was removed, false otherwise.

script.zs
// LivingEntity.removeEffect(effect as MobEffect) as bool;
myLivingEntity.removeEffect(myMobEffect);

Parameters:

effect Type: MobEffect - The effect to remove.

Return Type: bool

removeEffectNoUpdate(effect as MobEffect) as MobEffectInstance
Removes an effect from this entity without causing an update.

Returns: The removed effect.

script.zs
// LivingEntity.removeEffectNoUpdate(effect as MobEffect) as MobEffectInstance;
myLivingEntity.removeEffectNoUpdate(myMobEffect);

Parameters:

effect Type: MobEffect - The effect to remove.

Return Type: MobEffectInstance

removeTag(tagName as string) as bool
Removes a tag from the entity.

Returns: true if the tag was removed.

script.zs
// LivingEntity.removeTag(tagName as string) as bool;
myLivingEntity.removeTag(myString);

Parameters:

tagName Type: string - The name of the tag to remove.

Return Type: bool

removeVehicle()
Removes the vehicle of the entity.
script.zs
// LivingEntity.removeVehicle();
myLivingEntity.removeVehicle();
Getter
Gets the root vehicle of the entity.
script.zs
// LivingEntity.rootVehicle as Entity
myLivingEntity.rootVehicle

Return Type: Entity

rootVehicle() as Entity
Gets the root vehicle of the entity.

Returns: The root vehicle of the entity.

script.zs
// LivingEntity.rootVehicle() as Entity;
myLivingEntity.rootVehicle();

Return Type: Entity

Getter
Gets this entity's scale.
script.zs
// LivingEntity.scale as float
myLivingEntity.scale

Return Type: float

scale() as float
Gets this entity's scale.

Returns: The scale of the entity.

script.zs
// LivingEntity.scale() as float;
myLivingEntity.scale();

Return Type: float

sendMessage(component as Component)
Sends a message to the command source.
script.zs
// LivingEntity.sendMessage(component as Component);
myLivingEntity.sendMessage(myComponent);

Parameters:

component Type: Component - The message to send.
setAbsorptionAmount(absorption as float)
Sets the absorption amount for this entity.
script.zs
// LivingEntity.setAbsorptionAmount(absorption as float);
myLivingEntity.setAbsorptionAmount(myFloat);

Parameters:

absorption Type: float - The absorption amount to set.
setAirSupply(air as int)
Sets the air supply of the entity.
script.zs
// LivingEntity.setAirSupply(air as int);
myLivingEntity.setAirSupply(myInt);

Parameters:

air Type: int - The new air supply of the entity.
setArrowCount(count as int)
Sets how many arrows are currently in this entity.
script.zs
// LivingEntity.setArrowCount(count as int);
myLivingEntity.setArrowCount(myInt);

Parameters:

count Type: int - The number of arrows to set.
setAttachmentData(type as AttachmentType<T>, data as T) as T?
script.zs
// LivingEntity.setAttachmentData<T>(type as AttachmentType<T>, data as T) as T?;
myLivingEntity.setAttachmentData<T>(myAttachmentType, myT);

Parameters:

type Type: AttachmentType<T>
data Type: T

Return Type: T?

setAttachmentData(type as Supplier<AttachmentType<T>>, data as T) as T?
script.zs
// LivingEntity.setAttachmentData<T>(type as Supplier<AttachmentType<T>>, data as T) as T?;
myLivingEntity.setAttachmentData<T>(mySupplier, myT);

Parameters:

type Type: Supplier<AttachmentType<T>>
data Type: T

Return Type: T?

setCustomName(name as Component)
Sets the custom name of the entity.
script.zs
// LivingEntity.setCustomName(name as Component);
myLivingEntity.setCustomName(myComponent);

Parameters:

name Type: Component - The new custom name of the entity.
setCustomNameVisible(visible as bool)
Sets the custom name visible state of the entity.
script.zs
// LivingEntity.setCustomNameVisible(visible as bool);
myLivingEntity.setCustomNameVisible(myBool);

Parameters:

visible Type: bool - true if the custom name should be visible.
setDeltaMovement(xDelta as double, yDelta as double, zDelta as double)
Sets the delta movement of the entity.
script.zs
// LivingEntity.setDeltaMovement(xDelta as double, yDelta as double, zDelta as double);
myLivingEntity.setDeltaMovement(myDouble, myDouble, myDouble);

Parameters:

xDelta Type: double - The x delta movement to set.
yDelta Type: double - The y delta movement to set.
zDelta Type: double - The z delta movement to set.
setDiscardFriction(discardFriction as bool)
Sets if this entity should discard friction.
script.zs
// LivingEntity.setDiscardFriction(discardFriction as bool);
myLivingEntity.setDiscardFriction(myBool);

Parameters:

discardFriction Type: bool - True if this entity should discard friction, false otherwise.
setGlowingTag(glowing as bool)
Makes the entity glow.
script.zs
// LivingEntity.setGlowingTag(glowing as bool);
myLivingEntity.setGlowingTag(myBool);

Parameters:

glowing Type: bool - true if the entity should be glowing.
setHealth(health as float)
Sets the health of this entity.
script.zs
// LivingEntity.setHealth(health as float);
myLivingEntity.setHealth(myFloat);

Parameters:

health Type: float - The health to set.
setInvisible(invisible as bool)
Sets the invisible state of the entity.
script.zs
// LivingEntity.setInvisible(invisible as bool);
myLivingEntity.setInvisible(myBool);

Parameters:

invisible Type: bool - true if the entity should be invisible.
setInvulnerable(invulnerable as bool)
Sets the invulnerable state of the entity.
script.zs
// LivingEntity.setInvulnerable(invulnerable as bool);
myLivingEntity.setInvulnerable(myBool);

Parameters:

invulnerable Type: bool - true if the entity should be invulnerable.
setIsInPowderSnow(inPowderSnow as bool)
Sets whether the entity is in powder snow.
script.zs
// LivingEntity.setIsInPowderSnow(inPowderSnow as bool);
myLivingEntity.setIsInPowderSnow(myBool);

Parameters:

inPowderSnow Type: bool - Whether the entity is in powder snow.
setItemInHand(hand as InteractionHand, stack as ItemStack)
Sets the item in the entity's hand.
script.zs
// LivingEntity.setItemInHand(hand as InteractionHand, stack as ItemStack);
myLivingEntity.setItemInHand(myInteractionHand, myItemStack);

Parameters:

hand Type: InteractionHand - The hand to set the item in.
stack Type: ItemStack - The item to set.
setItemSlot(slot as EquipmentSlot, stack as ItemStack)
Sets the item in a specific equipment slot.
script.zs
// LivingEntity.setItemSlot(slot as EquipmentSlot, stack as ItemStack);
myLivingEntity.setItemSlot(myEquipmentSlot, myItemStack);

Parameters:

slot Type: EquipmentSlot - The equipment slot to set the item in.
stack Type: ItemStack - The item stack to set in the slot.
setJumping(jumping as bool)
Sets whether this entity is jumping.
script.zs
// LivingEntity.setJumping(jumping as bool);
myLivingEntity.setJumping(myBool);

Parameters:

jumping Type: bool - True if the entity should jump, false otherwise.
setLastHurtByMob(entity as LivingEntity)
Sets the last entity that hurt this entity.
script.zs
// LivingEntity.setLastHurtByMob(entity as LivingEntity);
myLivingEntity.setLastHurtByMob(myLivingEntity);

Parameters:

entity Type: LivingEntity - The entity that hurt this entity.
setLastHurtByPlayer(player as Player)
Sets the last entity that hurt this entity.
script.zs
// LivingEntity.setLastHurtByPlayer(player as Player);
myLivingEntity.setLastHurtByPlayer(myPlayer);

Parameters:

player Type: Player - The player that hurt this entity.
setLastHurtMob(entity as Entity)
Sets the last entity that this entity hurt.
script.zs
// LivingEntity.setLastHurtMob(entity as Entity);
myLivingEntity.setLastHurtMob(myEntity);

Parameters:

entity Type: Entity - The entity that this entity hurt.
setNoActionTime(idleTime as int)
Sets the time since this entity last performed an action.
script.zs
// LivingEntity.setNoActionTime(idleTime as int);
myLivingEntity.setNoActionTime(myInt);

Parameters:

idleTime Type: int - The time since this entity last performed an action.
setNoGravity(noGravity as bool)
Sets if the entity has no gravity.
script.zs
// LivingEntity.setNoGravity(noGravity as bool);
myLivingEntity.setNoGravity(myBool);

Parameters:

noGravity Type: bool - The no gravity state to set the entity to.
setOldPosAndRot()
Sets the old position and rotation of the entity.
script.zs
// LivingEntity.setOldPosAndRot();
myLivingEntity.setOldPosAndRot();
setOnGround(onGround as bool)
Sets if the entity is on the ground.
script.zs
// LivingEntity.setOnGround(onGround as bool);
myLivingEntity.setOnGround(myBool);

Parameters:

onGround Type: bool - The on ground state to set the entity to.
setPortalCooldown()
Sets the portal cooldown of the entity.
script.zs
// LivingEntity.setPortalCooldown();
myLivingEntity.setPortalCooldown();
setPos(position as Vec3)
Sets the position of the entity.
script.zs
// LivingEntity.setPos(position as Vec3);
myLivingEntity.setPos(myVec3);

Parameters:

position Type: Vec3 - The position to set the entity to.
setPos(x as double, y as double, z as double)
Sets the position of the entity.
script.zs
// LivingEntity.setPos(x as double, y as double, z as double);
myLivingEntity.setPos(myDouble, myDouble, myDouble);

Parameters:

x Type: double - The x position to set the entity to.
y Type: double - The y position to set the entity to.
z Type: double - The z position to set the entity to.
setPosRaw(x as double, y as double, z as double)
Sets the position of the entity to the given coordinates.
script.zs
// LivingEntity.setPosRaw(x as double, y as double, z as double);
myLivingEntity.setPosRaw(myDouble, myDouble, myDouble);

Parameters:

x Type: double - The x coordinate to set the position to.
y Type: double - The y coordinate to set the position to.
z Type: double - The z coordinate to set the position to.
setRemoved(var1 as RemovalReason)
Removes this entity with the given removal reason.
script.zs
// LivingEntity.setRemoved(var1 as RemovalReason);
myLivingEntity.setRemoved(myRemovalReason);

Parameters:

var1 Type: RemovalReason - The removal reason to set.
setShiftKeyDown(keyDown as bool)
Sets the shift key down state of the entity.
script.zs
// LivingEntity.setShiftKeyDown(keyDown as bool);
myLivingEntity.setShiftKeyDown(myBool);

Parameters:

keyDown Type: bool - true if the shift key is down.
setSilent(silent as bool)
Sets if the entity is silent.
script.zs
// LivingEntity.setSilent(silent as bool);
myLivingEntity.setSilent(myBool);

Parameters:

silent Type: bool - The silent state to set the entity to.
setSleepingPos(pos as BlockPos)
Sets the position that the entity is sleeping at.
script.zs
// LivingEntity.setSleepingPos(pos as BlockPos);
myLivingEntity.setSleepingPos(myBlockPos);

Parameters:

pos Type: BlockPos - The position to set the entity to sleep at.
setSpeed(speed as float)
Sets the movement speed of this entity.
script.zs
// LivingEntity.setSpeed(speed as float);
myLivingEntity.setSpeed(myFloat);

Parameters:

speed Type: float - The movement speed to set.
setSprinting(sprinting as bool)
Sets the sprinting state of the entity.
script.zs
// LivingEntity.setSprinting(sprinting as bool);
myLivingEntity.setSprinting(myBool);

Parameters:

sprinting Type: bool - true if the entity should be sprinting.
setStingerCount(count as int)
Sets how many stingers are currently in this entity.
script.zs
// LivingEntity.setStingerCount(count as int);
myLivingEntity.setStingerCount(myInt);

Parameters:

count Type: int - The number of stingers to set.
setSwimming(swimming as bool)
Sets the swimming state of the entity.
script.zs
// LivingEntity.setSwimming(swimming as bool);
myLivingEntity.setSwimming(myBool);

Parameters:

swimming Type: bool - true if the entity should be swimming.
setTicksFrozen(ticks as int)
Sets the number of ticks the entity has been frozen.
script.zs
// LivingEntity.setTicksFrozen(ticks as int);
myLivingEntity.setTicksFrozen(myInt);

Parameters:

ticks Type: int - The new number of ticks the entity has been frozen.
Getter
Checks if the entity should be saved.
script.zs
// LivingEntity.shouldBeSaved as bool
myLivingEntity.shouldBeSaved

Return Type: bool

shouldBeSaved() as bool
Checks if the entity should be saved.

Returns: true if the entity should be saved.

script.zs
// LivingEntity.shouldBeSaved() as bool;
myLivingEntity.shouldBeSaved();

Return Type: bool

Getter
Checks if this entity should discard friction.
script.zs
// LivingEntity.shouldDiscardFriction as bool
myLivingEntity.shouldDiscardFriction

Return Type: bool

shouldDiscardFriction() as bool
Checks if this entity should discard friction.

Returns: True if this entity should discard friction, false otherwise.

script.zs
// LivingEntity.shouldDiscardFriction() as bool;
myLivingEntity.shouldDiscardFriction();

Return Type: bool

Getter
Checks if the commands from this source should inform admins.
script.zs
// LivingEntity.shouldInformAdmins as bool
myLivingEntity.shouldInformAdmins

Return Type: bool

shouldInformAdmins() as bool
Checks if the commands from this source should inform admins.

Returns: True if the commands from this source should inform admins, false otherwise.

script.zs
// LivingEntity.shouldInformAdmins() as bool;
myLivingEntity.shouldInformAdmins();

Return Type: bool

Getter
Checks if the entity should show its name.
script.zs
// LivingEntity.shouldShowName as bool
myLivingEntity.shouldShowName

Return Type: bool

shouldShowName() as bool
Checks if the entity should show its name.

Returns: true if the entity should show its name.

script.zs
// LivingEntity.shouldShowName() as bool;
myLivingEntity.shouldShowName();

Return Type: bool

Getter
Checks if the entity should show vehicle health.
script.zs
// LivingEntity.showVehicleHealth as bool
myLivingEntity.showVehicleHealth

Return Type: bool

showVehicleHealth() as bool
Checks if the entity should show vehicle health.

Returns: true if the entity should show vehicle health.

script.zs
// LivingEntity.showVehicleHealth() as bool;
myLivingEntity.showVehicleHealth();

Return Type: bool

Getter
Gets the position that the entity is sleeping at.
script.zs
// LivingEntity.sleepingPos as BlockPos
myLivingEntity.sleepingPos

Return Type: BlockPos

sleepingPos() as BlockPos
Gets the position that the entity is sleeping at.

Returns: The position that the entity is sleeping at.

script.zs
// LivingEntity.sleepingPos() as BlockPos;
myLivingEntity.sleepingPos();

Return Type: BlockPos

Getter
Gets the SoundSource of the entity.
script.zs
// LivingEntity.soundSource as SoundSource
myLivingEntity.soundSource

Return Type: SoundSource

soundSource() as SoundSource
Gets the SoundSource of the entity.

Returns: The sound source of the entity.

script.zs
// LivingEntity.soundSource() as SoundSource;
myLivingEntity.soundSource();

Return Type: SoundSource

Getter
Gets the movement speed of this entity.
script.zs
// LivingEntity.speed as float
myLivingEntity.speed

Return Type: float

speed() as float
Gets the movement speed of this entity.

Returns: The movement speed of the entity.

script.zs
// LivingEntity.speed() as float;
myLivingEntity.speed();

Return Type: float

startRiding(entity as Entity) as bool
Starts riding the given entity.

Returns: true if the entity started riding.

script.zs
// LivingEntity.startRiding(entity as Entity) as bool;
myLivingEntity.startRiding(myEntity);

Parameters:

entity Type: Entity - The entity to start riding.

Return Type: bool

startRiding(entity as Entity, force as bool) as bool
Starts riding the given entity.

Returns: true if the entity started riding.

script.zs
// LivingEntity.startRiding(entity as Entity, force as bool) as bool;
myLivingEntity.startRiding(myEntity, myBool);

Parameters:

entity Type: Entity - The entity to start riding.
force Type: bool - true if the entity should be forced to start riding.

Return Type: bool

startSleeping(pos as BlockPos)
Starts the entity to sleep at a specific position.
script.zs
// LivingEntity.startSleeping(pos as BlockPos);
myLivingEntity.startSleeping(myBlockPos);

Parameters:

pos Type: BlockPos - The position to set the entity to sleep at.
startUsingItem(hand as InteractionHand)
Starts using an item.
script.zs
// LivingEntity.startUsingItem(hand as InteractionHand);
myLivingEntity.startUsingItem(myInteractionHand);

Parameters:

hand Type: InteractionHand - The hand to use the item with.
Getter
Gets how many stingers are currently in this entity.
script.zs
// LivingEntity.stingerCount as int
myLivingEntity.stingerCount

Return Type: int

stingerCount() as int
Gets how many stingers are currently in this entity.

Returns: The stinger count.

script.zs
// LivingEntity.stingerCount() as int;
myLivingEntity.stingerCount();

Return Type: int

stopRiding()
Stops riding the entity.
script.zs
// LivingEntity.stopRiding();
myLivingEntity.stopRiding();
stopSleeping()
Stops the entity from sleeping.
script.zs
// LivingEntity.stopSleeping();
myLivingEntity.stopSleeping();
stopUsingItem()
Stops using an item.
script.zs
// LivingEntity.stopUsingItem();
myLivingEntity.stopUsingItem();
Getter
Gets the UUID of the entity as a string.
script.zs
// LivingEntity.stringUUID as string
myLivingEntity.stringUUID

Return Type: string

stringUUID() as string
Gets the UUID of the entity as a string.

Returns: The UUID of the entity as a string.

script.zs
// LivingEntity.stringUUID() as string;
myLivingEntity.stringUUID();

Return Type: string

swing(hand as InteractionHand)
Swings the entity's main hand.
script.zs
// LivingEntity.swing(hand as InteractionHand);
myLivingEntity.swing(myInteractionHand);

Parameters:

hand Type: InteractionHand - The hand to swing.
swing(hand as InteractionHand, updateSelf as bool)
Swings the entity's main hand.
script.zs
// LivingEntity.swing(hand as InteractionHand, updateSelf as bool);
myLivingEntity.swing(myInteractionHand, myBool);

Parameters:

hand Type: InteractionHand - The hand to swing.
updateSelf Type: bool - Whether to update the entity's self.
Getter
Gets the tags of the entity.
These tags are arbitrary strings that can be attached to an entity. A single entity is limited to 1024.
script.zs
// LivingEntity.tags as Set<string>
myLivingEntity.tags

Return Type: Set<string>

tags() as Set<string>
Gets the tags of the entity.
These tags are arbitrary strings that can be attached to an entity. A single entity is limited to 1024.

Returns: The tags of the entity.

script.zs
// LivingEntity.tags() as Set<string>;
myLivingEntity.tags();

Return Type: Set<string>

Getter
Gets the team color of the entity.
script.zs
// LivingEntity.teamColor as int
myLivingEntity.teamColor

Return Type: int

teamColor() as int
Gets the team color of the entity.

Returns: The team color of the entity.

script.zs
// LivingEntity.teamColor() as int;
myLivingEntity.teamColor();

Return Type: int

teleportTo(x as double, y as double, z as double)
Teleports the entity to the given position.
script.zs
// LivingEntity.teleportTo(x as double, y as double, z as double);
myLivingEntity.teleportTo(myDouble, myDouble, myDouble);

Parameters:

x Type: double - The x coordinate to teleport to.
y Type: double - The y coordinate to teleport to.
z Type: double - The z coordinate to teleport to.
Getter
Gets the number of ticks the entity has been frozen.
script.zs
// LivingEntity.ticksFrozen as int
myLivingEntity.ticksFrozen

Return Type: int

ticksFrozen() as int
Gets the number of ticks the entity has been frozen.

Returns: The number of ticks the entity has been frozen.

script.zs
// LivingEntity.ticksFrozen() as int;
myLivingEntity.ticksFrozen();

Return Type: int

Getter
Gets the number of ticks required to freeze the entity.
script.zs
// LivingEntity.ticksRequiredToFreeze as int
myLivingEntity.ticksRequiredToFreeze

Return Type: int

ticksRequiredToFreeze() as int
Gets the number of ticks required to freeze the entity.

Returns: The number of ticks required to freeze the entity.

script.zs
// LivingEntity.ticksRequiredToFreeze() as int;
myLivingEntity.ticksRequiredToFreeze();

Return Type: int

Getter
Gets how long the entity has been using an item.
script.zs
// LivingEntity.ticksUsingItem as int
myLivingEntity.ticksUsingItem

Return Type: int

ticksUsingItem() as int
Gets how long the entity has been using an item.

Returns: The ticks that the entity has been using an item.

script.zs
// LivingEntity.ticksUsingItem() as int;
myLivingEntity.ticksUsingItem();

Return Type: int

travel(vec as Vec3)
Moves this entity towards the given location.
script.zs
// LivingEntity.travel(vec as Vec3);
myLivingEntity.travel(myVec3);

Parameters:

vec Type: Vec3 - The direction to move in.
turn(yaw as double, pitch as double)
Turns the entity.
script.zs
// LivingEntity.turn(yaw as double, pitch as double);
myLivingEntity.turn(myDouble, myDouble);

Parameters:

yaw Type: double - The yaw to turn the entity to.
pitch Type: double - The pitch to turn the entity to.
Getter
Gets the EntityType of the entity.
script.zs
// LivingEntity.type as EntityType<Entity>
myLivingEntity.type

Return Type: EntityType<Entity>

type() as EntityType<Entity>
Gets the EntityType of the entity.

Returns: The EntityType of the entity.

script.zs
// LivingEntity.type() as EntityType<Entity>;
myLivingEntity.type();

Return Type: EntityType<Entity>

unRide()
Removes any passengers and stops riding the current entity.
script.zs
// LivingEntity.unRide();
myLivingEntity.unRide();
updateCustomData(data as MapData)
Updates the custom NBT data for this Entity.
script.zs
// LivingEntity.updateCustomData(data as MapData);
myLivingEntity.updateCustomData({custom: "data"});

Parameters:

data Type: MapData - The custom data to store.
updateCustomEntityTag(level as Level, player as Player, data as MapData)
script.zs
// LivingEntity.updateCustomEntityTag(level as Level, player as Player, data as MapData);
myLivingEntity.updateCustomEntityTag(myLevel, myPlayer, myMapData);

Parameters:

level Type: Level
player Type: Player
data Type: MapData
updateData(data as MapData)
Updates the NBT data of this Entity.
script.zs
// LivingEntity.updateData(data as MapData);
myLivingEntity.updateData({key: "value"});

Parameters:

data Type: MapData - The new Data for this Entity
Getter
Gets the hand that the entity is using an item with.
script.zs
// LivingEntity.usedItemHand as InteractionHand
myLivingEntity.usedItemHand

Return Type: InteractionHand

usedItemHand() as InteractionHand
Gets the hand that the entity is using an item with.

Returns: The hand that the entity is using an item with.

script.zs
// LivingEntity.usedItemHand() as InteractionHand;
myLivingEntity.usedItemHand();

Return Type: InteractionHand

Getter
Gets the item that the entity is using.
script.zs
// LivingEntity.useItem as ItemStack
myLivingEntity.useItem

Return Type: ItemStack

useItem() as ItemStack
Gets the item that the entity is using.

Returns: The item that the entity is using.

script.zs
// LivingEntity.useItem() as ItemStack;
myLivingEntity.useItem();

Return Type: ItemStack

Getter
Gets the remaining ticks left of the use duration of the item that is being used.
script.zs
// LivingEntity.useItemRemainingTicks as int
myLivingEntity.useItemRemainingTicks

Return Type: int

useItemRemainingTicks() as int
Gets the remaining ticks left of the use duration of the item that is being used.

Returns: The remaining ticks for the item that the entity is using.

script.zs
// LivingEntity.useItemRemainingTicks() as int;
myLivingEntity.useItemRemainingTicks();

Return Type: int

Getter
Gets the UUID of the entity.
script.zs
// LivingEntity.uuid as UUID
myLivingEntity.uuid

Return Type: UUID

uuid() as UUID
Gets the UUID of the entity.

Returns: The UUID of the entity.

script.zs
// LivingEntity.uuid() as UUID;
myLivingEntity.uuid();

Return Type: UUID

Getter
Gets the vehicle of the entity.
script.zs
// LivingEntity.vehicle as Entity
myLivingEntity.vehicle

Return Type: Entity

vehicle() as Entity
Gets the vehicle of the entity.

Returns: The vehicle of the entity.

script.zs
// LivingEntity.vehicle() as Entity;
myLivingEntity.vehicle();

Return Type: Entity

Getter
Gets the voice pitch for this entity.
script.zs
// LivingEntity.voicePitch as float
myLivingEntity.voicePitch

Return Type: float

voicePitch() as float
Gets the voice pitch for this entity.

Returns: The voice pitch.

script.zs
// LivingEntity.voicePitch() as float;
myLivingEntity.voicePitch();

Return Type: float

Getter
Gets the x coordinate of the entity.
script.zs
// LivingEntity.x as double
myLivingEntity.x

Return Type: double

x() as double
Gets the x coordinate of the entity.

Returns: The x coordinate of the entity.

script.zs
// LivingEntity.x() as double;
myLivingEntity.x();

Return Type: double

Getter
Gets the y coordinate of the entity.
script.zs
// LivingEntity.y as double
myLivingEntity.y

Return Type: double

y() as double
Gets the y coordinate of the entity.

Returns: The y coordinate of the entity.

script.zs
// LivingEntity.y() as double;
myLivingEntity.y();

Return Type: double

Getter
Gets the z coordinate of the entity.
script.zs
// LivingEntity.z as double
myLivingEntity.z

Return Type: double

z() as double
Gets the z coordinate of the entity.

Returns: The z coordinate of the entity.

script.zs
// LivingEntity.z() as double;
myLivingEntity.z();

Return Type: double