Class PassableObstacle


  • public class PassableObstacle
    extends PathObstacle
    Created with IntelliJ IDEA.
    Since:
    : 3/31/2015 Time : 5:50 PM
    • Constructor Detail

      • PassableObstacle

        public PassableObstacle​(java.lang.String name,
                                java.lang.String action,
                                Tile startTile,
                                Tile endTile,
                                Tile obstacleTile)
        Instantiates a new Path obstacle with name action, and both primary and secondary tile.
        Parameters:
        name - the name of the obstacle.
        action - the action to preform to complete this obstacle.
    • Method Detail

      • duplicate

        public PassableObstacle duplicate​(Tile obsTile)
        Description copied from class: PathObstacle
        Duplicates the current PathObstacle and sets the obstacle's tile to given tile
        Specified by:
        duplicate in class PathObstacle
        Parameters:
        obsTile - Obstacle's tile
        Returns:
        duplicated PathObstacle
      • traverse

        public boolean traverse()
        Description copied from class: PathObstacle
        Traverses the obstacle **NOTE** this is not abstract to preserve currently compilation of existing overrides At some point when deprecated methods start to be removed, this *will* become abstract
        Overrides:
        traverse in class PathObstacle
        Returns:
        true if successfully traversed
      • isCompleted

        public boolean isCompleted()
        Description copied from class: PathObstacle
        Checks if the obstacle has been completed
        Specified by:
        isCompleted in class PathObstacle
        Returns: