mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-20 19:49:44 +00:00
falling tile physics rewritten, (hopefully) fixed entity collisions(only with solid blocks)
This commit is contained in:
parent
ef4b991374
commit
466d57d64b
2 changed files with 30 additions and 43 deletions
|
|
@ -95,7 +95,7 @@ class Player{
|
|||
$this->packetStats = [0, 0];
|
||||
$this->buffer = new RakNetPacket(RakNetInfo::DATA_PACKET_0);
|
||||
$this->buffer->data = [];
|
||||
$this->server->schedule(2, [$this, "handlePacketQueues"], [], true);
|
||||
$this->server->schedule(1, [$this, "handlePacketQueues"], [], true);
|
||||
$this->server->schedule(20 * 60, [$this, "clearQueue"], [], true);
|
||||
$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);
|
||||
|
|
@ -340,7 +340,7 @@ class Player{
|
|||
$this->bufferLen = 0;
|
||||
$this->buffer = new RakNetPacket(RakNetInfo::DATA_PACKET_0);
|
||||
$this->buffer->data = [];
|
||||
$this->nextBuffer = microtime(true) + 0.1;
|
||||
$this->nextBuffer = microtime(true) + 0.05;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
@ -1110,7 +1110,7 @@ class Player{
|
|||
}
|
||||
}
|
||||
|
||||
if($this->nextBuffer <= $time and $this->bufferLen > 0){
|
||||
if($this->bufferLen > 0){
|
||||
$this->sendBuffer();
|
||||
}
|
||||
|
||||
|
|
@ -1470,7 +1470,7 @@ class Player{
|
|||
$this->server->api->entity->spawnToAll($this->entity);
|
||||
|
||||
//$this->server->schedule(5, [$this->entity, "update"], [], true);
|
||||
$this->server->schedule(2, [$this->entity, "updateMovement"], [], true);
|
||||
//$this->server->schedule(2, [$this->entity, "updateMovement"], [], true);
|
||||
$this->sendArmor();
|
||||
$array = explode("@n", (string)$this->server->motd);
|
||||
foreach($array as $msg){
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue