View page as slide show

Game Programming - Class One

  • The basics

Introduction

  • We will be looking at programming for real-time interactive games
  • We will start at a top level
    • (Re)view the highest-level main stages of a game implementation
    • Do a tutorial for a simple game, that focuses many key concepts

Main Stages

  • Initialization
  • Game Loop
  • Finalization

Initialization

  • Configuration
  • Sub-system initialization and configuration
  • Resource Loading
  • Pre-computations
  • Overall setup

Game Loop

  • Update
    • Input handling
    • Simulations/animation parameters
    • Network
    • Audio
  • Draw
    • As fast as possible

(in these you may have embedded level/stage control, GUI interface/menus,etc.)

Finalization

  • Save relevant game state/configuration
  • Terminate network connections
  • Overall Clean shutdown of the system

Tutorial

  • Create a simple version of Pong, step by step, using XNA
  • Goals:
    • Draw attention to key concepts of game programming
    • Introduce a new platform: C#/XNA
    • Have fun

C#

  • Syntax very similar to C++
  • Main differences can be found in Moodle Resources
  • For the tutorial at hand, familiarity with C++ is enough
  • Available from Microsoft Visual C# Express Edition (see Moodle Resources)
  • In Linux you can try Mono (no support here yet, sorry)

XNA Game Studio

  • Using version 3.1
  • Installed over Visual C#/Visual Studio 2008
  • Works over Microsoft .NET 3.5
  • Provides a framework with a series of components that abstract hardware and simplify many common tasks
  • In Linux you can try MonoXNA (no support here yet, sorry)