Class LockedExit
java.lang.Object
nz.ac.vuw.ecs.swen225.gp22.domain.Tile
nz.ac.vuw.ecs.swen225.gp22.domain.LockedExit
Represents a tile which the player can only walk
on if they have collected all the treasures.
- Author:
- Abdul
-
Constructor Summary
ConstructorDescriptionLockedExit
(Maze.Point tilePos) Default constructor, sets the position and color of the tile, and obstructiveness to true. -
Method Summary
Methods inherited from class nz.ac.vuw.ecs.swen225.gp22.domain.Tile
getPos, isObstructive, setObstructive, setPos
-
Constructor Details
-
LockedExit
Default constructor, sets the position and color of the tile, and obstructiveness to true. An observer is also added to the player so that the obstructiveness is updated based on the treasures collected. The same observer makes sure that when they are on this tile, it is reset.- Parameters:
tilePos
- Point to set the position field to.
-
-
Method Details
-
deleteTile
public void deleteTile()Description copied from class:Tile
Called when a tile is removed or replaced. This method is not abstract because not all tiles will need special code to run on deletion.- Overrides:
deleteTile
in classTile
-
toString
-