mirror of
https://github.com/oldminecraftcommunity/NostalgiaCore.git
synced 2026-11-20 19:49:44 +00:00
project uses tabs instead of spaces(as in CONTRIBUTING.md)
This commit is contained in:
parent
f00318b6ed
commit
62571f26cd
115 changed files with 2291 additions and 2364 deletions
|
|
@ -2,26 +2,26 @@
|
|||
|
||||
class PathTile implements IElement
|
||||
{
|
||||
public $x, $y;
|
||||
|
||||
public function __construct($x, $y){
|
||||
$this->x = $x;
|
||||
$this->y = $y;
|
||||
}
|
||||
|
||||
public function equals(PathTile $t){
|
||||
return $t->x === $this->x && $t->y === $this->y;
|
||||
}
|
||||
|
||||
public function addOffset($offset){
|
||||
$this->x += $offset[0];
|
||||
$this->y += $offset[1];
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function __toString(){
|
||||
return $this->x.":".$this->y;
|
||||
}
|
||||
public $x, $y;
|
||||
|
||||
public function __construct($x, $y){
|
||||
$this->x = $x;
|
||||
$this->y = $y;
|
||||
}
|
||||
|
||||
public function equals(PathTile $t){
|
||||
return $t->x === $this->x && $t->y === $this->y;
|
||||
}
|
||||
|
||||
public function addOffset($offset){
|
||||
$this->x += $offset[0];
|
||||
$this->y += $offset[1];
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function __toString(){
|
||||
return $this->x.":".$this->y;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue