Академический Документы
Профессиональный Документы
Культура Документы
Object-Oriented Analysis
&
Design with UML
By
Chan Po Ki Tiffany
03011577
&
Mak Ho Fai
03011798
COMP 2221
Lecturer: Prof. Jiming Liu
December 4, 2004
9.0 Appendix
9.1 Mindmaps 42-43
A Game Design Company, ABC, consigns us a game software project, Puzzle Bubble which
serves as an entertaining purpose. The goals are:
A way in which players can choose mode of game (VS or Story mode)
A way in which players can choose a cartoon character representing player
A way in which players can input their name if score is reached top 5
A way in which promote to next stage if present stage is cleared
A way in which link particular stage when password is input
A way in which increase difficulties in respect to stages
A way in which process linkage to 2nd Player (for VS mode)
A way in which user can process “continue” or “new start” functions once game over
A way in which output player’s score at the end of game
A way in which output the ranking list for top 5 highest scores
This software is specially designed for game support company which desire applying it to
portable technological devices such as palm, pocket PC, mobile phones. The software is
designed without many complicated functions for easy handling by users.
1.5 Notations
Ad m in istra to r Entity
Create Process
table
Process
Flow
Data Store
Database
Ad m in Entity
Ha ve Relationship
Cardinality Cardinality
Multiple Single
Cardinality Cardinality
Compulsory Optional
State States
Initial State
Exit State
Number Transitions/Actions/Events
Command to be
Executed
Data Flow
C O MMAND
Component
REC EIVE UNIT
Use Case
<<include>>
include
The following event list aims to include all events that are invoked during the processes of
data flows.
Game result
Centra
End User Execute
l command
System
Input command /
password
Pla ye r
Input Data
Ad m in istra to r
Input Command
Level 1 DFD
Pla ye r Ad m in istra to r
Administrator
Process
Data Data
Data Database
Data
Player Process
Information
Pla ye r
Pla ye r
Start
Play
again
Process Mode
Process Exit
Process
Play Character
Data Data
Start Game
External
input
Database
End Game
Exit the
game
Ad m inistra to r
AdminID,
AdminPWD
Process Login
UpdatePWD
Data Data
Old PWD
Database
Stage Password
Change New PWD
Start Game
Start
Get input
from Process Stage
keyboard
External Input
Gain stage
information from
database
Process
Process Score
Keep
Position
playing
Change
score
Save instance
change to database
Gain update
information
from database
Save action
End Game
Data
Data
To End Game
Database
End Game
Give Password
Process Score
Display the
score Enter
Name
Gain information
from database
Display
Save action
To menu
Process Menu
Save to database
To Menu
Database
Option
admit
To StartGame
Back to
ProcessMenu
Confirm?
Check to see if the
Delete Record Save action password is correct
Admin delete
the record
Data
Data
Process Menu
To End Game
Database
Sta g e Re c o rd
Ha ve
Sta g e ID Ba c kg ro u n d ID
Pa ssw o rd Re c o rd
Ha ve
P_Re c o rd
Bu b b le Re c o rd
C o m p o se d b y
Ha ve
Ha ve Ha ve
Po sitio nRe c o rd
Ha ve
Ad m in
Ha ve
Ad m in ID Ad m in PWD
Sc o re Re c o rd
Ha ve
I_Sc o re R_Sc o re Na m e Re c o rd
AdminID
Type: String
Purpose This field contains the unique name of the administrator that is
set.
Informal The AdminID should be less than 8 digits which include
Description: character and number only
Related Comes from: Admin table
Processes Goes to: Admin/PasswordRecord table
Related Database
Objects
Range 1
AdminPWD
Type: String
Purpose This field contains the password of the administrator that is set
by himself
Informal The password should be at least 8 digits which may include
Description: character and number.
Related Comes from: Admin table
Processes Goes to: Admin/PasswordRecord table
Related Database
Objects
Range 1
StageID
Type: String
Purpose This field contains the default setting of bubbles that are already
existed on the screen in each different stage.
Informal Table name must be unique
Description:
Related Comes from: StageRecord table
Processes Goes to:
PositionRecord/BubbleRecord/ScoreRecord/PasswordRecord
table
Related Database
Objects
Range None
BackgroundID
Type: String
Purpose This field contains the default setting of background that are
already preset in each different stage.
Informal Table name must be unique. Mostly, we can query a table
Description: by its name.
Related Comes from: StageRecord table
Processes Goes to: StageRecord table
Related Database
Objects
Range None
X-Co_Position
Type: String
Purpose This field contains the information that if the x-coordinates of
the position that is still empty or occupied.
Informal Table name must be unique
Description:
Related Comes from: PositionRecord table
Processes
Goes to: BubbleRecord table
Related Database
Objects
Range None
Y-Co_Position
Type: String
Purpose This field contains the information that if the y-coordinates of
the position that is still empty or occupied.
Informal Table name must be unique
Description:
Related Comes from: PositionRecord table
Processes
Goes to: BubbleRecord table
Related Database
Objects
Range None
I_Bubble_Name
Type: String
Purpose This field contains the instance bubble name.
For example, R(0,0) ,it means the Red color bubble ball placed
on the top-left corner.
Informal Table name must be unique
Description:
Related Comes from: BubbleRecord table
Processes Goes to: PositionRecord/StageRecord table
Related Database
Objects
Range None
C_Bubble_Name
Type: String
Purpose This field contains the recorded score that the top-5 highest
score that maybe different user who get in different time.
Informal Table name must be unique
Description:
Related Comes from: BubbleRecord table
Processes Goes to: PositionRecord/StageRecord table
Related Database
Objects
Range None
C_Bubble_Color
Type: String
Purpose This field contains the coming bubble name that is generated
but not shoots out yet.
Informal Table name must be unique
Description:
Related Comes from: BubbleRecord table
Processes Goes to: PositionRecord/ StageRecord table
Related Database
Objects
Range None
Specification
(BNF)
S_Bubble_Name
Type: String
Purpose This field contains names of the special function bubble balls.
Informal Table name must be unique
Description:
Related Comes from: BubbleRecord table
Processes Goes to: PositionRecord/ StageRecord table
Related Database
Objects
Range None
I_Score
Type: String
Purpose This field contains the instance score that the user gets. It will
continuously to be added according the game still being play by
the user.
R_Score
Type: String
Purpose This field contains the recorded score that the top-5 highest
score that maybe different user who get in different time.
NameRecord
Type: String
Purpose This field contains the corresponding name entered by the top-5
highest score player.
Informal Table name must be unique
Description:
Related Comes from: ScoreRecord table
Processes Goes to: ScoreRecord table
Related Database
Objects
Range 5
P_Record
Type: String
Purpose This field contains different 4-Digit password that preset and
can be accessed directly to corresponding stage.
Informal The password must be 4 digits which may include character and
Description: number.
Related Comes from: PaswordRecord table
Processes Goes to: Stage table
Related Database
Objects
Range None
6
Login
1
Logout
1
5
2 Execute 3
Command
Modifying
Stage Modifying
Password 4 4 Score Record
START
10
Reading user 4 Choosing Starting
command play mode Game
5
1 2 3
11 15
Choose Go to Option Exit Process
character screen stage
5 6 7 8
Reading user
Choose Showing User enters 14 command
difficulty ranking list password
9
5
16
Deleting all
data in DB
Exit
5 3
18
1
Pla ye r Ad m in istra to r
Administrator Boundary
Process
Transform
Center
Data Data
4
Data Database
Data
Player Process 3
拖曳側邊控點以
改變文字區塊的
寬度。
Information
Pu zzle
Pla ye r Bu b b le
O p e ra tio n
C o m m a nd
C o m m a nd Exe c u tio n
Re c e ive Un it
Pro c e ssin g
Sa ve Un it 3
Un it
1 2 O utp u t
Re su lt Un it 4
ted e
ecu o b
t
Ex and t
sul
Re
mm
rm
C O MMAND
Co
Resu n
nfi
utio
REC EIVE UNIT
lt
Co
O UTPUT RESULT
Exec
UNIT
Execution
Execution
Result
Result
UNIT
Command to be
Confirm Result
Execution
Execution
Executed
Result
Result
G ET EXTERNAL PRO C ESS MENU
INPUT
Execution
LO G IN
Result
Database
Confirm Result
Command to be
Executed
DISPLAY
C HANG E STAG E
PASSWO RD
Player Score
Display
information Stage
Password «include»
«include»
Ranking
list
«include»
Database
«include»
Update
Record
«include»
Manage Delete
Database Record «include»
Change
Administrator
StagePwd
<<instantiate>>
+getID(AdminID) : void 1
+getPWD(AdminPWD) : void
Database
1 -AdminID : int
-AdminPWD : String
-StageID : String
-BackgroundID : String
-P_Record : String
-R_Score : int
1 1
1
Score Stage
Checking
-I_Score : int -StageID : String
-R_Score : int -BackgroundID : String
+Update(I_Score) : void -P_Record : String 1
+Display(R_Score) : void +gotoStage(P_Record) :void
+Delete() : void
1
User
Login(AdminID,AdminPWD)
false:=<undefined>login(ID,PWD)
ErrorMsg(login)
true:=<undefined>login(ID,PWD)
SuccessMsg(login)
AdminMenu
EnableUse()
Description of Login
The interaction starts at the top of the diagram, and time flows down the diagram from
top to bottom.
At the top of the diagram, there is an instance of the actor representing the user, the
login menu object, the database and the menu object. Each object shown has a dashed
line extending below its icon.
When the login system receives the Login(AdminID,AdminPWD) data, it will check the
user information from the database.
When the user inputted information checked in the databse by check(AdminID,
AdminPWD) method and returns true, SuccessMsg(login) will enable the login user to
use the functions in its user level. If it returns false, ErrorMsg(login) disappears.
Admin
Admin(ID,PWD)
true:=<undefined>login(ID,PWD)
SuccessMsg(login)
EnableUse()
UpdateStagePWD(OldPWD,NewPWD)
SuccessMsg(update)
MainMenu Database
User
Selete(Play)
Get(StageData)
Send(StageData)
EndGame(Continue)
Send(Score)
Display(Score)
Description of Play
The interaction starts at the top of the diagram, and time flows down the diagram from
top to bottom.
At the top of the diagram, there is an instance of the actor representing the user, the
Main menu object and the database object. Each object shown has a dashed line
extending below its icon.
When the user selected to start game, Get(StageData) will require the database send out
all necessary data for initial the game.
When there is game over, EndGame(Continue) option will appear. If the user select yes,
it will loop and start the game again. If No, the score who got will send to database and
recorded with Send(Score) function. Database will also send back a Display(Score) to
display the top 5 highest score player.
8.4 Score Sequence Diagram
User Admin
Selete(Option)
Click(Option)
Display(score) Display(score)
SucessMsg(Display) SucessMsg(Display)
Delete(score) Delete(score)
Login(AdminID,AdminPWD)
SucessMsg(Display)
ConfirmMsg(Delete) ConfirmMsg(Delete)
Description of Score
The interaction starts at the top of the diagram, and time flows down the diagram from
top to bottom.
At the top of the diagram, there is an instance of the actor representing the user, the
It will be the same step and function when the administrator want to do the above
instructions.
9.0 Appendix
9.1 Summary of Mind Map
Application
o palm / pocket PC
Users
o Software Developers
Read
Write
Modify