1 / 13

Chapter 1

Chapter 1. XNA Game Studio 4.0. Your First Project. A computer game is not just a program—it is also lots of other bits and pieces that make playing the game fun and interesting. C ontent Manager Comprehensive solution that manages XNA resources Part of the project .

luella
Télécharger la présentation

Chapter 1

An Image/Link below is provided (as is) to download presentation Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author. Content is provided to you AS IS for your information and personal use only. Download presentation by click this link. While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server. During download, if you can't get a presentation, the file might be deleted by the publisher.

E N D

Presentation Transcript


  1. Chapter 1 XNA Game Studio 4.0

  2. Your First Project • A computer game is not just a program—it is also lots of other bits and pieces that make playing the game fun and interesting. • Content Manager • Comprehensive solution that manages XNA resources • Part of the project

  3. Create Your First Project • In XNA Game Studio, select New Project from the File menu.

  4. Create Your First Project • Select Windows Game.

  5. Running Your First Program • Click the Start Debugging button

  6. What Happens? • XNA Game Studio compiles the source code files. • The source code of the program is all the lines of C# code. • A compileris a program that takes source code and creates a set of machine instructions that can be loaded into the computer’s processor to control what the computer does • The compiler rejects any program that it thinks is not correct and tells you about the compilation errors. • If all the program source files compile correctly, they are then combined with any resources (for example, images and sounds) that are part of the project.

  7. What Happens? • If you are using an external device, either Xbox 360 or Windows Phone, the compiled files are now transferred into it. • XNA Game Studio starts the program running.

  8. Stopping a Program There are two ways to do this. • You can press the Back button on an Xbox 360 gamepad or Windows Phone to instruct the program to finish. If the program is running on a remote device, XNA Game Studio displays a message indicating that the remote connection to the device has been lost. Simply click OK on the message to dismiss it. • You can stop the program from within XNA Game Studio by clicking the Stop button

  9. Storing Games on the Xbox 360 or Windows Phone • Once you’ve created a game and deployed it to an Xbox 360 or Windows Phone, the game itself remains stored inside the machine for you to load and play later, without the need for a PC to be attached. • You can find the games you have created by selecting your Game Library on the Xbox 360 or entering the Xbox Live Games menu on the Windows Phone.

  10. Running the Same XNA Game on Different Devices • You can use a single XNA workspace to hold multiple projects, one for each device you want to target. • You will find out more about projects and workspaces in the section “XNA Game Studio Solutions and Projects” in Chapter 4.

  11. Creating a Copy of an XNA Project for Another Device • Start by clicking the project in the Solution Explorer of XNA Game Studio so that it is selected. Then choose Create Copy Of Project For Xbox 360 from the Project menu.

  12. Creating a Copy of an XNA Project for Another Device • XNA Game Studio copies the project and adds the copy to the workspace. • You can select which of the projects to start by setting one of the projects as the StartUp Project. • To set a project as the StartUp project, you right-click the project and choose Set as StartUp Project from the menu that appears • When you click Start Debugging, the project that is selected as the StartUp project is the one that gets to run.

  13. Choosing Between Windows Phone and Emulator • If you have created a game that is aimed at the Windows Phone device you can select whether the game runs on the Windows Phone itself or the emulator. • To deploy to the device it must have been registered as a development device. • The phone must be connected to the computer via USB and the Zune software must be running. • The phone should not be displaying its lock screen when you try to deploy the program to it.

More Related