What to do now?
So, I'm in the process of learning python, I got the basics and a little more, I started learning this language because I got interested in programming, but recently the game development part of it got me interested as well, however, I'm not sure where to go from here.
Should I keep going with Python? If I had to, I'm not sure where to go from where I am, I started learning Javascript a while ago before finding out about the game development world, I've read I should learn C (or C#/C++ I don't even know).
The point is I'd really appreciate some guidance here, thanks a lot in advance
(English is not my native language, sorry if there's any errors)
Hi, and welcome,
I think you're doing fine. Python is a nice language to learn programming, including game programming.
python.org doesn't seem to have a wiki page dedicated to game programming, but one site I know is pygame.org Pygame is the standard Python module for writing games in Python.
As for what type of game you can make, there is an article that you can read http://www.gamedev.net/page/resources/_/technical/game-programming/your-first-step-to-game-development-starts-here-r2976
Not sure if you want to do them all (likely not), but it should help to get inspired :)
As for other languages, yes, eventually. The point is that game programming isn't that simple. If you also take on learning a new programming language at the same time, you're making it all a lot harder. I would suggest to try a new language once you are somewhat comfortable with programming / game programming.
Learning a new language does however make you a better programmer, as you get new options to choose from. I'll list a few as a reference.
The C# language is relatively close to Python (the other one being Java), which means the step won't be as large.
C is very much "bare metal programming". You'll get a deeper understanding how the computer really works, at the cost of having to write a lot of code. (Computers are a lot less smart than Python makes it believe they are.)
C++ is also close to the metal, like C, but much higher level. It's the standard language for high-end games. Like C, the C++ language gives you heaps of freedom, and assumes you know how to handle that, which makes for an interesting ride :)
I don't know Javascript, except that it's used in browsers, but you probably already figured that out :)
Anyway, have fun, if you have further questions, just ask
Hi, and welcome,
I think you're doing fine. Python is a nice language to learn programming, including game programming.
python.org doesn't seem to have a wiki page dedicated to game programming, but one site I know is pygame.org Pygame is the standard Python module for writing games in Python.
As for what type of game you can make, there is an article that you can read http://www.gamedev.net/page/resources/_/technical/game-programming/your-first-step-to-game-development-starts-here-r2976
Not sure if you want to do them all (likely not), but it should help to get inspired :)
As for other languages, yes, eventually. The point is that game programming isn't that simple. If you also take on learning a new programming language at the same time, you're making it all a lot harder. I would suggest to try a new language once you are somewhat comfortable with programming / game programming.
Learning a new language does however make you a better programmer, as you get new options to choose from. I'll list a few as a reference.
The C# language is relatively close to Python (the other one being Java), which means the step won't be as large.
C is very much "bare metal programming". You'll get a deeper understanding how the computer really works, at the cost of having to write a lot of code. (Computers are a lot less smart than Python makes it believe they are.)
C++ is also close to the metal, like C, but much higher level. It's the standard language for high-end games. Like C, the C++ language gives you heaps of freedom, and assumes you know how to handle that, which makes for an interesting ride :)
I don't know Javascript, except that it's used in browsers, but you probably already figured that out :)
Anyway, have fun, if you have further questions, just ask
Thanks a lot man, I appreciate the time you took on replying, I'm gonna check out the link you posted
Now, here's a weird proposal.
It occurred to me, maybe you could give me your email? I think everything would be easier if I could actually contact you when I have some doubt or something, obviously I would not annoy you daily, I just think I could use the help.
You can say no, though, the reply you gave is more than enough.
Thank you again
Don't worry, we're a helpful bunch here, and we're used to new people asking unexpected questions :)
Unless you insult people, you will be given a good answer, although it may not always be the answer you expect.
In society, it is often seen as bad if you have to ask a question.
Here, nobody knows everything, and asking questions about things is considered to be good. You'll get smarter (get better understanding), and often other people also learn a thing or two. So don't be afraid to ask when you want to know or when you're not sure. Everybody here has such problems, even experienced programmers. Talking about it often gives you new angles you didn't consider yourself. (Browse the forums to see all the weird topics that experienced programmers discuss :) )
Last but not least, you'll get quicker answers here (there is usually someone around scanning the forum), and you'll get better answers, as people will add things that others forgot to mention, or they correct errors.
Hello, GabrielJim!
Python is good enough for games development and I recommend you stick with it for now.
Eventually you would use PyGame(an API for games) for handling graphics, input and sound, but before that I recommend looking at the following two things...
1) Write a text-based game. This could be a "ye olde" adventure game along the lines of "You are in a room with a DRAGON, surrounded by treasure. You are armed with a FEATHER DUSTER. What now?" or perhaps a resource management game...similar to Championship Manager, where you just navigate menus via a list of options. If you are really adventureous though, one could actually make a full blown text rpg along the lines of the old Final Fantasy games! Just running from a "command prompt", or a linux "terminal", this sort of game only requires your knowledge of whatever language you are using. Give it some thought, though...
2) "Visual Programming" or making GUI apps. One of the things so easily over-looked by the beginner is that they will eventually have to create tools to make levels, characters and other such stuff for their games. Python has the capability to create windows and include menus, buttons, text fields and drop-down selection boxes. You definitely want to delve into this stuff as you can produce files that can be loaded by your PyGame program. Also, remember that text-based game stuff I mentioned before? Well, now you can beef it up with buttons, simple graphics and a menu bar to assist in saving your game instead of typing in commands, using mouse clicks! Hurrah!
...after all this, you will enter the games-api arena with the confidence of a Rock-God!
Have fun! ^_^
Don't worry, we're a helpful bunch here, and we're used to new people asking unexpected questions :)
Unless you insult people, you will be given a good answer, although it may not always be the answer you expect.
In society, it is often seen as bad if you have to ask a question.
Here, nobody knows everything, and asking questions about things is considered to be good. You'll get smarter (get better understanding), and often other people also learn a thing or two. So don't be afraid to ask when you want to know or when you're not sure. Everybody here has such problems, even experienced programmers. Talking about it often gives you new angles you didn't consider yourself. (Browse the forums to see all the weird topics that experienced programmers discuss :) )
Last but not least, you'll get quicker answers here (there is usually someone around scanning the forum), and you'll get better answers, as people will add things that others forgot to mention, or they correct errors.
Alright, i'll have it in mind if i get any problems or anything :)
Hello, GabrielJim!
Python is good enough for games development and I recommend you stick with it for now.
Eventually you would use PyGame(an API for games) for handling graphics, input and sound, but before that I recommend looking at the following two things...
1) Write a text-based game. This could be a "ye olde" adventure game along the lines of "You are in a room with a DRAGON, surrounded by treasure. You are armed with a FEATHER DUSTER. What now?" or perhaps a resource management game...similar to Championship Manager, where you just navigate menus via a list of options. If you are really adventureous though, one could actually make a full blown text rpg along the lines of the old Final Fantasy games! Just running from a "command prompt", or a linux "terminal", this sort of game only requires your knowledge of whatever language you are using. Give it some thought, though...
2) "Visual Programming" or making GUI apps. One of the things so easily over-looked by the beginner is that they will eventually have to create tools to make levels, characters and other such stuff for their games. Python has the capability to create windows and include menus, buttons, text fields and drop-down selection boxes. You definitely want to delve into this stuff as you can produce files that can be loaded by your PyGame program. Also, remember that text-based game stuff I mentioned before? Well, now you can beef it up with buttons, simple graphics and a menu bar to assist in saving your game instead of typing in commands, using mouse clicks! Hurrah!
...after all this, you will enter the games-api arena with the confidence of a Rock-God!
Have fun! ^_^
Hey!
Yes, i was actually playing around with the idea of a text based game, the thing is i don't really know how to proceed with it, should i just write a program based on if/else statements? Or do you know an easier way?
Thanks, for the reply!
GabrielJim, I would probably look at using a "switch" statement instead, for a menu.
However, I've just gone through my books, and had a look at "Python Programming for the absolute beginner", by Michael Dawson. It does seem like a perfect fit for you as each chapter is focused on making a game(or sometimes just programs) with Python. These include text-based games, and later in the book also cover GUI programming and PyGame and another library for multimedia called "livewires".
Depending on where you are, its $35 or £20. Its a book you can grow with, and takes you right up to PyGame which shows you how to make a fruit-slicing game and an Asteroids clone. Everything you need! ^_^
GabrielJim, I would probably look at using a "switch" statement instead, for a menu.
However, I've just gone through my books, and had a look at "Python Programming for the absolute beginner", by Michael Dawson. It does seem like a perfect fit for you as each chapter is focused on making a game(or sometimes just programs) with Python. These include text-based games, and later in the book also cover GUI programming and PyGame and another library for multimedia called "livewires".
Depending on where you are, its $35 or £20. Its a book you can grow with, and takes you right up to PyGame which shows you how to make a fruit-slicing game and an Asteroids clone. Everything you need! ^_^
Oh, that seems pretty perfect.
However, does it cover Python 2 or Python 3? I'm learning Python 3 and i feel like it would not be a good idea to mix it up
Assuming that nothing happens until the user has entered some input, your game is a 'while' loop with an 'input' statement and code to process that input.
Usually, you also want to print something before asking the next input, so the user knows what happened too.
You could try hangman as first text-based game, as there is very little processing to do there.
As for best way to write code, the opinions vary :) In fact, as you get more experienced you'll find new and better ways to express the same thing. Thus even the same person changes opinion over time.
In my experience, the best strategy is to start small, and slowly make it bigger. When you realize things get too large, or cannot be handled easily, stop adding and think of a better solution. Likely this will happen a few times before you get it right (and this is normal, I have programmed for 30 years, and still have this problem), but every time you find it went wrong, you learn a little so you can avoid the same mistake the next time.
As for fixing, you can either fix the code that you have at that point in time, or you can go back to an earlier version (if you have that), or you can start from scratch again. Every option has different advantages and disadvantages, as you'll find out.
Last but not least, let others read your code (the technical term is "code review" although that is a bit more formal), and read code of others. While it is scary at first, and getting comments on your work may feel awkward, it is generally given in positive spirit, as points where you can improve.
The more important part however is the explanation how to improve those points. That's the real gold, knowledge how to get better real quickly.
You can ask for a code review right here, just post the code (use the "<>" symbol for the code, as that makes it look good). You can also post code fragments that way if you have a question about some particular part.
@Anri: Python does not have a "switch" statement, you code it as a "if ..: ... elif .. : ... elif ... : ... else: ..." sequence.