Skip to content

Instantly share code, notes, and snippets.

@PJZ9n
Created April 21, 2020 23:22
Show Gist options
  • Save PJZ9n/e7328bf1cb60bf2b968249a84a6e78e5 to your computer and use it in GitHub Desktop.
Save PJZ9n/e7328bf1cb60bf2b968249a84a6e78e5 to your computer and use it in GitHub Desktop.
<?php
/**
* Copyright (c) 2020 NewCore.
*
* This file is part of NewCore.
*
* NewCore is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* NewCore is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with NewCore. If not, see <http://www.gnu.org/licenses/>.
*/
declare(strict_types=1);
namespace NewCore\Utils\Chunk;
class ChunkPos
{
/** @var int */
private $x;
/** @var int */
private $z;
/**
* ChunkPos constructor.
*
* @param int $x
* @param int $z
*/
public function __construct(int $x, int $z)
{
$this->x = $x;
$this->z = $z;
}
/**
* @return int
*/
public function getX(): int
{
return $this->x;
}
/**
* @return int
*/
public function getZ(): int
{
return $this->z;
}
/**
* @param int $x
*/
public function setX(int $x): void
{
$this->x = $x;
}
/**
* @param int $z
*/
public function setZ(int $z): void
{
$this->z = $z;
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment