List of all files, and what they are for. - 100594493/Battleships GitHub Wiki
Resources
- Images
o Deploy
Background for the ship placement / deployment screen after clicking play.
o deploy_button_hl
Overlay for the currently selected ship in deployment screen.
o deploy_dir_button_horiz
Button for placing ships horizontally in the deployment screen.
o deploy_dir_button_vert
Button for placing ships vertically in the deployment screen.
o deploy_play_button
Play button on deployment screen, starts the game.
o deploy_randomize_button
Button that randomly places ships around the deployment screen.
o Discover
Background for the in game screen after clicking play.
o Explosion
Set of images for the explosion effect when hitting a ship.
o loader_empty
empty loading bar state seen just after opening the game.
o loader_full
full loading bar state seen just after opening the game.
o main_page
Background for the main page (home page).
o ship_deploy_horiz_1
Ship type 1 placed horizontally for use in the deployment screen.
o ship_deploy_horiz_2
Ship type 2 placed horizontally for use in the deployment screen.
o ship_deploy_horiz_3
Ship type 3 placed horizontally for use in the deployment screen.
o ship_deploy_horiz_4
Ship type 4 placed horizontally for use in the deployment screen.
o ship_deploy_horiz_5
Ship type 5 placed horizontally for use in the deployment screen.
o ship_deploy_vert_1
Ship type 1 placed vertically for use in the deployment screen.
o ship_deploy_vert_2
Ship type 2 placed vertically for use in the deployment screen.
o ship_deploy_vert_3
Ship type 3 placed vertically for use in the deployment screen.
o ship_deploy_vert_4
Ship type 4 placed vertically for use in the deployment screen.
o ship_deploy_vert_5
Ship type 5 placed vertically for use in the deployment screen.
o splash
Set of images for the splash effect when missing a ship.
o SplashBack
Background for the splash screen.
o Swinburne
Swinburne logo, used on the splash screen.
o SwinGameAni
Set of images used for the SwinGame animation on the splash screen.
- Sounds
o Hit
Played when a ship is hit.
o Horrodrone
Background music
o Lose
Played if the user loses the match.
o Sink
Played when a ship is sunk.
o SwinGameStart
Played at the splash screen with the SwinGame animation.
o Watershot
Played when a shot misses and hits the water.
o Winner
Played if the user wins the match.
Code
- src
o DeploymentController
Controls the player’s actions during the deployment phase.
o DiscoveryController
Handles the battle phase.
o EndingGameController
Manages the interactions at the end of the game.
o GameController
Controls the game, manages user input and displays the current game state.
o GameLogic
Opens the game window, keeping it open until close is requested and plays the game music.
o GameResources
Handles and Loads the game resources (images, sounds, fonts and music).
o GameState
Controls the actions and view displayed to the player.
o HighScoreController
Controls displaying and collecting high score data.
o MenuController
Handles the drawing and user interactions from the menus in the game.
o UtilityFunctions
Contains a number of utility methods for drawing and interacting with the mouse.
- Model
o AIHardPlayer
Handles the AI on the hard setting.
o AIMediumPlayer
Handles the AI on the medium setting.
o AIOption
An enumeration for the AI difficulty options.
o AIPlayer
Handles the AI on the easy setting.
o AttackResult
Gives the result after a shot has been made.
o BattleShipsGame
Adds to players to the game, verifies that both have all their ships deployed before
starting the game. Allows players to shoot and swap turns. Checks if players are destroyed.
o Direction
An enumeration for the direction the ship can be oriented.
o ISeaGrid
Allows each player to see and attack their opponent’s grid.
o Player
Has its own Player grid and enemy grid. Checks if all ships are deployed and if all ships
are destroyed.
o ResultOfAttack
An enumeration with all possible results of an attack.
o SeaGrid
Handles the sea grid in which the ships are deployed.
o SeaGridAdapter
Handles the change of tiles on the sea grid.
o Ship
Keeps track of all the details about a ship.
o ShipName
An enumeration of all the ship names.
o Tile
Tracks the state of each individual tile on the sea grid.
o TileView
An enumeration of each possible state of tile on the sea grid.