|
| __construct (Location $location, Vector3 $blockIn, int $facing, PaintingMotive $motive, ?CompoundTag $nbt=null) |
|
| __toString () |
|
| addMotion (float $x, float $y, float $z) |
|
| attack (EntityDamageEvent $source) |
|
| broadcastAnimation (Animation $animation, ?array $targets=null) |
|
| broadcastSound (Sound $sound, ?array $targets=null) |
|
| canBeCollidedWith () |
|
| canBeMovedByCurrents () |
|
| canBeRenamed () |
|
| canClimb () |
|
| canClimbWalls () |
|
| canCollideWith (Entity $entity) |
|
| canSaveWithChunk () |
|
| close () |
|
| despawnFrom (Player $player, bool $send=true) |
|
| despawnFromAll () |
|
| extinguish () |
|
| flagForDespawn () |
|
| getAttributeMap () |
|
| getBoundingBox () |
|
| getDirectionPlane () |
|
| getDirectionVector () |
|
| getEyeHeight () |
|
| getEyePos () |
|
| getFacing () |
|
| getFallDistance () |
|
| getFireTicks () |
|
| getGravity () |
|
| getHealth () |
|
| getHorizontalFacing () |
|
| getId () |
|
| getLastDamageCause () |
|
| getLocation () |
|
| getMaxHealth () |
|
| getMotion () |
|
| getMotive () |
|
| getNameTag () |
|
| getNetworkProperties () |
|
| getNetworkTypeId () |
|
| getOffsetPosition (Vector3 $vector3) |
|
| getOwningEntity () |
|
| getOwningEntityId () |
|
| getPickedItem () |
|
| getPosition () |
|
| getScale () |
|
| getScoreTag () |
|
| getSize () |
|
| getTargetEntity () |
|
| getTargetEntityId () |
|
| getViewers () |
|
| getWorld () |
|
| hasGravity () |
|
| hasMovementUpdate () |
|
| hasNoClientPredictions () |
|
| heal (EntityRegainHealthEvent $source) |
|
| isAlive () |
|
| isClosed () |
|
| isFireProof () |
|
| isFlaggedForDespawn () |
|
| isInsideOfSolid () |
|
| isInvisible () |
|
| isNameTagAlwaysVisible () |
|
| isNameTagVisible () |
|
| isOnFire () |
|
| isOnGround () |
|
| isSilent () |
|
| isUnderwater () |
|
| kill () |
|
| onCollideWithPlayer (Player $player) |
|
| onInteract (Player $player, Vector3 $clickPos) |
|
| onNearbyBlockChange () |
|
| onRandomUpdate () |
|
| onUpdate (int $currentTick) |
|
| resetFallDistance () |
|
| respawnToAll () |
|
| saveNBT () |
|
| scheduleUpdate () |
|
| sendData (?array $targets, ?array $data=null) |
|
| setCanClimb (bool $value=true) |
|
| setCanClimbWalls (bool $value=true) |
|
| setCanSaveWithChunk (bool $value) |
|
| setFallDistance (float $fallDistance) |
|
| setFireTicks (int $fireTicks) |
|
| setForceMovementUpdate (bool $value=true) |
|
| setGravity (float $gravity) |
|
| setHasGravity (bool $v=true) |
|
| setHealth (float $amount) |
|
| setInvisible (bool $value=true) |
|
| setLastDamageCause (EntityDamageEvent $type) |
|
| setMaxHealth (int $amount) |
|
| setMotion (Vector3 $motion) |
|
| setNameTag (string $name) |
|
| setNameTagAlwaysVisible (bool $value=true) |
|
| setNameTagVisible (bool $value=true) |
|
| setNoClientPredictions (bool $value=true) |
|
| setOnFire (int $seconds) |
|
| setOwningEntity (?Entity $owner) |
|
| setRotation (float $yaw, float $pitch) |
|
| setScale (float $value) |
|
| setScoreTag (string $score) |
|
| setSilent (bool $value=true) |
|
| setTargetEntity (?Entity $target) |
|
| spawnTo (Player $player) |
|
| spawnToAll () |
|
| teleport (Vector3 $pos, ?float $yaw=null, ?float $pitch=null) |
|
|
| addAttributes () |
|
| applyDragBeforeGravity () |
|
| broadcastMotion () |
|
| broadcastMovement (bool $teleport=false) |
|
| checkBlockIntersections () |
|
| checkGroundState (float $wantedX, float $wantedY, float $wantedZ, float $dx, float $dy, float $dz) |
|
| checkObstruction (float $x, float $y, float $z) |
|
| dealFireDamage () |
|
| destroyCycles () |
|
| doOnFireTick (int $tickDiff=1) |
|
| entityBaseTick (int $tickDiff=1) |
|
| getAllNetworkData () |
|
| getBlocksAroundWithEntityInsideActions () |
|
| getBlocksIntersected (float $inset) |
|
| getDirtyNetworkData () |
|
| getInitialDragMultiplier () |
|
| getInitialGravity () |
|
| getInitialSizeInfo () |
|
| initEntity (CompoundTag $nbt) |
|
| move (float $dx, float $dy, float $dz) |
|
| onDeath () |
|
| onDeathUpdate (int $tickDiff) |
|
| onDispose () |
|
| onFirstUpdate (int $currentTick) |
|
| onHitGround () |
|
| recalculateBoundingBox () |
|
| resetLastMovements () |
|
| sendSpawnPacket (Player $player) |
|
| setPosition (Vector3 $pos) |
|
| setPositionAndRotation (Vector3 $pos, float $yaw, float $pitch) |
|
| setSize (EntitySizeInfo $size) |
|
| syncNetworkData (EntityMetadataCollection $properties) |
|
| tryChangeMovement () |
|
| updateFallState (float $distanceThisTick, bool $onGround) |
|
| updateMovement (bool $teleport=false) |
|
Definition at line 44 of file Painting.php.
◆ __construct()
◆ __toString()
pocketmine\entity\Entity::__toString |
( |
| ) |
|
|
inherited |
◆ addAttributes()
pocketmine\entity\Entity::addAttributes |
( |
| ) |
|
|
protectedinherited |
◆ addMotion()
pocketmine\entity\Entity::addMotion |
( |
float | $x, |
|
|
float | $y, |
|
|
float | $z ) |
|
inherited |
◆ applyDragBeforeGravity()
pocketmine\entity\Entity::applyDragBeforeGravity |
( |
| ) |
|
|
protectedinherited |
◆ attack()
◆ broadcastAnimation()
pocketmine\entity\Entity::broadcastAnimation |
( |
Animation | $animation, |
|
|
?array | $targets = null ) |
|
inherited |
◆ broadcastMotion()
pocketmine\entity\Entity::broadcastMotion |
( |
| ) |
|
|
protectedinherited |
◆ broadcastMovement()
pocketmine\entity\Entity::broadcastMovement |
( |
bool | $teleport = false | ) |
|
|
protectedinherited |
◆ broadcastSound()
pocketmine\entity\Entity::broadcastSound |
( |
Sound | $sound, |
|
|
?array | $targets = null ) |
|
inherited |
Broadcasts a sound caused by the entity. If the entity is considered "silent", the sound will be dropped.
- Parameters
-
Reimplemented in pocketmine\player\Player.
Definition at line 1703 of file Entity.php.
◆ canBeCollidedWith()
pocketmine\entity\object\Painting::canBeCollidedWith |
( |
| ) |
|
◆ canBeMovedByCurrents()
pocketmine\entity\Entity::canBeMovedByCurrents |
( |
| ) |
|
|
inherited |
◆ canBeRenamed()
pocketmine\entity\Entity::canBeRenamed |
( |
| ) |
|
|
inherited |
◆ canClimb()
pocketmine\entity\Entity::canClimb |
( |
| ) |
|
|
inherited |
Returns whether the entity is able to climb blocks such as ladders or vines.
Definition at line 369 of file Entity.php.
◆ canClimbWalls()
pocketmine\entity\Entity::canClimbWalls |
( |
| ) |
|
|
inherited |
Returns whether this entity is climbing a block. By default this is only true if the entity is climbing a ladder or vine or similar block.
Definition at line 384 of file Entity.php.
◆ canCollideWith()
pocketmine\entity\Entity::canCollideWith |
( |
Entity | $entity | ) |
|
|
inherited |
◆ canFit()
static pocketmine\entity\object\Painting::canFit |
( |
World | $world, |
|
|
Vector3 | $blockIn, |
|
|
int | $facing, |
|
|
bool | $checkOverlap, |
|
|
PaintingMotive | $motive ) |
|
static |
Returns whether a painting with the specified motive can be placed at the given position.
Definition at line 205 of file Painting.php.
◆ canSaveWithChunk()
pocketmine\entity\Entity::canSaveWithChunk |
( |
| ) |
|
|
inherited |
◆ checkBlockIntersections()
pocketmine\entity\Entity::checkBlockIntersections |
( |
| ) |
|
|
protectedinherited |
◆ checkGroundState()
pocketmine\entity\Entity::checkGroundState |
( |
float | $wantedX, |
|
|
float | $wantedY, |
|
|
float | $wantedZ, |
|
|
float | $dx, |
|
|
float | $dy, |
|
|
float | $dz ) |
|
protectedinherited |
◆ checkObstruction()
pocketmine\entity\Entity::checkObstruction |
( |
float | $x, |
|
|
float | $y, |
|
|
float | $z ) |
|
protectedinherited |
◆ close()
pocketmine\entity\Entity::close |
( |
| ) |
|
|
finalinherited |
Closes the entity and frees attached references.
WARNING: Entities are unusable after this has been executed!
Definition at line 1595 of file Entity.php.
◆ dealFireDamage()
pocketmine\entity\Entity::dealFireDamage |
( |
| ) |
|
|
protectedinherited |
Called to deal damage to entities when they are on fire.
Definition at line 742 of file Entity.php.
◆ despawnFrom()
pocketmine\entity\Entity::despawnFrom |
( |
Player | $player, |
|
|
bool | $send = true ) |
|
inherited |
- Deprecated
- WARNING: This function DOES NOT permanently hide the entity from the player. As soon as the entity or player moves, the player will once again be able to see the entity.
Definition at line 1542 of file Entity.php.
◆ despawnFromAll()
pocketmine\entity\Entity::despawnFromAll |
( |
| ) |
|
|
inherited |
- Deprecated
- WARNING: This function DOES NOT permanently hide the entity from viewers. As soon as the entity or player moves, viewers will once again be able to see the entity.
Definition at line 1556 of file Entity.php.
◆ destroyCycles()
pocketmine\entity\Entity::destroyCycles |
( |
| ) |
|
|
protectedinherited |
◆ doOnFireTick()
pocketmine\entity\Entity::doOnFireTick |
( |
int | $tickDiff = 1 | ) |
|
|
protectedinherited |
◆ entityBaseTick()
pocketmine\entity\Entity::entityBaseTick |
( |
int | $tickDiff = 1 | ) |
|
|
protectedinherited |
◆ extinguish()
pocketmine\entity\Entity::extinguish |
( |
| ) |
|
|
inherited |
◆ flagForDespawn()
pocketmine\entity\Entity::flagForDespawn |
( |
| ) |
|
|
inherited |
Flags the entity to be removed from the world on the next tick.
Definition at line 1574 of file Entity.php.
◆ getAllNetworkData()
pocketmine\entity\Entity::getAllNetworkData |
( |
| ) |
|
|
finalprotectedinherited |
- Returns
- MetadataProperty[] @phpstan-return array<int, MetadataProperty>
Definition at line 1661 of file Entity.php.
◆ getAttributeMap()
pocketmine\entity\Entity::getAttributeMap |
( |
| ) |
|
|
inherited |
◆ getBlocksAroundWithEntityInsideActions()
pocketmine\entity\Entity::getBlocksAroundWithEntityInsideActions |
( |
| ) |
|
|
protectedinherited |
◆ getBlocksIntersected()
pocketmine\entity\Entity::getBlocksIntersected |
( |
float | $inset | ) |
|
|
protectedinherited |
Yields all the blocks whose full-cube areas are intersected by the entity's AABB.
@phpstan-return \Generator<int, Block, void, void>
Definition at line 1265 of file Entity.php.
◆ getBoundingBox()
pocketmine\entity\Entity::getBoundingBox |
( |
| ) |
|
|
inherited |
◆ getDirectionPlane()
pocketmine\entity\Entity::getDirectionPlane |
( |
| ) |
|
|
inherited |
◆ getDirectionVector()
pocketmine\entity\Entity::getDirectionVector |
( |
| ) |
|
|
inherited |
◆ getDirtyNetworkData()
pocketmine\entity\Entity::getDirtyNetworkData |
( |
| ) |
|
|
finalprotectedinherited |
- Returns
- MetadataProperty[] @phpstan-return array<int, MetadataProperty>
Definition at line 1649 of file Entity.php.
◆ getEyeHeight()
pocketmine\entity\Entity::getEyeHeight |
( |
| ) |
|
|
inherited |
◆ getEyePos()
pocketmine\entity\Entity::getEyePos |
( |
| ) |
|
|
inherited |
◆ getFacing()
pocketmine\entity\object\Painting::getFacing |
( |
| ) |
|
◆ getFallDistance()
pocketmine\entity\Entity::getFallDistance |
( |
| ) |
|
|
inherited |
◆ getFireTicks()
pocketmine\entity\Entity::getFireTicks |
( |
| ) |
|
|
inherited |
◆ getGravity()
pocketmine\entity\Entity::getGravity |
( |
| ) |
|
|
inherited |
◆ getHealth()
pocketmine\entity\Entity::getHealth |
( |
| ) |
|
|
inherited |
◆ getHorizontalFacing()
pocketmine\entity\Entity::getHorizontalFacing |
( |
| ) |
|
|
inherited |
◆ getId()
pocketmine\entity\Entity::getId |
( |
| ) |
|
|
inherited |
◆ getInitialDragMultiplier()
pocketmine\entity\object\Painting::getInitialDragMultiplier |
( |
| ) |
|
|
protected |
Returns the percentage by which the entity's velocity is reduced per tick when moving through air. The entity's velocity is multiplied by 1 minus this value.
- Returns
- float 0-1
Reimplemented from pocketmine\entity\Entity.
Definition at line 83 of file Painting.php.
◆ getInitialGravity()
pocketmine\entity\object\Painting::getInitialGravity |
( |
| ) |
|
|
protected |
Returns the downwards acceleration of the entity when falling, in blocks/tick².
- Returns
- float minimum 0
Reimplemented from pocketmine\entity\Entity.
Definition at line 85 of file Painting.php.
◆ getInitialSizeInfo()
pocketmine\entity\object\Painting::getInitialSizeInfo |
( |
| ) |
|
|
protected |
◆ getLastDamageCause()
pocketmine\entity\Entity::getLastDamageCause |
( |
| ) |
|
|
inherited |
◆ getLocation()
pocketmine\entity\Entity::getLocation |
( |
| ) |
|
|
inherited |
◆ getMaxHealth()
pocketmine\entity\Entity::getMaxHealth |
( |
| ) |
|
|
inherited |
◆ getMotion()
pocketmine\entity\Entity::getMotion |
( |
| ) |
|
|
inherited |
◆ getMotive()
pocketmine\entity\object\Painting::getMotive |
( |
| ) |
|
Returns the painting motive (which image is displayed on the painting)
Definition at line 176 of file Painting.php.
◆ getNameTag()
pocketmine\entity\Entity::getNameTag |
( |
| ) |
|
|
inherited |
◆ getNetworkProperties()
pocketmine\entity\Entity::getNetworkProperties |
( |
| ) |
|
|
inherited |
◆ getNetworkTypeId()
pocketmine\entity\object\Painting::getNetworkTypeId |
( |
| ) |
|
◆ getOffsetPosition()
pocketmine\entity\Entity::getOffsetPosition |
( |
Vector3 | $vector3 | ) |
|
|
inherited |
◆ getOwningEntity()
pocketmine\entity\Entity::getOwningEntity |
( |
| ) |
|
|
inherited |
◆ getOwningEntityId()
pocketmine\entity\Entity::getOwningEntityId |
( |
| ) |
|
|
inherited |
Returns the entity ID of the owning entity, or null if the entity doesn't have an owner.
Definition at line 399 of file Entity.php.
◆ getPickedItem()
pocketmine\entity\object\Painting::getPickedItem |
( |
| ) |
|
◆ getPosition()
pocketmine\entity\Entity::getPosition |
( |
| ) |
|
|
inherited |
◆ getScale()
pocketmine\entity\Entity::getScale |
( |
| ) |
|
|
inherited |
◆ getScoreTag()
pocketmine\entity\Entity::getScoreTag |
( |
| ) |
|
|
inherited |
◆ getSize()
pocketmine\entity\Entity::getSize |
( |
| ) |
|
|
inherited |
◆ getTargetEntity()
pocketmine\entity\Entity::getTargetEntity |
( |
| ) |
|
|
inherited |
Returns the entity's target entity, or null if not found. This is used for things like hostile mobs attacking entities, and for fishing rods reeling hit entities in.
Definition at line 437 of file Entity.php.
References pocketmine\server().
◆ getTargetEntityId()
pocketmine\entity\Entity::getTargetEntityId |
( |
| ) |
|
|
inherited |
Returns the entity ID of the entity's target, or null if it doesn't have a target.
Definition at line 429 of file Entity.php.
◆ getViewers()
pocketmine\entity\Entity::getViewers |
( |
| ) |
|
|
inherited |
◆ getWorld()
pocketmine\entity\Entity::getWorld |
( |
| ) |
|
|
inherited |
◆ hasGravity()
pocketmine\entity\Entity::hasGravity |
( |
| ) |
|
|
inherited |
◆ hasMovementUpdate()
pocketmine\entity\object\Painting::hasMovementUpdate |
( |
| ) |
|
◆ hasNoClientPredictions()
pocketmine\entity\Entity::hasNoClientPredictions |
( |
| ) |
|
|
inherited |
Returns whether clients may predict this entity's behaviour and movement. Used for things like water movement, burning, and movement smoothing (interpolation).
Definition at line 331 of file Entity.php.
◆ heal()
◆ initEntity()
pocketmine\entity\object\Painting::initEntity |
( |
CompoundTag | $nbt | ) |
|
|
protected |
◆ isAlive()
pocketmine\entity\Entity::isAlive |
( |
| ) |
|
|
inherited |
◆ isClosed()
pocketmine\entity\Entity::isClosed |
( |
| ) |
|
|
inherited |
Returns whether the entity has been "closed".
Definition at line 1586 of file Entity.php.
◆ isFireProof()
pocketmine\entity\Entity::isFireProof |
( |
| ) |
|
|
inherited |
◆ isFlaggedForDespawn()
pocketmine\entity\Entity::isFlaggedForDespawn |
( |
| ) |
|
|
inherited |
◆ isInsideOfSolid()
pocketmine\entity\Entity::isInsideOfSolid |
( |
| ) |
|
|
inherited |
◆ isInvisible()
pocketmine\entity\Entity::isInvisible |
( |
| ) |
|
|
inherited |
◆ isNameTagAlwaysVisible()
pocketmine\entity\Entity::isNameTagAlwaysVisible |
( |
| ) |
|
|
inherited |
◆ isNameTagVisible()
pocketmine\entity\Entity::isNameTagVisible |
( |
| ) |
|
|
inherited |
◆ isOnFire()
pocketmine\entity\Entity::isOnFire |
( |
| ) |
|
|
inherited |
◆ isOnGround()
pocketmine\entity\Entity::isOnGround |
( |
| ) |
|
|
inherited |
◆ isSilent()
pocketmine\entity\Entity::isSilent |
( |
| ) |
|
|
inherited |
◆ isUnderwater()
pocketmine\entity\Entity::isUnderwater |
( |
| ) |
|
|
inherited |
◆ kill()
pocketmine\entity\Entity::kill |
( |
| ) |
|
|
inherited |
◆ move()
pocketmine\entity\Entity::move |
( |
float | $dx, |
|
|
float | $dy, |
|
|
float | $dz ) |
|
protectedinherited |
◆ nextRuntimeId()
static pocketmine\entity\Entity::nextRuntimeId |
( |
| ) |
|
|
staticinherited |
Returns a new runtime entity ID for a new entity.
Definition at line 102 of file Entity.php.
◆ onCollideWithPlayer()
pocketmine\entity\Entity::onCollideWithPlayer |
( |
Player | $player | ) |
|
|
inherited |
◆ onDeath()
pocketmine\entity\object\Painting::onDeath |
( |
| ) |
|
|
protected |
◆ onDeathUpdate()
pocketmine\entity\Entity::onDeathUpdate |
( |
int | $tickDiff | ) |
|
|
protectedinherited |
◆ onDispose()
pocketmine\entity\Entity::onDispose |
( |
| ) |
|
|
protectedinherited |
◆ onFirstUpdate()
pocketmine\entity\Entity::onFirstUpdate |
( |
int | $currentTick | ) |
|
|
protectedinherited |
Called from onUpdate() on the first tick of a new entity. This is called before any movement processing or main ticking logic. Use this to fire any events related to spawning the entity.
Reimplemented in pocketmine\entity\object\ItemEntity.
Definition at line 962 of file Entity.php.
◆ onHitGround()
pocketmine\entity\Entity::onHitGround |
( |
| ) |
|
|
protectedinherited |
◆ onInteract()
pocketmine\entity\Entity::onInteract |
( |
Player | $player, |
|
|
Vector3 | $clickPos ) |
|
inherited |
Called when interacted or tapped by a Player. Returns whether something happened as a result of the interaction.
Definition at line 1116 of file Entity.php.
◆ onNearbyBlockChange()
pocketmine\entity\object\Painting::onNearbyBlockChange |
( |
| ) |
|
◆ onRandomUpdate()
pocketmine\entity\object\Painting::onRandomUpdate |
( |
| ) |
|
Called when a random update is performed on the chunk the entity is in. This happens when the chunk is within the ticking chunk range of a player (or chunk loader).
Reimplemented from pocketmine\entity\Entity.
Definition at line 139 of file Painting.php.
◆ onUpdate()
pocketmine\entity\Entity::onUpdate |
( |
int | $currentTick | ) |
|
|
inherited |
◆ recalculateBoundingBox()
pocketmine\entity\object\Painting::recalculateBoundingBox |
( |
| ) |
|
|
protected |
◆ resetFallDistance()
pocketmine\entity\Entity::resetFallDistance |
( |
| ) |
|
|
inherited |
◆ resetLastMovements()
pocketmine\entity\Entity::resetLastMovements |
( |
| ) |
|
|
protectedinherited |
◆ respawnToAll()
pocketmine\entity\Entity::respawnToAll |
( |
| ) |
|
|
inherited |
◆ saveNBT()
pocketmine\entity\object\Painting::saveNBT |
( |
| ) |
|
◆ scheduleUpdate()
pocketmine\entity\Entity::scheduleUpdate |
( |
| ) |
|
|
finalinherited |
◆ sendData()
pocketmine\entity\Entity::sendData |
( |
?array | $targets, |
|
|
?array | $data = null ) |
|
inherited |
- Parameters
-
Player[] | null | $targets | |
MetadataProperty[] | $data | Properly formatted entity data, defaults to everything |
@phpstan-param array<int, MetadataProperty> $data
Reimplemented in pocketmine\player\Player.
Definition at line 1638 of file Entity.php.
◆ sendSpawnPacket()
pocketmine\entity\object\Painting::sendSpawnPacket |
( |
Player | $player | ) |
|
|
protected |
◆ setCanClimb()
pocketmine\entity\Entity::setCanClimb |
( |
bool | $value = true | ) |
|
|
inherited |
Sets whether the entity is able to climb climbable blocks.
Definition at line 376 of file Entity.php.
◆ setCanClimbWalls()
pocketmine\entity\Entity::setCanClimbWalls |
( |
bool | $value = true | ) |
|
|
inherited |
Sets whether the entity is climbing a block. If true, the entity can climb anything.
Definition at line 391 of file Entity.php.
◆ setCanSaveWithChunk()
pocketmine\entity\Entity::setCanSaveWithChunk |
( |
bool | $value | ) |
|
|
inherited |
Sets whether this entity will be saved when its chunk is unloaded. This can be used to prevent the entity being saved to disk.
Reimplemented in pocketmine\player\Player.
Definition at line 468 of file Entity.php.
◆ setFallDistance()
pocketmine\entity\Entity::setFallDistance |
( |
float | $fallDistance | ) |
|
|
inherited |
◆ setFireTicks()
pocketmine\entity\Entity::setFireTicks |
( |
int | $fireTicks | ) |
|
|
inherited |
- Exceptions
-
InvalidArgumentException
Definition at line 699 of file Entity.php.
◆ setForceMovementUpdate()
pocketmine\entity\Entity::setForceMovementUpdate |
( |
bool | $value = true | ) |
|
|
finalinherited |
Flags the entity as needing a movement update on the next tick. Setting this forces a movement update even if the entity's motion is zero. Used to trigger movement updates when blocks change near entities.
Definition at line 1047 of file Entity.php.
◆ setGravity()
pocketmine\entity\Entity::setGravity |
( |
float | $gravity | ) |
|
|
inherited |
◆ setHasGravity()
pocketmine\entity\Entity::setHasGravity |
( |
bool | $v = true | ) |
|
|
inherited |
◆ setHealth()
pocketmine\entity\Entity::setHealth |
( |
float | $amount | ) |
|
|
inherited |
◆ setInvisible()
pocketmine\entity\Entity::setInvisible |
( |
bool | $value = true | ) |
|
|
inherited |
◆ setLastDamageCause()
◆ setMaxHealth()
pocketmine\entity\Entity::setMaxHealth |
( |
int | $amount | ) |
|
|
inherited |
◆ setMotion()
pocketmine\entity\Entity::setMotion |
( |
Vector3 | $motion | ) |
|
|
inherited |
◆ setNameTag()
pocketmine\entity\Entity::setNameTag |
( |
string | $name | ) |
|
|
inherited |
◆ setNameTagAlwaysVisible()
pocketmine\entity\Entity::setNameTagAlwaysVisible |
( |
bool | $value = true | ) |
|
|
inherited |
◆ setNameTagVisible()
pocketmine\entity\Entity::setNameTagVisible |
( |
bool | $value = true | ) |
|
|
inherited |
◆ setNoClientPredictions()
pocketmine\entity\Entity::setNoClientPredictions |
( |
bool | $value = true | ) |
|
|
inherited |
Things such as movement in water, burning, etc. may be predicted by the client. This is sometimes not desirable, since server-side logic may differ from client-side prediction. However, things like movement smoothing (interpolation) are also controlled by this, so it should be used with care.
Setting this flag will also disable player movement inputs, but this should not be relied on, as cheat clients will be able to bypass it.
Definition at line 343 of file Entity.php.
◆ setOnFire()
pocketmine\entity\Entity::setOnFire |
( |
int | $seconds | ) |
|
|
inherited |
◆ setOwningEntity()
pocketmine\entity\Entity::setOwningEntity |
( |
?Entity | $owner | ) |
|
|
inherited |
Sets the owner of the entity. Passing null will remove the current owner.
- Exceptions
-
InvalidArgumentException if the supplied entity is not valid
Definition at line 415 of file Entity.php.
◆ setPosition()
pocketmine\entity\Entity::setPosition |
( |
Vector3 | $pos | ) |
|
|
protectedinherited |
◆ setPositionAndRotation()
pocketmine\entity\Entity::setPositionAndRotation |
( |
Vector3 | $pos, |
|
|
float | $yaw, |
|
|
float | $pitch ) |
|
protectedinherited |
◆ setRotation()
pocketmine\entity\Entity::setRotation |
( |
float | $yaw, |
|
|
float | $pitch ) |
|
inherited |
◆ setScale()
pocketmine\entity\Entity::setScale |
( |
float | $value | ) |
|
|
inherited |
◆ setScoreTag()
pocketmine\entity\Entity::setScoreTag |
( |
string | $score | ) |
|
|
inherited |
◆ setSilent()
pocketmine\entity\Entity::setSilent |
( |
bool | $value = true | ) |
|
|
inherited |
◆ setSize()
◆ setTargetEntity()
pocketmine\entity\Entity::setTargetEntity |
( |
?Entity | $target | ) |
|
|
inherited |
Sets the entity's target entity. Passing null will remove the current target.
- Exceptions
-
InvalidArgumentException if the target entity is not valid
Definition at line 446 of file Entity.php.
◆ spawnTo()
pocketmine\entity\Entity::spawnTo |
( |
Player | $player | ) |
|
|
inherited |
◆ spawnToAll()
pocketmine\entity\Entity::spawnToAll |
( |
| ) |
|
|
inherited |
◆ syncNetworkData()
◆ teleport()
pocketmine\entity\Entity::teleport |
( |
Vector3 | $pos, |
|
|
?float | $yaw = null, |
|
|
?float | $pitch = null ) |
|
inherited |
◆ tryChangeMovement()
pocketmine\entity\Entity::tryChangeMovement |
( |
| ) |
|
|
protectedinherited |
◆ updateFallState()
pocketmine\entity\Entity::updateFallState |
( |
float | $distanceThisTick, |
|
|
bool | $onGround ) |
|
protectedinherited |
◆ updateMovement()
pocketmine\entity\object\Painting::updateMovement |
( |
bool | $teleport = false | ) |
|
|
protected |
◆ $alwaysShowNameTag
bool pocketmine\entity\Entity::$alwaysShowNameTag = false |
|
protectedinherited |
◆ $attributeMap
◆ $blockIn
Vector3 pocketmine\entity\object\Painting::$blockIn |
|
protected |
◆ $blocksAround
array pocketmine\entity\Entity::$blocksAround = null |
|
protectedinherited |
◆ $boundingBox
◆ $canClimb
bool pocketmine\entity\Entity::$canClimb = false |
|
protectedinherited |
◆ $canClimbWalls
bool pocketmine\entity\Entity::$canClimbWalls = false |
|
protectedinherited |
◆ $closed
bool pocketmine\entity\Entity::$closed = false |
|
protectedinherited |
◆ $drag
float pocketmine\entity\Entity::$drag |
|
protectedinherited |
◆ $facing
int pocketmine\entity\object\Painting::$facing |
|
protected |
◆ $fallDistance
float pocketmine\entity\Entity::$fallDistance = 0.0 |
|
inherited |
◆ $fireTicks
int pocketmine\entity\Entity::$fireTicks = 0 |
|
protectedinherited |
◆ $forceMovementUpdate
bool pocketmine\entity\Entity::$forceMovementUpdate = false |
|
protectedinherited |
◆ $gravity
float pocketmine\entity\Entity::$gravity |
|
protectedinherited |
◆ $gravityEnabled
bool pocketmine\entity\Entity::$gravityEnabled = true |
|
protectedinherited |
◆ $hasSpawned
array pocketmine\entity\Entity::$hasSpawned = [] |
|
protectedinherited |
◆ $id
int pocketmine\entity\Entity::$id |
|
protectedinherited |
◆ $invisible
bool pocketmine\entity\Entity::$invisible = false |
|
protectedinherited |
◆ $isCollided
bool pocketmine\entity\Entity::$isCollided = false |
|
inherited |
◆ $isCollidedHorizontally
bool pocketmine\entity\Entity::$isCollidedHorizontally = false |
|
inherited |
◆ $isCollidedVertically
bool pocketmine\entity\Entity::$isCollidedVertically = false |
|
inherited |
◆ $justCreated
bool pocketmine\entity\Entity::$justCreated = true |
|
protectedinherited |
◆ $keepMovement
bool pocketmine\entity\Entity::$keepMovement = false |
|
inherited |
◆ $lastDamageCause
◆ $lastLocation
Location pocketmine\entity\Entity::$lastLocation |
|
protectedinherited |
◆ $lastMotion
Vector3 pocketmine\entity\Entity::$lastMotion |
|
protectedinherited |
◆ $lastUpdate
int pocketmine\entity\Entity::$lastUpdate |
|
inherited |
◆ $location
Location pocketmine\entity\Entity::$location |
|
protectedinherited |
◆ $motion
Vector3 pocketmine\entity\Entity::$motion |
|
protectedinherited |
◆ $motive
◆ $nameTag
string pocketmine\entity\Entity::$nameTag = "" |
|
protectedinherited |
◆ $nameTagVisible
bool pocketmine\entity\Entity::$nameTagVisible = true |
|
protectedinherited |
◆ $networkPropertiesDirty
bool pocketmine\entity\Entity::$networkPropertiesDirty = false |
|
protectedinherited |
◆ $noClientPredictions
bool pocketmine\entity\Entity::$noClientPredictions = false |
|
protectedinherited |
◆ $noDamageTicks
int pocketmine\entity\Entity::$noDamageTicks = 0 |
|
inherited |
◆ $onGround
bool pocketmine\entity\Entity::$onGround = false |
|
inherited |
◆ $ownerId
int pocketmine\entity\Entity::$ownerId = null |
|
protectedinherited |
◆ $scale
float pocketmine\entity\Entity::$scale = 1.0 |
|
protectedinherited |
◆ $scoreTag
string pocketmine\entity\Entity::$scoreTag = "" |
|
protectedinherited |
◆ $server
Server pocketmine\entity\Entity::$server |
|
protectedinherited |
◆ $silent
bool pocketmine\entity\Entity::$silent = false |
|
protectedinherited |
◆ $size
◆ $stepHeight
float pocketmine\entity\Entity::$stepHeight = 0.0 |
|
protectedinherited |
◆ $targetId
int pocketmine\entity\Entity::$targetId = null |
|
protectedinherited |
◆ $ticksLived
int pocketmine\entity\Entity::$ticksLived = 0 |
|
inherited |
◆ $timings
◆ $ySize
float pocketmine\entity\Entity::$ySize = 0.0 |
|
protectedinherited |
◆ DATA_TO_FACING
const pocketmine\entity\object\Painting::DATA_TO_FACING |
Initial value:= [
0 => Facing::SOUTH,
1 => Facing::WEST,
2 => Facing::NORTH,
3 => Facing::EAST
]
Definition at line 54 of file Painting.php.
◆ MOTION_THRESHOLD
const pocketmine\entity\Entity::MOTION_THRESHOLD = 0.00001 |
|
inherited |
◆ STEP_CLIP_MULTIPLIER
const pocketmine\entity\Entity::STEP_CLIP_MULTIPLIER = 0.4 |
|
protectedinherited |
◆ TAG_DIRECTION_BE
const pocketmine\entity\object\Painting::TAG_DIRECTION_BE = "Direction" |
◆ TAG_FACING_JE
const pocketmine\entity\object\Painting::TAG_FACING_JE = "Facing" |
◆ TAG_MOTION
const pocketmine\entity\Entity::TAG_MOTION = "Motion" |
|
inherited |
◆ TAG_MOTIVE
const pocketmine\entity\object\Painting::TAG_MOTIVE = "Motive" |
◆ TAG_POS
const pocketmine\entity\Entity::TAG_POS = "Pos" |
|
inherited |
◆ TAG_ROTATION
const pocketmine\entity\Entity::TAG_ROTATION = "Rotation" |
|
inherited |
◆ TAG_TILE_X
const pocketmine\entity\object\Painting::TAG_TILE_X = "TileX" |
◆ TAG_TILE_Y
const pocketmine\entity\object\Painting::TAG_TILE_Y = "TileY" |
◆ TAG_TILE_Z
const pocketmine\entity\object\Painting::TAG_TILE_Z = "TileZ" |
The documentation for this class was generated from the following file: