First try at TicTacToe
Thanks for the input but I was more asking about the structure of the code. The general idea...I know I could have used classes but since I don't know classes beyond defining members and making public and private members I just used what I did know to make the game. The reason I made it was so that I could actually make something...anything. It's crushing seeing the making of even simple games so far off.
Quote:Original post by MikeWulf
Thanks for the input but I was more asking about the structure of the code. The general idea...I know I could have used classes but since I don't know classes beyond defining members and making public and private members I just used what I did know to make the game. The reason I made it was so that I could actually make something...anything. It's crushing seeing the making of even simple games so far off.
That's perfectly fine. I just wanted to show you ways to clean up the code and make it more elegant. Now, there's still even more things which could be done, but I thought classes was enough.
Now you'll have something to refer to when you start using classes [smile]
Personally, i think you should hold off on graphics until you feel really comfortable with the language. You should get comfortable with using classes, pointers, functions, and everything before going onto the hardcore stuff.
great, now all you need is to implement the minimax algorithm so that you can play against the computer. That was one of my favorite college projects.
If you did want a good, simple book to teach you how to use graphics with C++ and Windows, I can suggest Michael Morrison's "Beginning Game Programming". Even if some of the code is complex at the beginning, if you stick with it then it will become more understandable. You also gradually just pick up more C++ knowledge as you go.
With it I made some pretty cool games like Pong and stuff, which my friends all really like.
So I say it would be an excellent choice because it is a simple book that teaches you how to use graphics.
With it I made some pretty cool games like Pong and stuff, which my friends all really like.
So I say it would be an excellent choice because it is a simple book that teaches you how to use graphics.
This topic is closed to new replies.
Advertisement
Popular Topics
Advertisement