Lecture 3 CS171: Game Design Studio 1I UC Santa Cruz School of Engineering 11 January.

Slides:



Advertisements
Similar presentations
Sequence diagram How to. Guards Sequence diagram with combined fragments and messages Sequence diagram based on figure of UML specification It.
Advertisements

Chapter 15 UML Interaction Diagrams 1CS6359 Fall 2012 John Cole.

Object-Oriented Analysis and Design CHAPTERS 15: UML INTERACTION DIAGRAMS 1.
System Sequence Diagrams
Ana M. Fernández  A UML diagram that depicts: ◦ interactions between objects. ◦ how the business currently works by showing how various.
Software Engineering COMP 201
THE OBJECT-ORIENTED DESIGN WORKFLOW UML2 Sequence Diagrams.
1 © Wolfgang Pelz UML2 UML Part Two. 2 © Wolfgang Pelz UML2 Chapters Four & Twelve Interaction Diagrams.
Essentials of interaction diagrams Lecture 23 & 24.
Essentials of interaction diagrams Lecture Outline Collaborations Interaction on collaboration diagrams Sequence diagrams Messages from an object.
Lecture 1 CS171: Game Design Studio 1I UC Santa Cruz School of Engineering 5 January 2010.
Introduction to UML (slides adapted from Michael Mateas)
UML Sequence Diagrams (Slides adapted from Michael Mateas) UC Santa Cruz CMPS 171 – Game Design Studio II
SE-565 Software System Requirements More UML Diagrams.
Sequence diagram example T120B029P pavasaris.
Unified Modeling Language
SENG 403 SENG 403 – Winter  Brief introduction to SSD  Example (A sales systems (Cashier))  Example (Monopoly game) SENG 403 – Winter 2012.
UML Sequence Diagrams Reading: UML Distilled Ch. 4, by M. Fowler
Karolina Muszyńska Based on: S. Wrycza, B. Marcinkowski, K. Wyrzykowski „Język UML 2.0 w modelowaniu SI”
Sequence Diagram Tutorial
CS3773 Software Engineering
מידול התנהגותי 1. Today’s Session Sequence Diagrams State Machines 2.
1 SAD2 - UML 2 nd Lecture Sequence Diagram and other dynamic views Lecturer: Dr Dimitrios Makris
Introduction to Interaction Diagrams Used to illustrate the dynamic behaviour of a community of objects that collaborate by passing messages in order to.
1 Sequence Diagrams (Based on Stevens and Pooley (2006, Chapters 9, 10) and Fowler (2004, Chapter 4)) David Meredith Aalborg University.
Practical Object-Oriented Design with UML 2e Slide 1/1 ©The McGraw-Hill Companies, 2004 PRACTICAL OBJECT-ORIENTED DESIGN WITH UML 2e Chapter 9: Interaction.
1 Modeling interactions and behavior Lecturer Dr. Mai Fadel.
Starting Object Design
Chapter 4: UML Interaction Diagrams. Objective Provide a reference for frequently used UML interaction diagram notation- sequence and communication diagrams.
Chapter 2, Modeling with UML: UML 2 Hightlights
1 UML Sequence Diagrams UML Distilled, Third Edition, Chapter 4 M. Fowler.
Smith’s Aerospace © P. Bailey & K. Vander Linden, 2005 Interaction and Communication Diagrams Patrick Bailey Keith Vander Linden Calvin College.
What to remember from Chap 13 (Logical architecture)
Discovering object interaction. Use case realisation The USE CASE diagram presents an outside view of the system. The functionality of the use case is.
Object-Oriented Software Engineering Practical Software Development using UML and Java Chapter 8: Modelling Interactions and Behaviour UML Sequence Diagram.
Object-Oriented Analysis and Design 1 Mira Balaban & Arnon Sturm Object-Oriented Analysis and Design Session 3a: Behavioral Modeling - Interactions.
Object Oriented Analysis and Design Sequence Diagrams.
Karolina Muszyńska Based on: S. Wrycza, B. Marcinkowski, K. Wyrzykowski „Język UML 2.0 w modelowaniu SI”
CS212: Object Oriented Analysis and Design Lecture 34: UML Activity and Collaboration diagram.
Practical Object-Oriented Design with UML 2e Slide 1/1 ©The McGraw-Hill Companies, 2004 PRACTICAL OBJECT-ORIENTED DESIGN WITH UML 2e Chapter 10: Statecharts.
Chapter 3: Introducing the UML
Sequence diagrams Practice 7. Task 1  The “Author” sends his paper to the “Editor” by the message “manuscript” and waits the confirmation.
 The Sequence Diagram models the collaboration of objects based on a time sequence.  It shows how the objects interact with others in a particular scenario.
