mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-21 03:59:43 +00:00
minecart pushing test
This commit is contained in:
parent
fb13a6123b
commit
39dbd6db34
5 changed files with 110 additions and 22 deletions
|
|
@ -99,7 +99,7 @@ abstract class Living extends Entity implements Pathfindable{
|
|||
foreach($this->level->entityListPositioned[$ind] ?? [] as $entid){
|
||||
if(($this->level->entityList[$entid] ?? null) instanceof Entity){
|
||||
if($this->level->entityList[$entid]->isPushable() && $bb->intersectsWith($this->level->entityList[$entid]->boundingBox)){
|
||||
$this->level->entityList[$entid]->applyCollision($this);
|
||||
$this->level->entityList[$entid]->applyCollision($this, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
@ -188,9 +188,9 @@ abstract class Living extends Entity implements Pathfindable{
|
|||
}
|
||||
|
||||
|
||||
//$this->ai->mobController->movementTick();
|
||||
//$this->ai->mobController->rotateTick();
|
||||
//$this->ai->mobController->jumpTick();
|
||||
$this->ai->mobController->movementTick();
|
||||
$this->ai->mobController->rotateTick();
|
||||
$this->ai->mobController->jumpTick();
|
||||
|
||||
if(abs($this->speedX) < self::MIN_POSSIBLE_SPEED) $this->speedX = 0;
|
||||
if(abs($this->speedZ) < self::MIN_POSSIBLE_SPEED) $this->speedZ = 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue