mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-05-10 15:59:39 +00:00
Entity->entityBaseTick() is now protected
This commit is contained in:
parent
acd0a8f2d4
commit
c872b120d0
@ -885,7 +885,7 @@ abstract class Entity extends Location implements Metadatable, EntityIds{
|
|||||||
return $this->propertyManager;
|
return $this->propertyManager;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function entityBaseTick(int $tickDiff = 1) : bool{
|
protected function entityBaseTick(int $tickDiff = 1) : bool{
|
||||||
//TODO: check vehicles
|
//TODO: check vehicles
|
||||||
|
|
||||||
$this->justCreated = false;
|
$this->justCreated = false;
|
||||||
|
@ -689,7 +689,7 @@ class Human extends Creature implements ProjectileSource, InventoryHolder{
|
|||||||
$this->attributeMap->addAttribute(Attribute::getAttribute(Attribute::EXPERIENCE));
|
$this->attributeMap->addAttribute(Attribute::getAttribute(Attribute::EXPERIENCE));
|
||||||
}
|
}
|
||||||
|
|
||||||
public function entityBaseTick(int $tickDiff = 1) : bool{
|
protected function entityBaseTick(int $tickDiff = 1) : bool{
|
||||||
$hasUpdate = parent::entityBaseTick($tickDiff);
|
$hasUpdate = parent::entityBaseTick($tickDiff);
|
||||||
|
|
||||||
$this->doFoodTick($tickDiff);
|
$this->doFoodTick($tickDiff);
|
||||||
|
@ -676,7 +676,7 @@ abstract class Living extends Entity implements Damageable{
|
|||||||
$this->despawnFromAll();
|
$this->despawnFromAll();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function entityBaseTick(int $tickDiff = 1) : bool{
|
protected function entityBaseTick(int $tickDiff = 1) : bool{
|
||||||
Timings::$timerLivingEntityBaseTick->startTiming();
|
Timings::$timerLivingEntityBaseTick->startTiming();
|
||||||
|
|
||||||
$hasUpdate = parent::entityBaseTick($tickDiff);
|
$hasUpdate = parent::entityBaseTick($tickDiff);
|
||||||
|
@ -78,7 +78,7 @@ class Squid extends WaterAnimal{
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public function entityBaseTick(int $tickDiff = 1) : bool{
|
protected function entityBaseTick(int $tickDiff = 1) : bool{
|
||||||
if($this->closed){
|
if($this->closed){
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -163,7 +163,7 @@ class ExperienceOrb extends Entity{
|
|||||||
$this->targetPlayerRuntimeId = $player !== null ? $player->getId() : null;
|
$this->targetPlayerRuntimeId = $player !== null ? $player->getId() : null;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function entityBaseTick(int $tickDiff = 1) : bool{
|
protected function entityBaseTick(int $tickDiff = 1) : bool{
|
||||||
$hasUpdate = parent::entityBaseTick($tickDiff);
|
$hasUpdate = parent::entityBaseTick($tickDiff);
|
||||||
|
|
||||||
$this->age += $tickDiff;
|
$this->age += $tickDiff;
|
||||||
|
@ -87,7 +87,7 @@ class FallingBlock extends Entity{
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public function entityBaseTick(int $tickDiff = 1) : bool{
|
protected function entityBaseTick(int $tickDiff = 1) : bool{
|
||||||
if($this->closed){
|
if($this->closed){
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -83,7 +83,7 @@ class ItemEntity extends Entity{
|
|||||||
(new ItemSpawnEvent($this))->call();
|
(new ItemSpawnEvent($this))->call();
|
||||||
}
|
}
|
||||||
|
|
||||||
public function entityBaseTick(int $tickDiff = 1) : bool{
|
protected function entityBaseTick(int $tickDiff = 1) : bool{
|
||||||
if($this->closed){
|
if($this->closed){
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -81,7 +81,7 @@ class PrimedTNT extends Entity implements Explosive{
|
|||||||
return $nbt;
|
return $nbt;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function entityBaseTick(int $tickDiff = 1) : bool{
|
protected function entityBaseTick(int $tickDiff = 1) : bool{
|
||||||
if($this->closed){
|
if($this->closed){
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
@ -116,7 +116,7 @@ class Arrow extends Projectile{
|
|||||||
$this->punchKnockback = $punchKnockback;
|
$this->punchKnockback = $punchKnockback;
|
||||||
}
|
}
|
||||||
|
|
||||||
public function entityBaseTick(int $tickDiff = 1) : bool{
|
protected function entityBaseTick(int $tickDiff = 1) : bool{
|
||||||
if($this->closed){
|
if($this->closed){
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user