1 Kyung Hee University Interaction Diagrams Spring 2001.
UML Diagrams (Slides adapted from Michael Mateas) UC Santa Cruz CMPS 171 – Game Design Studio II courses.soe.ucsc.edu/courses/cmps171/Winter13/01
Project 2: Phase 1 Submission 7 Late submissions 10% 10 No submissions 14% Better than project 1 phase 3 submissions 10-point bonus: If you catch the deadline.
UML Activity and Sequence Diagrams David Millard
Sequence diagrams Lecture 5. Main terms  Interaction  Life line  Activation  Executable behavior and derived behavior  Messages  Trajectory  Frame.
UML Sequence Diagrams (Slides adapted from Michael Mateas) UC Santa Cruz CMPS 171 – Game Design Studio II courses.soe.ucsc.edu/courses/cmps171/Winter12/01.
CNG 140 C Programming (Lecture set 3)
UML Interaction Diagrams
UML SEQUENCE DIAGRAM.
Sequence Diagrams.
Chapter 11: Collaboration Diagram - PART1
UML Sequence Diagrams (Slides adapted from Michael Mateas)
UML UML Sequence Diagrams CSE 403
Sequence and Collaboration Diagrams
Sequence Diagram.
Prepared By Sidra Noureen
Object Oriented Analysis and Design
System Sequence Diagrams
IMAT5205 Systems Analysis and Design
Superior University, Lahore
Unified Modelling Language
Chapter 9: Sequence Diagrams Chapter 5 in Software Engineering Book
Interaction Diagrams A Lot of UML!
Interaction diagrams Interaction diagrams are models that describe how groups of objects collaborate in some behavior. Typically, an interaction diagram.
UML Interaction diagrams
Chapter 9: Sequence Diagrams Chapter 5 in Software Engineering Book
Presentation transcript:

Lecture 3 CS171: Game Design Studio 1I UC Santa Cruz School of Engineering 11 January 2009

UC SANTA CRUZ UML Sequence diagrams  Sequence diagrams capture the temporal order of interactions between system objects (might be literal code objects or subsystems)  You should capture a sequence diagram for each of the important chains of events that happens in your game  Collision detection  Controller event (player pressing a button)  Main loop  NPC action selection (if there are significant inter-object interactions)  Interface interactions

UC SANTA CRUZ Lifelines  Lifelines represent object instances or roles  The box at the top of the lifeline names the object instance or role  A dotted line under the box indicates how long the object lives Object name Class

UC SANTA CRUZ Messages  Messages indicate method invocations between objects – more generally, messages sent between roles  Bars on the lifeline indicate the period of time during which execution/handling of the message takes place  Dotted lines indicate return  Returns are optional, though it’s recommended to use them if you are returning a value

UC SANTA CRUZ Instances may create new instances  If you need to show one instance creating another, use the > message stereotype  StarUML doesn’t let a > message (stimulus) connect directly to a object/role box, so here’s an approach you can use

UC SANTA CRUZ Self messages and call stacks  Objects/roles can send messages to themselves  If working with object instances, this represents a method on an instance invoking other methods on the same instance  Bars are nested to indicate the call stack

UC SANTA CRUZ Indicating if-then semantics on individual messages  Guards are used to indicate if-then semantics on individual messages  The message is sent only if the test in square braces is true guard Multi-instance StarUML problem: arguments?

UC SANTA CRUZ Combined fragments  Combined fragments frame a subset of object interations  They are used to show that a subsequence has alternatives (if then blocks) or loops  Here’s a loop example Loop control (use name field) Annotation label used for comment

UC SANTA CRUZ Alt fragments  Alt fragments indicate if-then blocks  Use interaction operands to indicate alternative sequences [foreach character]loop Test Invinciblealt c : CollisionManager char : Character hero : Character 8 [collision] : isAttacking() 9 : doDamage() 10 : kill() 11 : damage() [invincible] [!invincible]

UC SANTA CRUZ Miscellaneous features  All the message types used in the example are blocking message types (normal method invocations)  Non-blocking messages (e.g. sending a request via an IPC mechanism like sockets) are indicated with open arrowhead  Parallel processes can be indicated with a par combined fragment  Various view options exist  Hide/show sequence numbers, show message arguments, etc.  Important! View options can’t be retrospectively applied. So select view options before starting diagramming