Requirements Analysis Documentation Class Analysis Pid Crystal Exit Ally Golem Fury Flames ====> All generalize as Tile. Hole Switch Dirt Wall Trap Arrow 4-Way/2-Way Block Death Block TILE -LIVING OR -MOVEABLE -COLOURFUL LEVEL -Aggregate relationship. It is a bunch of Tiles. -Level Size -Name -Recommended #Moves WORLD -Aggregate relationship with Levels. -Datafile -% Complete WORLDMAP -Aggregate relationship with World. -Current User MENU -Uni-directional association towards Worldmap. -Gives Current User to WorldMap. Data Dictionary Here is where we will define what each class specifically does. Pid -Living -Moveable -Hero (meaning Enemies can kill it) -Only one who can delete Crystal tiles from level. -If deleted, level fails. -If touches moving exit, level succeeds. If there are allies remaining, level fails. Crystal -Moveable -Colourful -Is a wall to anything Liveable, except Pid. Exit -Moveable -Colourful -Closed with Crystals remaining. -If Open, will delete Pid and Allies from level. If Pid deleted, level ends. Ally -Liveable -Hero (meaning Enemies can kill it) -Moveable -Can touch Exit. Golem -Liveable -Moveable -Can move Blocks. Fury -Liveable -Enemy (meaning it will kill Pid and Allies) -Moveable Flames -Liveable -Enemy (meaning it will kill Pid and Allies) -Moveable -Moves either vertically or horizontally each time Pid moves. Red Hot -Liveable -Enemy (meaning it will kill Pid and Allies) -Moveable -Moves oppositely to Pid. Hole -Will delete anything that touches it. If an Ally, Pid, Crystal or Exit touches it, level over. Switch -Colourful -If a switch is active, the colours are active. If the switch is inactive, it still interacts with the level. Dirt -Acts as a wall, but afterwards the stopped tile can move in any direction. Wall -Colourful -Will stop motion in any of the four given directions. Trap -Colourful -Moveable -Will delete anything liveable with itself. Arrow -Colourful -Moveable -Will stop any object that touches it and send it in the direction it points in. The direction changes with each touch. -The directions assigned to the arrow are done by level design. 4-Way/2-Way Block -Colourful -Liveable -Will move if pushed by something. Will only move if push happens in one of the directions this block responds to. Death Block -Colourful -Moveable -Will kill any Liveable it touches, but not delete itself. Level -Collection of Tiles -Level Name -Recommended Number of Moves -Starting Number of Crystals -World Indicator -NumberCrystals(): Determines how many crystals are left. -Touch(Tile a, Tile b): Determines the interaction if a touches b. -MoveLeft(): Will scan level and move all Left-Moving objects to the left. -MoveRight(): "" -MoveUp(): "" -MoveDown(): "" World -A collection of levels. -A co-ordinate associated with 15 levels. -An associated datafile with graphics, music, and backgrounds. -BeginLevel(): Starts the level chosen. When level ends, tells the worldmap #crystals, #moves, and finished or not. WorldMap -A collection of Worlds. -A background map, showing locations of each world. -Co-ordinates for all 6 worlds. -Username. -Current #used moves, collected crystals, and finished levels. This is stored in a user file. Menu -Can begin the game. -Can go to the Options: Controls, Sound, Music -Can quit to system. State Diagram This is simple enough. I will provide the basic statechart diagram. This is for choosing and playing a level. Sequence Diagrams This has not been completed due to the complicated nature of each interaction. Seriously, I don't have that kind of time on my hands. Suffice to say that this was mostly completed by my Use Case analysis in the RED.