no more mob pushing as it was causing a lot of memery waste, added 0.9 branch fix

This commit is contained in:
GameHerobrine 2023-03-02 00:16:51 +03:00
parent a3711cfded
commit a3fda45979
4 changed files with 3 additions and 59 deletions

View file

@ -55,7 +55,7 @@ class EntityAI
}
public function updateTasks(){
if(!($this->entity instanceof Entity)) return;
if(!isset($this->entity) || !($this->entity instanceof Entity)) return;
foreach($this->tasks as $t){
if(!$t->isStarted && $t->canBeExecuted($this)){
$t->isStarted = true;