mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-20 19:49:44 +00:00
Fixed crash
This commit is contained in:
parent
b5c935559f
commit
5683dca9f6
1 changed files with 2 additions and 2 deletions
|
|
@ -378,7 +378,7 @@ class PlayerAPI{
|
|||
|
||||
public function spawnAllPlayers(Player $player){
|
||||
foreach($this->getAll() as $p){
|
||||
if($p !== $player){
|
||||
if($p !== $player and ($p->entity instanceof Entity)){
|
||||
$p->entity->spawn($player);
|
||||
if($p->level !== $player->level){
|
||||
$player->dataPacket(MC_MOVE_ENTITY_POSROT, array(
|
||||
|
|
@ -396,7 +396,7 @@ class PlayerAPI{
|
|||
|
||||
public function spawnToAllPlayers(Player $player){
|
||||
foreach($this->getAll() as $p){
|
||||
if($p !== $player){
|
||||
if($p !== $player and ($p->entity instanceof Entity)){
|
||||
$player->entity->spawn($p);
|
||||
if($p->level !== $player->level){
|
||||
$p->dataPacket(MC_MOVE_ENTITY_POSROT, array(
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue