mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-20 19:49:44 +00:00
chicken should look on player correctly now
This commit is contained in:
parent
8c12e0de26
commit
a37ea6af3f
3 changed files with 3 additions and 3 deletions
|
|
@ -45,7 +45,7 @@ class MobController
|
|||
if($pitch){
|
||||
$diff = sqrt($x * $x + $z * $z);
|
||||
$calcPitch = rad2deg(atan($y / $diff));
|
||||
$this->entity->pitch = $calcPitch;
|
||||
$this->entity->pitch = $this->entity->type === MOB_CHICKEN ? -$calcPitch : $calcPitch;
|
||||
}
|
||||
|
||||
$this->entity->server->query("UPDATE entities SET pitch = ".$this->entity->pitch.", yaw = ".$this->entity->yaw." WHERE EID = ".$this->entity->eid.";");
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue