Sign in to follow this  
Narf the Mouse

How to get started making a game

Recommended Posts

Narf the Mouse    322
The first thing you will need to do is choose a programming language and learn how to program. This is complicated by the probable fact that you have no clue what they are or how to evaluate them. The internet, such as Google and Wikipedia, can obviously be a big help here. You can google "Programming Languages" and get all sorts of results, a few of which may even be relevant. In the end, you have some sort of sketchy idea of what they do, although you're probably still wondering about Procedural Programming versus Object Oriented versus maybe the even more esoteric Functional Programming. So, at this point, there's really only two things to do: You can go to a store (On- or off-line) and buy a $60-250 programming book or you can download a programming language and get started. Yeah. The first thing you should know at this point is that there is and isn't such a thing as "downloading a programming language". Before you get confused further, here's some terms: IDE = Integrated development Environment = Fancy Text Editor for programming. Compiler = Turns your program into machine language. Interpreter = Translates your program into machine language on the fly. This is slower. DLLs = Dynamic Link Libraries = This is where the actual programming language is, basically. They hold all the useful stuff that gets turned into your code. Obviously, these are abreviated explanations, nor does everything always work this way. However, it's good enough for now. What you need to know now is that everything you need should be installed when you download and install an IDE (Fancy Text Editor for programming). If it isn't, my advice is get a better IDE. A programmers job is to make the user's easier, not create a fancy maze. That aside, there's still the question of programming languages. Here's the basics: Variables: Remember algebra? Variables are letters and words that contain a meaning. In short, Int A = 2 assigns a value of 2 to the integer variable A. Procedural Programming: In simple, you have program code and functions. The code is executed one line at a time. With some pseudo-code (Fancy way of saying "Not actual programming code, just demonstration sample") to demonstrate;
Int A = 2
Int b = 2
Int c = a + b


We can also stick code in functions, such as:
Int A = 2
Int b = 2
Int c = Add(A, B)
END

Add(one, two)
Int three = one + two
return three


When the compiler reaches Add, it goes down to the Add function, sticks the value of A into "one" and the value of B into "two" and continues into the function code, which merrily adds and returns a value. Note, we can also write it:
Add(one, two)
return one + two


It'll just use a "hidden" variable which gets its value returned. Object Oriented Programming introduces one large thing: Classes and Objects. The best explanation is, a "Pencil" is a Class. It has data that describes it (Variables) and stuff it can do (Functions). If we create an Object of Class Pencil, we have a new Pencil.
Class Pencil
{
Bool Sharp = false

Write(String text)
BecomeObsolete()
}


Pencil somethingToWriteWith = new Pencil()


Ok, there's a bunch of new stuff here, but it's all simple, once it's broken down. A Bool is a Boolean value, which is a fancy way of saying "True or False". "Write(String text)" is the function to use to write with it. A String is a string of characters, such as "Hello World!". It's text, basically. The stuff between { and } is part of the Pencil class. And finally, "Pencil somethingToWriteWith = new Pencil()" calls a function called a Constructor which creates a new pencil. Defining a Constructor lets you make different ways of creating a pencil. Your programming language, if thirty years old *Cough*C++*Cough* may require you to create a Destructor, to destroy an Object once you're done with it. There's more, but that's the basics. Functional Programming is the spawn of Cthulhu and a chainsaw. If you know what to do with it, you can cut through nearly any problem - But trying to learn about it and use it will probably drive you insane. Now, on to a sample of programming languages: BASIC = Exactly what it says on the tin. If you can understand English, you can program in BASIC. OTOH, it's exactly what it says on the tin. Basic. Generally Procedural and Interpreted. C++ = You can do nearly anything with it, if you know how. It's the basis of a lot of computer software. If you have a desperate need for speed, it has something of an advantage. OTOH, it's a thirty-year old mess, with functions with names like itoa. ("Integer to String", if you're wondering. I dunno where the "a" came from). Object-Oriented, Compiled. Java = Scripting (Interpreted) Object Oriented language. Can run on any modern computer that has Java installed - And Java can be installed on almost any modern computer. Very easy to learn and use. C# = Microsoft's Java. Only runs on Windows. There's an unfortunately-named Mono port for non-windows platforms. Benfit? 95% of the functionality of C++, almost all of the speed and three days to learn the basics, as opposed to a month for C++. Perl = Scripting Language, Functional. OTOH, learning it will probably do wonders for your future job prospects. So, you download one of those and then what? First, start small. Figure out how to paste "Hello World!" to a console. No, I'm serious. Aside from tradition, it's the first small step - Rolling over before you can crawl. Next, start with something simple. Say, "Guess my Number" or two-player Tic-Tac-Toe. Don't do graphics; don't do AI. Not yet, anyway. After a few simple games, you'll know wether you like the programming language - And that's the most important thing, generally. You've probably noted my basis. While I acknowledge C#'s faults, it's *Fun* for me to program - Which means I don't have to force myself to program for hours. Never underestimate that. So, what now? Go on these forums again, and ask for a good beginners book for the language you choose. Check out the most suggested options - They're probably the best. If none of the listed programming languages appeal, ask around for more - There's plenty. If it ends up you don't like any programming languages, my advice is to make a living in something you like. Money really can't buy happiness. The pursuit of money above happiness, however, can buy ulcers. Things to look for in a programming book: 1) Written in plain English. People who use fancy terms too much are, plain and simply, not good teachers. 2) Many examples, explained in-depth. After every section on some code, you should have a sufficient grasp on what it does that, when you code it, you don't need to open the book again except for what you don't remember. If the book can't at least approach that, don't consider it. 3) A good price tag. AI Game Programming Gems is $60, at the very low end of the scale, but it's one of the best I've read. Price isn't always quality. 4) For learning a programming language, date. Programming languages can easily change. If you're not sure, ask on here. Once you've read through the book and programmed the examples (Trying for all of them is a pretty good idea), then you should have a better idea of what you can and can't do. Do some programming of your own until you've reached the edges of what you can do now - And then buy another book. Oh, and go on Google and Wikipedia again. You'll have a much better idea of search terms. Hopefully leaving you less confused, Goodbye for now.

Share this post


Link to post
Share on other sites
I think you're trying to do a little too much with this... article? Tutorial? Whatever. Every topic you cover is covered in more detail here: http://www.gamedev.net/reference/start_here/

Quote:
Original post by Narf the Mouse
The first thing you will need to do is choose a programming language and learn how to program.


http://www.gamedev.net/reference/programming/features/davegpg/

Quote:
IDE = Integrated development Environment = Fancy Text Editor for programming.

Compiler = Turns your program into machine language.

Interpreter = Translates your program into machine language on the fly. This is slower.

DLLs = Dynamic Link Libraries = This is where the actual programming language is, basically. They hold all the useful stuff that gets turned into your code.


None of this information seems relevant for a beginner who has not even chosen a language yet. Other than that, it's not accurate: IDEs are not fancy text editors. Sometimes, a text editor can be embedded. Gvim is a fancy text editor, but not an IDE. Compilers do not turn code into machine language, assemblers do that to the compiler's output. DLLs are not where the language actually is--language is an abstract concept. DLLs hold already compiled code and are language-independent. (Though to be honest, i'm a lot more shaky on my understanding of DLLs, so i could be wrong, for all i know.)

Quote:
What you need to know now is that everything you need should be installed when you download and install an IDE (Fancy Text Editor for programming). If it isn't, my advice is get a better IDE. A programmers job is to make the user's easier, not create a fancy maze.


My favorite, and thus subjectively-to-me the best IDE ever, Eclipse, does not come with a C++ compiler. Telling beginners that an IDE's worth is based on whether it comes with a compiler is misleading as many beginners choose DevC++ for just this reason. When was the last time you saw that site get updated?

And, in my opinion, beginners shouldn't work with IDEs. I think every C++ programmer should be versed in makefiles. Every C++ programmer should know what their tools do behind their backs.

Quote:
That aside, there's still the question of programming languages. Here's the basics:


I'm not going to pick on your programming tutorial too much, and i'm fine with the syntax you use not being of any specific language, but it doesn't feel consistent. I think it'd be better to do that part in python--the language that lets you write pseudo code that just happens to also work.

But again, your thesis is how to get started making a game and how to start programming is another topic. Delegate that job to someone who wrote a tutorial about programming. Whoever reads this is going to get such a vague idea of what to do, they're just gonna end up finding someone else's tutorial anyway.

Quote:
Object Oriented Programming introduces one large thing: Classes and Objects. The best explanation is, a "Pencil" is a Class. It has data that describes it (Variables) and stuff it can do (Functions). If we create an Object of Class Pencil, we have a new Pencil.


Better explanations have been thought of, though this is nearly on par with how i learned about classes. But, really, you're just skimming the topics here. Is it really helping a beginner to read one paragraph describing what a class is rather than telling him/her to read another's longer, more detailed explanation?

Quote:
Now, on to a sample of programming languages:


http://www.gamedev.net/reference/design/features/whatlang/

Quote:
C++ = You can do nearly anything with it, if you know how. It's the basis of a lot of computer software. If you have a desperate need for speed, it has something of an advantage. OTOH, it's a thirty-year old mess, with functions with names like itoa. ("Integer to String", if you're wondering. I dunno where the "a" came from). Object-Oriented, Compiled.


OK, you HAD to know if you criticized C++, someone would complain. C++ is thirty years old, but it's also new and evolving. However, itoa is more than thirty years old since it's a C function from stdlib.h. (All functions from a .h in C++ are inherited from C.) The a comes from array, because they didn't use "strings", but arrays of characters.

Though, i have to admit that the standard C++ way of converting integers to strings isn't great:

std::string make_string( int i )
{
std::string str;
std::stringstream ss;
ss << i;
ss >> str;
return str;
}


Quote:
Java = Scripting (Interpreted) Object Oriented language. Can run on any modern computer that has Java installed - And Java can be installed on almost any modern computer. Very easy to learn and use.


From wikipedia: Java applications are typically compiled to bytecode (class file) that can run on any Java Virtual Machine

Java is not a scripting language, although, theoretically, can't any language be scripted? javascript IS a scripting language of no relation, however.

You don't mention Python as a suggested language! It's just a preference on my part, but it was the first language i really started coding with and i still use it today.

Quote:
So, you download one of those and then what? First, start small. Figure out how to paste "Hello World!" to a console. No, I'm serious. Aside from tradition, it's the first small step - Rolling over before you can crawl.
Next, start with something simple. Say, "Guess my Number" or two-player Tic-Tac-Toe. Don't do graphics; don't do AI. Not yet, anyway.


This is exactly what your article should talk about! Even though a beginner who fallows a tutorial will learn, one doesn't always realize the extra work they should do on their own, like a "Guess my Number" game.

Quote:
So, what now? Go on these forums again, and ask for a good beginners book for the language you choose. Check out the most suggested options - They're probably the best.


If popularity denoted quality, the Atkins diet would still be around. Can you provide a rational reason that this is a case where a correlation between quality and popularity is definite?

Besides that, i wonder if anyone really needs books on this considering how many online tutorials there are. At least i've never used one to learn a language. But i don't know that i shouldn't have because maybe if i'd bought a Python book, i'd have been a better programmer sooner, and be better now.

Quote:
Hopefully leaving you less confused, Goodbye for now.


Your title was "How to get started making a game". An experienced programmer may be interested in that since s/he will have the technical knowledge, but may not be sure of the design aspect. On that point, beginners will be interested in the design aspect, which you don't cover. Programming is one way games are made, but not the only way. (See Game Maker and pals.)

Since you do not cover how to get started making games at all in your article, the title does not make sense. You only actually cover how to get started in programming, which may one day lead you to being able to make a game.

I have not seen any articles giving a good primer on how to start making games, so you might have a useful thing here, but i do not see it as useful the way you implemented it.

Also, this forum post will eventually float into obscurity, and i bet gamedev.net deletes really old posts. If your article is useful now, it will be later too, so you might want to post it on a blog of your own, or have someone host it. You could then post here a link to that. Yeah, your link would eventually die, but if people liked your article, they'd probably link to it when necessary.

I think introducing beginners to all of these concepts is a really good idea, but not the way you did it, and not when you don't set out to introduce concepts without teaching them.

Good luck on this! The last thing i want to see is this article not become better.

Share this post


Link to post
Share on other sites
Narf the Mouse    322
I think you mistook the intent of the article. You see, every so often, someone comes on asking how to make a game, without even the slightest clue where to start. This is just my humorous and hopefully non-condescending compilation of the common responses.

It's intended to give starting points, not the "complete list". :)

Share this post


Link to post
Share on other sites
jpetrie    13159
Ignoring for the moment the fact that there is quite a lot misleading or downright wrong with the information you you have posted here... this is a forum, not a blog.

If you want to write and submit an article, and have it vetted via our review board, you can contact writers@gamedev.net.

[Edited by - jpetrie on March 16, 2010 8:03:13 PM]

Share this post


Link to post
Share on other sites
Guest
This topic is now closed to further replies.
Sign in to follow this