mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-20 19:49:44 +00:00
added ack packet limit
This commit is contained in:
parent
5023bb2286
commit
7166d58916
4 changed files with 59 additions and 6 deletions
|
|
@ -223,7 +223,7 @@ class Player{
|
|||
$this->chatMessagesQueue->data = [];
|
||||
|
||||
//$this->server->schedule(20 * 60, [$this, "clearQueue"], [], true);
|
||||
|
||||
$this->server->interface->maxACKsAllowed["{$this->ip}:{$this->port}"] = 0;
|
||||
$this->evid[] = $this->server->event("server.close", [$this, "close"]);
|
||||
console("[DEBUG] New Session started with $ip:$port. MTU {$this->MTU}, Client ID {$this->clientID}", true, true, 2);
|
||||
}
|
||||
|
|
@ -2021,6 +2021,10 @@ class Player{
|
|||
//$this->entity->close();
|
||||
}
|
||||
}
|
||||
|
||||
public function __destruct(){ //pwease dont leak memory >_<
|
||||
unset($this->server->interface->maxACKsAllowed["{$this->ip}:{$this->port}"]);
|
||||
}
|
||||
|
||||
public function save(){
|
||||
if($this->entity instanceof Entity){
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue