mirror of
https://github.com/pmmp/PocketMine-MP.git
synced 2025-04-22 00:33:59 +00:00
RegionLocationTableEntry: require sector count to be at least 1
This commit is contained in:
parent
6bf840c72e
commit
22f25dfbdb
@ -42,8 +42,8 @@ class RegionLocationTableEntry{
|
||||
throw new \InvalidArgumentException("Start sector must be positive, got $firstSector");
|
||||
}
|
||||
$this->firstSector = $firstSector;
|
||||
if($sectorCount < 0 or $sectorCount > 255){
|
||||
throw new \InvalidArgumentException("Sector count must be in range 0...255, got $sectorCount");
|
||||
if($sectorCount < 1 or $sectorCount > 255){
|
||||
throw new \InvalidArgumentException("Sector count must be in range 1...255, got $sectorCount");
|
||||
}
|
||||
$this->sectorCount = $sectorCount;
|
||||
$this->timestamp = $timestamp;
|
||||
|
Loading…
x
Reference in New Issue
Block a user