Package model

Class Map

java.lang.Object
model.Map
All Implemented Interfaces:
Serializable

public final class Map extends Object implements Serializable
Implementation of Map class.
See Also:
  • Constructor Details

    • Map

      public Map(String name, Terrain[][] tiles)
      Parameters:
      name - the name of the Map
      tiles - the tile grid of the Map
    • Map

      public Map(Map map)
      Copy constructor for Map class.
      Parameters:
      map - the Map to copy
    • Map

      public Map()
      Constructs a default Map instance if the Map file is not found.
  • Method Details

    • getName

      public String getName()
      Returns the Map instance's name.
      Returns:
      the Map instance's name
    • getTiles

      public Terrain[][] getTiles()
      Returns the Map instance's tile grid.
      Returns:
      the Map instance's tile grid