Upcoming Events
Unite 2010
11/10 - 11/12 @ Montréal, Canada

GDC China
12/5 - 12/7 @ Shanghai, China

Asia Game Show 2010
12/24 - 12/27  

GDC 2011
2/28 - 3/4 @ San Francisco, CA

More events...
Quick Stats
107 people currently visiting GDNet.
2406 articles in the reference section.

Help us fight cancer!
Join SETI Team GDNet!
Link to us Events 4 Gamers
Intel sponsors gamedev.net search:

Game Programming Beginners Guide


Picking the Right Compiler

The programs you write, or source code, is stored as a text file, and you can even use Notepad to write a C/C++ program. But something needs to take that source code and convert it into an executable file. In the case of C and C++, that something is a compiler.

There are a large number of compilers available, including many free ones. It is important to choose a compiler that you are comfortable with, and the free ones have the advantage that you can try them all out and see which one you like best. However, free compilers are often not as full-featured or well-supported as commercial ones. Fortunately, most commercial compilers come in introductory or academic versions, which cost much less and usually have the same features as the full version, with the only restriction being that you cannot distribute programs you create using it (which you are not going to be doing for a while anyway).

Ultimately, the compiler you choose will depend on how much you can spend and which operating system and platform you will be developing for. If you are going to be developing for Windows, I strongly suggest using Microsoft Visual C++. It has a powerful development environment that will make a lot of things easier for you, and there is no question that no other compiler is more well-suited to developing Windows applications. If you are a student, you can obtain a copy for a significantly reduced price. If you are going to program in DOS, your best bet is probably DJGPP, which is free.

Choosing a Target Platform

Although you will probably develop for a number of platforms eventually, you are going to need to pick one to learn in. While you are learning the language, and before you get into any programming involving graphics, you will probably want to use a non-GUI operating system, such as DOS or UNIX. These will avoid the overhead involved with, for example, Windows programming, and let you just focus on learning the language.

Once you are ready to start making games, though, you should consider changing your target platform. Let's look at the more prominent options.

Windows: If you want to eventually work professionally in the games industry, or if you just want a lot of people to be able to play your game, then this is the platform you want to choose. The majority of your target audience uses Windows, and I don't see that changing any time soon. The vast majority of games today are made for Windows using a technology you have probably heard of called DirectX. DirectX is a library that allows you to access the hardware directly, which means you can write high-performance games.

DOS: DOS used to be the dominant platform for games, but those days are gone. Although some hobbyists are still making games for DOS, no commercial games are being made for DOS, and it will continue to decline as Microsoft stops supporting it. If you are just starting to make games, don't choose DOS, or if you do, don't stay with it for long. Note: because there are a large number of game programming books written specifically for DOS, there may be some justification to developing games in DOS while learning from these books. However, as the number of books for game programming in Windows grows, this argument becomes less and less valid.

Linux: Linux is a UNIX variant that has become popular lately for a number of reasons, including stability, price, and anti-Microsoft sentiment. Although the number of Linux users is still relatively small, the enthusiasm surrounding it and the potential growth of the market make it an viable choice as a target platform.

Macintosh: The Mac has a very loyal following in numbers that are not insignificant, and nearly every Mac enthusiast I have talked to has expressed a desire for more and better games for the Macintosh. I have not seen as many resources for making games for the Mac, but I am sure they are out there, so this may be a valid option too.

Consoles: The console (i.e. Playstation, N64, Dreamcast, etc.) game market is huge, and there is certainly a future in console game development. However, developing console games in a non-commercial setting is not really plausible at this time, for a number of reasons. If you develop for consoles, it will probably be while employed by a commercial game studio.



The Good Stuff


Contents
  Introduction
  Picking the Right Compiler
  The Good Stuff

  Printable version
  Discuss this article