ExplodePacket records have a signed Y coordinate -_-

This commit is contained in:
Dylan K. Taylor 2017-06-26 23:09:20 +01:00
parent 1dd8fc008b
commit 4a7c40edd5

View File

@ -51,7 +51,7 @@ class ExplodePacket extends DataPacket{
$count = $this->getUnsignedVarInt();
for($i = 0; $i < $count; ++$i){
$x = $y = $z = null;
$this->getBlockPosition($x, $y, $z);
$this->getSignedBlockPosition($x, $y, $z);
$this->records[$i] = new Vector3($x, $y, $z);
}
}
@ -63,7 +63,7 @@ class ExplodePacket extends DataPacket{
$this->putUnsignedVarInt(count($this->records));
if(count($this->records) > 0){
foreach($this->records as $record){
$this->putBlockPosition($record->x, $record->y, $record->z);
$this->putSignedBlockPosition($record->x, $record->y, $record->z);
}
}
}