View
215
Download
1
Tags:
Embed Size (px)
Citation preview
Goal
Introduction to UML: what are classes and instances? Basic project analysis
Introduction to Prototyping/AgentSheets Game #1: Frogger
UML = Unified Modeling Language helps you specify, visualize, and document
models of object-oriented software systems, including their structure and design.
More information: http://www.omg.org
Diagrams Structural Diagrams (represent static application structure)
Class Diagram (examples) Object Diagram (examples) Component Diagram Deployment Diagram
Behavior Diagrams (represent different aspects of dynamic behavior) Use Case Diagram Sequence Diagram Activity Diagram Collaboration Diagram Statechart Diagram
Model Management Diagrams (ways you can organize and manage your application modules) Packages Subsystems Models
Game 1: Frogger
You are a frog. Your task is simple: hop across a busy highway, dodging cars and trucks, until you get the to the edge of a river, where you must keep yourself from drowning by crossing safely to your grotto at the top of the screen by leaping across the backs of turtles and logs. But watch out for snakes and alligators! (Sega, 1980)
What are the Object Classes/Instances?
Step #1: Mark nouns You are a frog. Your task is simple: hop across a
busy highway, dodging cars and trucks, until you get the to the edge of a river, where you must keep yourself from drowning by crossing safely to your grotto at the top of the screen by leaping across the backs of turtles and logs. But watch out for snakes and alligators!
What are the Operations/Methods?
Step #2: Mark verbs You are a frog. Your task is simple: hop across a
busy highway, dodging cars and trucks, until you get the to the edge of a river, where you must keep yourself from drowning by crossing safely to your grotto at the top of the screen by leaping across the backs of turtles and logs. But watch out for snakes and alligators!
Class 3: Truck Class name
Attributes
Operations
Truck
X: integer
Y: integer
Direction: String
drive ()
Object Diagram
The AgentSheets Worksheet IS THE Object Diagram Shows ALL the instances Indicates the relationships between instances
(spatially)
Homework 2
Download AgentSheets Key will be emailed to you Build Frogger game Email project (Alex & Andri)
Windows: use “email project” feature Mac: stuff project folder
Due: Sept. 10 Read UML introduction: http://www.omg.org/
gettingstarted/what_is_uml.htm