13. Creating gameplay

Image

What you will learn

In this chapter, you’ll write your first proper game, with a beginning, a middle, and an end. You’ll find out how a game gets input from players and uses it to control objects in the game. You’ll also discover how games detect when objects on the screen interact and how you can use these interactions to generate gameplay. Games are not just about images, though, so we’ll also consider how a game can produce sound output and display text messages for its players. At the end of the chapter, we’ll take a look at a complete game and consider how to use randomness, one of the greatest allies of the computer ...

Get Begin to Code with C# now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.