Preview

Xna Tutorial 01

Good Essays
Open Document
Open Document
4172 Words
Grammar
Grammar
Plagiarism
Plagiarism
Writing
Writing
Score
Score
Xna Tutorial 01
Lab 1 – Building a Basic Game
Project XNA 2010 - Phil Ward & Paul Taylor 2010 (Revised by Andrew Herbert 2010)
This is the biggest and hardest tutorial you will have to do, it’s a fair bit of work, but once you have finished you will be ready to build heaps of games.
What are we building?
THE Color Game – Yes it is spelt wrong, but that is how you’ll need to spell it when you are programming the game!
Using your keyboard (and later on an Xbox 360 controller) you need to press the letter (R G B Y) or coloured button on the controller which matches the colour of the screen. By time we have finished three tutorials, you’ll be forcing players to think quickly, and giving them scores, taking away lives, and telling them when the game is over. To start with we will get the screen colour changing, and then start using the keyboard. * Creating a new project
Visual Studio 2008:
Start->All Programs->Microsoft XNA Game Studio 3.1->Microsoft Visual Studio 2008
Select File->New->Project
C# Express:
Start->All Programs->Microsoft XNA Game Studio 3.1->Microsoft Visual C# 2008 Express Edition
Select File->New Project

Select the XNA Game Studio 3.1 icon underneath the Visual C# node. A set of available projects will appear in the right pane. Then select the Windows Game (3.1) Icon

Give your project a name (such as PaulsGame) and simple location such as c:\XNA\,and then click on the OK button.
This will create the base Object and functions needed to build a game.
This will create a basic game for you, and you will be presented with the Visual Studio Interface.
On the Right hand side you will see the Solution Explorer

In the middle of the screen you will see the code window, the important things to look at are the Open File Tabs across the top, these will let you change objects very quickly later on, and the Method Selector, which you will be using a lot to find the method you want to edit.

By default the base Object is

You May Also Find These Documents Helpful

Related Topics