Property | Type | Description | |
---|---|---|---|
$DIRECTIONS | |||
$RELATIVE_DIRECTIONS | |||
$floor |
Method | Description | |
---|---|---|
__construct ( $floor, $x, $y, null $direction = null ) | Position constructor. | |
direction ( ) | ||
direction_of ( $space ) : string | ||
direction_stub ( ) | ||
distance_from_stairs ( ) | ||
distance_of ( $space ) : mixed | ||
is_at ( integer $x, integer $y ) : boolean | ||
move ( $forward, integer $right ) | ||
normalize_direction ( $direction ) : mixed | ||
relative_direction ( $direction ) : mixed | ||
relative_direction_of ( $space ) : mixed | ||
relative_direction_of_stairs ( ) | ||
relative_space ( $forward, integer $right ) : mixed | ||
rotate ( $amount ) | ||
space ( ) | ||
translate_offset ( $forward, $right ) : array |
public __construct ( $floor, $x, $y, null $direction = null ) | ||
$floor | ||
$x | ||
$y | ||
$direction | null |
public static normalize_direction ( $direction ) : mixed | ||
$direction | ||
return | mixed |
public relative_direction ( $direction ) : mixed | ||
$direction | ||
return | mixed |
public relative_direction_of ( $space ) : mixed | ||
$space | ||
return | mixed |
public relative_space ( $forward, integer $right ) : mixed | ||
$forward | ||
$right | integer | |
return | mixed |
public translate_offset ( $forward, $right ) : array | ||
$forward | ||
$right | ||
return | array |