Animation and Simulation Plus Interaction

Slides:



Advertisements
Similar presentations
State Machines An approach to assembler coding. Intro State Machines are an integral part of software programming. State machines make code more efficient,
Advertisements

Artificial Intelligence in Game Design Hierarchical Finite State Machines.
Robotics Simulator Intelligent Systems Lab. What is it ? Software framework - Simulating Robotics Algorithms.
1 Flash Actionscript Animation. 2 Introduction to Sprites We will now look at implementing Sprites in Flash. We should know enough after this to create.
Lab 01 Fundamentals SE 405 Discrete Event Simulation
SE320: Introduction to Computer Games Week 8: Game Programming Gazihan Alankus.
Oakkar Fall The Need for Decision Engine Automate business processes Implement complex business decision logic Separation of rules and process Business.
Sage CRM Developers Course
Chapter 12: Simulation and Modeling
 1  Outline  world view of simulation  overview of ARENA  simple ARENA model: Model  basic operations: Model
1 OM2, Supplementary Ch. D Simulation ©2010 Cengage Learning. All Rights Reserved. May not be scanned, copied or duplicated, or posted to a publicly accessible.
Game Maker Terminology
Rational Agents (Chapter 2)
Reid & Sanders, Operations Management © Wiley 2002 Simulation Analysis D SUPPLEMENT.
MODELING EXAMPLES Types of model Conceptual Containing components that have not been clearly Identified in terms of theoretic categories such as state,
OPERATING SYSTEMS CS 3530 Summer 2014 Systems and Models Chapter 03.
Programming Games Show your rock-paper-scissors. Demonstrate bouncing ball. Demonstrate and examine Bo the dog. Homework: Modify Bo to make your own.
Computer Simulation of Networks ECE/CSC 777: Telecommunications Network Design Fall, 2013, Rudra Dutta.
SCRIPT PROGRAMMING WITH FLASH Introductory Level 1.
Finite State Machines (FSM) OR Finite State Automation (FSA) - are models of the behaviors of a system or a complex object, with a limited number of defined.
Simulation Chapter 16 of Quantitative Methods for Business, by Anderson, Sweeney and Williams Read sections 16.1, 16.2, 16.3, 16.4, and Appendix 16.1.
Today we are learning to: Understand how flow charts are used to design games Add events to our objects to control stuff in our game – (Using the user.
1 Budapest University of Technology and Economics Department of Measurement and Information Systems Budapest University of Technology and Economics Fault.
LECTURE TWO Introduction to Databases: Data models Relational database concepts Introduction to DDL & DML.
Game Maker Tutorials Introduction Clickball IntroductionClickball Where is it? Shooting Where is it?Shooting.
Business rules.
Collision Theory and Logic
Chapter 12: Simulation and Modeling
OPERATING SYSTEMS CS 3502 Fall 2017
Object-oriented and Structured System Models
Advantages of FSM Their simplicity make it easy for inexperienced developers to implement with little to no extra knowledge (low entry level)
Concurrent Systems Modeling using Petri Nets
Learning to Program D is for Digital.
Main issues: • What do we want to build • How do we write this down
Collision Theory and Logic
Compilers Principles, Techniques, & Tools Taught by Jing Zhang
Technologies Overview Media files, such as the sounds, are placed in the app’s resource folder res/raw. When an Activity is shut down, its Fragment.
ADVANTAGES OF SIMULATION
Graph Coverage for Specifications CS 4501 / 6501 Software Testing
Game Engines By James Tedder.
Datastructure.
Understanding an App’s Architecture
Discrete Event Simulation
Microsoft Access Illustrated
Introduction to Events
Knowledge Representation
Problem Solving (design of programs) CS140: Introduction to Computing 1 8/26/13.
Chapter 10 Verification and Validation of Simulation Models
Finite State Machines and Statecharts
CO Games Development 2 Week 19 Extensions to Finite State Machines
Computer Simulation of Networks
A Real-time Intrusion Detection System for UNIX
Workflow Management Systems
CSCI1600: Embedded and Real Time Software
More Explanation of an example in chapter4
Detecting and Resolving Model Errors
HAPPY NEW YEAR! Lesson 7: If-statements unplugged
Technical Implementations
Finite State Machines and Statecharts
Arrays
CSCI1600: Embedded and Real Time Software
Graph Coverage for Specifications CS 4501 / 6501 Software Testing
Week 6: Time and triggers!
Simulation Discrete Variables.
Planning and Storyboarding a Web Site
Lecture 8 Programming Paradigm & Languages. Programming Languages The process of telling the computer what to do Also known as coding.
Knowledge Representation
Games Development Game Architecture: Entities
Object-Oriented Programming (OOPs)
Assertions and Triggers
Presentation transcript:

Animation and Simulation Plus Interaction Norm Badler CSE 377 March 3, 2003

Discrete Simulation Event is primary entity. Time jumps forward to next event. Not good for animation per se as events may happen at arbitrary time points (e.g. customers arriving at a server) Time line

Animation Frames must be produced at fixed time intervals, whether or not anything is actually happening. In general, this means that animated actions must be represented as functions of TIME. Time line Frame times

So what about the EVENTS? Events are changes in the world environment caused by: User actions Objects in the world Interactions between objects (and user) E.g., Button push or mouse action Object property (movements or other attribute changes) Collisions or “in view”

Events Cause Branches in Action Stuff changes because of events in the world or user actions. HOW DO WE REPRESENT THE ACTION ALTERNATIVES? Representational options: Sequential logic (IF THEN ELSE) Finite State Machines Rule-based systems

Sequential Logic IF condition-a THEN action-1 ELSE IF condition-b ELSE IF condition-c THEN … PROBLEMS: Awkward, brittle, hard to debug and modify.

Finite State Machines Flexible for small-ish action sets. Simple semantics. Can be hierarchical (can invoke sub-FSMs) Allow clear think about the transitions in the action space.

Example Finite State Machine for a Game Watt and Policarpo

FSM Generally nodes are processes. Edges are transitions from one process to another: occur at events (as defined before) Edge transitions may be deterministic or dependent on a statistical distribution of options. Transitions may have side effects besides changing program state.

Edge Transitions Happen if something is observed (visible to entity): “Looking for enemy” changes to “Tracking enemy” Happen if objects interact: “Enemy destroyed” changes state to “Looking for [new] enemy” {note side effect!} Happen if user interacts: Button push may fire missile that collides with enemy causing it to be destroyed.

Implementing a FSM Determine process states and all possible transitions. Determine all possible variables that need checking in a state. Organize in a table. (May not be as efficient as sequential logic but easier to design and maintain!)

State Var –1: Enemy in view Var –2: User fires missile (in flight) Var –3 Collision detected Var –4 Missile position Var –5: User position Actions Required or Allowed Side Effects T (x,y,z)[t] (x,y,z)[inter-face] Run vaporize graphic Enemy deleted; Missile deleted; User arsenal-- User score++ F Enemy/user moves Missile deleted; User arsenal-- -

Existing FSM Packages Game engines (MOTIVATE) PaT-Nets KPL (Ken Perlin’s Language) Write your own…