Everyone loves playing video games, and each of us has their
favorites. Some of us are old-school and
enjoy playing the classics like Pac-Man and Space Invaders, while others may be
into the latest multiplayer online games.
Perhaps some of you would even like to create your own video games, but
how do you get started? In this blog we’ll
provide a brief overview of video game elements and design, and then introduce
you to Kobold2D, a popular framework for building video games targeted for the
Apple OS X and iOS platforms.
Introduction
Video
games come in a variety of genres, each of which has general characteristics
that distinguish it. The most common game
genres are:
- Action – these games feature real-time player interactions that emphasize physical tests of skill, and typically require quick reflexes and careful timing to complete challenges.
- Adventure - Adventure games focus on storytelling, and usually feature exploration, puzzle solving, and collecting items.
- Action-Adventure - Action-adventure game combines elements of both the adventure and action game genres. They typically feature problem-solving and physical challenges.
- Role-Playing - In role-playing games the player controls one or a small group of characters and lives as this character(s) in a fictional world.
- Simulation - These games attempt to replicate real-world experiences. The simulation follows real-world rules as much as possible, and the players employ their understanding of these rules when confronted with situations in the game. Common categories of simulation games include vehicle, life, and sports.
- Strategy - Strategy games typically have a player managing a limited set of resources to achieve a specific goal. These games can be turn-based or real-time.
- Casual - These games are those commonly played by casual gamers; they tend to be short, without a story line, and are geared towards relaxation.
- Massive Multiplayer Online (MMO) - MMO games may feature thousands of simultaneous players and basically add the capability for online gaming to the genres specified above.
Developing a Video Game
One of the key factors to understand when developing video games is their continuous nature. Specifically, many games are designed such that the game environment (i.e. game world) is continuously updated (e.g. animated), and also responds to inputs in real-time. The animation is performed by the sequential display of images, each of which is (typically) slightly different from the previous one, at a rate that gives the illusion of motion. The inputs can be received from both the player (via input devices) and input sensors. Game programs are commonly designed with a game loop to implement this continuous, real-time behavior.During game startup the program is initialized. The update stage of the loop receives inputs and updates the game state appropriately. The game state updates typically involve updating the game ‘virtual world’ per the game physics and game play components. The draw stage renders the updated game scene (i.e. its graphics, sound, and special effects) to the output device(s). The wait stage is then entered if there is time left over before starting the loop again. The game loop continues until the game ends or the player stops the game.
Introducing Kobold2D
Kobold2D is a free, open-source framework for building computer
games and graphical/interactive applications.
It is a flexible, feature-filled framework that is designed to make game
programming simpler. Kobold2D is an extended
version of the Cocos2d game framework, augmented with additional tools,
developer resources, and other software libraries that make for more efficient
and productive game development. Kobold2D
is designed for developing Apple OS X and iOS games; its minimum hardware and software
requirements are an Intel-based Mac computer running Mac OS X 10.6 or
later. An iOS device is also required if
developing games targeted for these devices.
The Xcode IDE and Objective-C language are used for programming with Kobold2D.
Features
The main features of Kobold2D include the software libraries, the installer, documentation, project templates, along with several example games. These features make it easy to quickly begin developing games.Creating an Example Game
The Kobold2D website has numerous template projects that you can use to get started. An example tic-tac-toe game developed with Kobold2d is also available for download at the Programming for Everyone website (source code files); the book also includes a detailed overview of the game's design. In an upcoming blog I'll take you step-by-step through the process of developing this game; in the meantime use these resources to get started with game programming using Kobold2D!Programming for Everyone is designed to give the reader an introduction to computer programming. The book is written for a very general audience and focuses on providing you with a detailed understanding of the basic concepts. It's also great for programmers who want to learn about other programming areas (e.g. logic programming, computer graphics, games, etc.) they may not have experience in. Whatever your age or background, Programming for Everyone will help you to understand computer programming!
No comments:
Post a Comment