McRegion: Make nbtDeserialize() and nbtSerialize() protected

Not really sure why these are still exposed publicly.
This commit is contained in:
Dylan K. Taylor 2018-03-01 10:42:06 +00:00
parent 97bfcf6e71
commit ae2e1fdd5a
2 changed files with 4 additions and 4 deletions

View File

@ -39,7 +39,7 @@ class Anvil extends McRegion{
public const REGION_FILE_EXTENSION = "mca";
public function nbtSerialize(Chunk $chunk) : string{
protected function nbtSerialize(Chunk $chunk) : string{
$nbt = new CompoundTag("Level", []);
$nbt->setInt("xPos", $chunk->getX());
$nbt->setInt("zPos", $chunk->getZ());
@ -97,7 +97,7 @@ class Anvil extends McRegion{
]);
}
public function nbtDeserialize(string $data){
protected function nbtDeserialize(string $data){
$nbt = new BigEndianNBTStream();
try{
$chunk = $nbt->readCompressed($data);

View File

@ -49,7 +49,7 @@ class McRegion extends BaseLevelProvider{
*
* @return string
*/
public function nbtSerialize(Chunk $chunk) : string{
protected function nbtSerialize(Chunk $chunk) : string{
$nbt = new CompoundTag("Level", []);
$nbt->setInt("xPos", $chunk->getX());
$nbt->setInt("zPos", $chunk->getZ());
@ -109,7 +109,7 @@ class McRegion extends BaseLevelProvider{
*
* @return Chunk|null
*/
public function nbtDeserialize(string $data){
protected function nbtDeserialize(string $data){
$nbt = new BigEndianNBTStream();
try{
$chunk = $nbt->readCompressed($data);