Class AvatarEntity
java.lang.Object
org.geysermc.geyser.entity.type.Entity
org.geysermc.geyser.entity.type.LivingEntity
org.geysermc.geyser.entity.type.player.AvatarEntity
- All Implemented Interfaces:
org.geysermc.geyser.api.entity.type.GeyserEntity
- Direct Known Subclasses:
MannequinEntity,PlayerEntity,SkullPlayerEntity
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected static final List<org.cloudburstmc.protocol.bedrock.data.AbilityLayer>static final floatprotected @Nullable StringThe textures property from the GameProfile.protected StringFields inherited from class org.geysermc.geyser.entity.type.LivingEntity
equipment, health, maxHealthFields inherited from class org.geysermc.geyser.entity.type.Entity
definition, dirtyMetadata, displayName, entityId, flags, geyserId, headYaw, motion, nametag, onGround, passengers, pitch, position, propertyManager, session, silent, uuid, valid, vehicle, yaw -
Constructor Summary
ConstructorsConstructorDescriptionAvatarEntity(GeyserSession session, int entityId, long geyserId, UUID uuid, EntityDefinition<?> definition, org.cloudburstmc.math.vector.Vector3f position, org.cloudburstmc.math.vector.Vector3f motion, float yaw, float pitch, float headYaw, String username) -
Method Summary
Modifier and TypeMethodDescription@Nullable org.cloudburstmc.math.vector.Vector3i@Nullable StringThe textures property from the GameProfile.protected voidCalled on entity spawn.voidmoveAbsolute(org.cloudburstmc.math.vector.Vector3f position, float yaw, float pitch, float headYaw, boolean isOnGround, boolean teleported) voidmoveRelative(double relX, double relY, double relZ, float yaw, float pitch, float headYaw, boolean isOnGround) protected voidscoreVisibility(boolean show) @Nullable org.cloudburstmc.math.vector.Vector3isetBedPosition(org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.EntityMetadata<Optional<org.cloudburstmc.math.vector.Vector3i>, ?> entityMetadata) voidsetBelowNameText(String text) voidsetDimensionsFromPose(org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.Pose pose) Set the height and width of the entity's bounding boxvoidsetDisplayName(org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.EntityMetadata<Optional<net.kyori.adventure.text.Component>, ?> entityMetadata) voidsetDisplayNameVisible(org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.type.BooleanEntityMetadata entityMetadata) voidsetPitch(float pitch) voidsetPose(org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.Pose pose) Usually used for bounding box and not animation.voidsetPosition(org.cloudburstmc.math.vector.Vector3f position) voidvoidvoidsetSkin(org.geysermc.mcprotocollib.protocol.data.game.entity.player.ResolvableProfile profile, boolean cape, Runnable after) voidsetSkinVisibility(org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.type.ByteEntityMetadata entityMetadata) voidsetTexturesProperty(@Nullable String texturesProperty) The textures property from the GameProfile.voidMethods inherited from class org.geysermc.geyser.entity.type.LivingEntity
calculateAttribute, canUseSlot, checkInteractWithNameTag, createHealthAttribute, getEquipment, getItemInSlot, getMainHandItem, getOffHandItem, hasBodyArmor, hasShield, interact, isAlive, isHolding, isMaxFrozenState, isShaking, setBody, setBoots, setBoundingBoxHeight, setBoundingBoxWidth, setChestplate, setEquipment, setFreezing, setHand, setHealth, setHelmet, setLeggings, setLivingEntityFlags, setMaxFrozenState, setMaxHealth, setOffhand, setParticles, setSaddle, setScale, setSpinAttack, switchHands, updateArmor, updateAttribute, updateBedrockAttributes, updateMainHand, updateNametag, updateOffHand, updateSaddled, useArmSwingAttackMethods inherited from class org.geysermc.geyser.entity.type.Entity
addAdditionalSpawnData, despawnEntity, getBedrockRotation, getBoundingBoxHeight, getBoundingBoxWidth, getDefinition, getDirtyMetadata, getEntityId, getFlag, getGeyserId, getHeadYaw, getMaxAir, getMotion, getNametag, getPassengers, getPitch, getPosition, getPropertyManager, getSession, getUuid, getVehicle, getYaw, hasLeashesToDrop, interactAt, isOnGround, isSilent, isValid, javaId, moveAbsolute, moveRelative, playEntityEvent, playEntityEvent, setAir, setAirSupply, setClientSideSilent, setDefinition, setEntityId, setFlag, setFlags, setFlagsDirty, setGliding, setGravity, setHeadYaw, setInvisible, setMotion, setNametag, setOnGround, setPassengers, setRiderSeatPosition, setSilent, setSneaking, setSprinting, setUuid, setValid, setVehicle, setYaw, standardDisplayName, teamIdentifier, teleport, testInteraction, updateBedrockEntityProperties, updateBedrockMetadata, updateHeadLookRotation, updateInteractiveTag, updateMountOffset, updateNametag, updatePassengerOffsets, updatePositionAndRotation, updatePropertiesBatched, updateRotationMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.geysermc.geyser.api.entity.type.GeyserEntity
updateProperty
-
Field Details
-
SNEAKING_POSE_HEIGHT
public static final float SNEAKING_POSE_HEIGHT- See Also:
-
BASE_ABILITY_LAYER
-
username
-
texturesProperty
The textures property from the GameProfile.
-
-
Constructor Details
-
AvatarEntity
public AvatarEntity(GeyserSession session, int entityId, long geyserId, UUID uuid, EntityDefinition<?> definition, org.cloudburstmc.math.vector.Vector3f position, org.cloudburstmc.math.vector.Vector3f motion, float yaw, float pitch, float headYaw, String username)
-
-
Method Details
-
initializeMetadata
protected void initializeMetadata()Description copied from class:EntityCalled on entity spawn. Used to populate the entity metadata and flags with default values.- Overrides:
initializeMetadatain classLivingEntity
-
spawnEntity
public void spawnEntity()- Overrides:
spawnEntityin classEntity
-
moveAbsolute
public void moveAbsolute(org.cloudburstmc.math.vector.Vector3f position, float yaw, float pitch, float headYaw, boolean isOnGround, boolean teleported) - Overrides:
moveAbsolutein classEntity
-
moveRelative
public void moveRelative(double relX, double relY, double relZ, float yaw, float pitch, float headYaw, boolean isOnGround) - Overrides:
moveRelativein classLivingEntity
-
setPosition
public void setPosition(org.cloudburstmc.math.vector.Vector3f position) - Overrides:
setPositionin classEntity
-
setBedPosition
public @Nullable org.cloudburstmc.math.vector.Vector3i setBedPosition(org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.EntityMetadata<Optional<org.cloudburstmc.math.vector.Vector3i>, ?> entityMetadata) - Overrides:
setBedPositionin classLivingEntity
-
setSkin
public void setSkin(org.geysermc.mcprotocollib.protocol.data.game.entity.player.ResolvableProfile profile, boolean cape, Runnable after) -
setSkin
public void setSkin(org.geysermc.mcprotocollib.auth.GameProfile profile, boolean cape, Runnable after) -
setSkin
-
setSkinVisibility
public void setSkinVisibility(org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.type.ByteEntityMetadata entityMetadata) -
getDisplayName
- Overrides:
getDisplayNamein classEntity
-
setDisplayName
public void setDisplayName(org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.EntityMetadata<Optional<net.kyori.adventure.text.Component>, ?> entityMetadata) - Overrides:
setDisplayNamein classEntity
-
setDisplayNameVisible
public void setDisplayNameVisible(org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.type.BooleanEntityMetadata entityMetadata) - Overrides:
setDisplayNameVisiblein classEntity
-
setBelowNameText
-
scoreVisibility
protected void scoreVisibility(boolean show) - Overrides:
scoreVisibilityin classEntity
-
setPose
public void setPose(org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.Pose pose) Description copied from class:EntityUsually used for bounding box and not animation. -
setPitch
public void setPitch(float pitch) -
setDimensionsFromPose
public void setDimensionsFromPose(org.geysermc.mcprotocollib.protocol.data.game.entity.metadata.Pose pose) Description copied from class:EntitySet the height and width of the entity's bounding box- Overrides:
setDimensionsFromPosein classLivingEntity
-
getUsername
-
getTexturesProperty
The textures property from the GameProfile. -
setTexturesProperty
The textures property from the GameProfile. -
getBedPosition
public @Nullable org.cloudburstmc.math.vector.Vector3i getBedPosition()
-