Vine: added hasFace()

This commit is contained in:
Dylan K. Taylor 2022-02-01 04:01:16 +00:00
parent 25fdf7e442
commit dbe99e5821
No known key found for this signature in database
GPG Key ID: 8927471A91CAFD3D

View File

@ -64,6 +64,10 @@ class Vine extends Flowable{
/** @return int[] */
public function getFaces() : array{ return $this->faces; }
public function hasFace(int $face) : bool{
return isset($this->faces[$face]);
}
/**
* @param int[] $faces
* @phpstan-param list<Facing::NORTH|Facing::EAST|Facing::SOUTH|Facing::WEST> $faces