Class MazeGameArea
java.lang.Object
com.csse3200.game.areas.GameArea
com.csse3200.game.minigames.maze.areas.MazeGameArea
- All Implemented Interfaces:
com.badlogic.gdx.utils.Disposable
Forest area for the demo game with trees, a player, and some enemies.
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final int
static final int
static final int
static final int
static final int
static final int
static final int
static final float
Fields inherited from class com.csse3200.game.areas.GameArea
areaEntities, terrain
-
Constructor Summary
ConstructorsConstructorDescriptionMazeGameArea
(MazeTerrainFactory terrainFactory) Initialise this ForestGameArea to use the provided TerrainFactory. -
Method Summary
Modifier and TypeMethodDescriptionvoid
create()
Create the game area, including terrain, static entities (trees), dynamic entities (player)void
Displays the maze game areavoid
dispose()
Disposes of assets used by this component, including the maze background musicgetEggs()
Gets the list of fish eggsGets the list of enemiesgetEnemies
(Entity.EnemyType enemyType) Gets the list of enemiesgets the playervoid
Stops the musicvoid
Plays background music for the maze mini-gamevoid
spawnGreenJellyfish
(int number, float minDistToPlayer) Spawns in the jellyfish npc.void
spawnJellyfish
(int number, float minDistToPlayer) Spawns in the jellyfish npc.void
Unloads assets from the screenMethods inherited from class com.csse3200.game.areas.GameArea
spawnConvertedNPCs, spawnEntity, spawnEntityAt, spawnEntityAtVector, spawnEntityCenteredAt, unlockArea
-
Field Details
-
WALL_THICKNESS
public static final float WALL_THICKNESS- See Also:
-
NUM_WALL_BREAKS
public static final int NUM_WALL_BREAKS- See Also:
-
NUM_ANGLERS
public static final int NUM_ANGLERS- See Also:
-
NUM_OCTOPI
public static final int NUM_OCTOPI- See Also:
-
NUM_EELS
public static final int NUM_EELS- See Also:
-
NUM_TURTLES
public static final int NUM_TURTLES- See Also:
-
NUM_JELLYFISH
public static final int NUM_JELLYFISH- See Also:
-
NUM_EGGS
public static final int NUM_EGGS- See Also:
-
-
Constructor Details
-
MazeGameArea
Initialise this ForestGameArea to use the provided TerrainFactory.- Parameters:
terrainFactory
- TerrainFactory used to create the terrain for the GameArea.
-
-
Method Details
-
create
public void create()Create the game area, including terrain, static entities (trees), dynamic entities (player) -
displayUI
public void displayUI()Displays the maze game area -
spawnJellyfish
public void spawnJellyfish(int number, float minDistToPlayer) Spawns in the jellyfish npc. Jellyfish wander around, and do not actively seek the player. -
spawnGreenJellyfish
public void spawnGreenJellyfish(int number, float minDistToPlayer) Spawns in the jellyfish npc. Jellyfish wander around, and do not actively seek the player. -
playMusic
public void playMusic()Plays background music for the maze mini-game -
pauseMusic
public void pauseMusic()Stops the music- Specified by:
pauseMusic
in classGameArea
-
unloadAssets
public void unloadAssets()Unloads assets from the screen- Specified by:
unloadAssets
in classGameArea
-
dispose
public void dispose()Disposes of assets used by this component, including the maze background music -
getPlayer
gets the player -
getEnemies
Gets the list of enemies- Specified by:
getEnemies
in classGameArea
- Returns:
- the list of enemies
-
getEnemies
Gets the list of enemies- Parameters:
enemyType
- the type of enemy to get a list for- Returns:
- the list of enemies
-
getEggs
Gets the list of fish eggs- Returns:
- the list of eggs
-
getBosses
-
getFriendlyNPCs
- Specified by:
getFriendlyNPCs
in classGameArea
-
getMinigameNPCs
- Specified by:
getMinigameNPCs
in classGameArea
-