XNA GameThemed Programming Assignments Kelvin Sung Computing and

  • Slides: 9
Download presentation
XNA Game-Themed Programming Assignments Kelvin Sung Computing and Software Systems University of Washington, Bothell

XNA Game-Themed Programming Assignments Kelvin Sung Computing and Software Systems University of Washington, Bothell Serious Game Winter School, Puerto Vallarta, Mexico, Feb 2010

Idea n Given a “Starter Project” with All Graphics and User support Does not

Idea n Given a “Starter Project” with All Graphics and User support Does not work! Ø Ø n n Students complete the system by implementing the “missing piece” Support Professors who does not know any graphics or games programming! Serious Game Winter School, Puerto Vallarta, Mexico, Feb 2010

Our Approach: Game-Themed Assignment n A set of Programming Assignment Modules … Designed to

Our Approach: Game-Themed Assignment n A set of Programming Assignment Modules … Designed to be adopted selectively in existing classes No requirements on knowledge of graphics or gaming Ø Ø n 7 assignment modules on well defined CS 1/2 topics: For example: 2 D Array / BST / Lists etc. Ø n Each module includes 2 versions: Game-themed and “traditional” console version Console version is a good reference Based on the same topics, the two versions may be different: e. g. : Ø Ø 2 D Array / BST / Lists Serious Game Winter School, Puerto Vallarta, Mexico, Feb 2010

Assignment Module: Contents n For Faculty: Summary page: prerequisite + learning outcomes Sample pre

Assignment Module: Contents n For Faculty: Summary page: prerequisite + learning outcomes Sample pre and post-tests Sample solution: console / XNA Sample Grading rubric (console / XNA) FAQs XNA Implementation Guide: on Graphics + UI Ø Ø Ø n For Students: Description of the assignment (console / XNA) Skeleton starter project (console / XNA) Ø Ø Serious Game Winter School, Puerto Vallarta, Mexico, Feb 2010

All The Assignments n XGA Release. Note Ø Operator: Console, XNA Starter, XNA Solution

All The Assignments n XGA Release. Note Ø Operator: Console, XNA Starter, XNA Solution Random Numbers & Arrays: Console, XNA Starter, XNA Solution Array of Object References: Console, XNA Starter, XNA Solution 2 D Array: Console, XNA Starter, XNA Solution Class Hierarchy: Console, XNA Starter, XNA Solution Linked Lists: Console, XNA Starter, XNA Solution Binary Search Tree: Console, XNA Starter, XNA Solution Ø Ø Ø Ø Serious Game Winter School, Puerto Vallarta, Mexico, Feb 2010

Starter Project n n Our experience: Students must modify same source code E. g.

Starter Project n n Our experience: Students must modify same source code E. g. , Operator: Ø Ø n Console, XNA Starter, XNA Solution Students are given a well defined API E. g. , BST: Ø Ø Console, XNA Starter, XNA Solution Serious Game Winter School, Puerto Vallarta, Mexico, Feb 2010

Example XGAs: Switch, Modulus, Integer Division n What Worked Well: Ø Ø n Graphical,

Example XGAs: Switch, Modulus, Integer Division n What Worked Well: Ø Ø n Graphical, interactive Forced students to think about things like mod operator, in an open-ended / real-world-ish sort of way What Didn’t Work So Well: Ø Students can do this without integer division Ø Ø (Do real division, then cast to int, then do mod) One can’t really solve this without some understanding of the video game structure – Color. Red, or a clear view of the coordinate system. Serious Game Winter School, Puerto Vallarta, Mexico, Feb 2010

Example XGAs: Binary Search Trees n Students implement a BST of chars Ø Ø

Example XGAs: Binary Search Trees n Students implement a BST of chars Ø Ø Ø n Add( char c ) Find( char c ) int Find. Tree. Depth() Clone() -> new, deep copy of the tree void Balance() // balances existing nodes in-place Students do NOT implement: Ø BST also has an in-order traverse method, privately implemented in the base class, so that the video game works, but doesn’t give away answers Serious Game Winter School, Puerto Vallarta, Mexico, Feb 2010

Example XGAs: Binary Search Trees n What Worked Well: Ø Ø Ø n Graphical,

Example XGAs: Binary Search Trees n What Worked Well: Ø Ø Ø n Graphical, interactive Nicely isolated BST – students really did not have to know about the gaming aspects Could potentially re-use Console based stuff, including unit tests, etc What Didn’t Work So Well: Ø Example being too “academic”? Serious Game Winter School, Puerto Vallarta, Mexico, Feb 2010