Move responsibility of firing chunk requests from World to NetworkSession

this is, after all, all about sending chunks ...
This commit is contained in:
Dylan K. Taylor 2020-11-08 14:14:43 +00:00
parent 4ae7efbfbc
commit 64afb6f2e2
2 changed files with 5 additions and 5 deletions

View File

@ -956,8 +956,12 @@ class NetworkSession{
return true; //keep ticking until timeout
}
if($this->player !== null){
$this->player->doChunkRequests();
}
$this->flushSendBuffer();
return false;
return true;
}
}

View File

@ -810,10 +810,6 @@ class World implements ChunkManager{
}
foreach($this->players as $p){
$p->doChunkRequests();
}
if($this->sleepTicks > 0 and --$this->sleepTicks <= 0){
$this->checkSleep();
}