fixed tasklookaround

This commit is contained in:
GameHerobrine 2024-01-12 05:54:19 +03:00
parent b7f9d3f1c5
commit 3d1dba6b86
14 changed files with 58 additions and 24 deletions

View file

@ -115,9 +115,14 @@ abstract class Living extends Entity implements Pathfindable{
public function updateEntityMovement(){
if(!$this->dead && Entity::$allowedAI && $this->idleTime <= 0) {
$this->ai->updateTasks();
//$this->ai->updateTasks();
}
//if($this->onGround){
// if(!$this->hasPath() && $this->pathFinder instanceof ITileNavigator){
// $this->path = $this->pathFinder->navigate(new PathTileXYZ($this->x, $this->y, $this->z, $this->level), new PathTileXYZ($this->x + mt_rand(-10, 10), $this->y + mt_rand(-1, 1), $this->z + mt_rand(-10, 10), $this->level), 10);
// }
// $this->pathFollower->followPath();
//}
$this->ai->mobController->movementTick();
$this->ai->mobController->rotateTick();