Jump to content
  • Advertisement

Archived

This topic is now archived and is closed to further replies.

Xeon

Newbie in need of help!

This topic is 6928 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

Hello, I have beeen trying to learn C for the past several months. I have learned several things about the language such as loops, arrays, pointers, and writing and reading I/O. However I am very anxious to start writing games and I am sick and tired of typing out boring code from the book which I bought. Anyways, I was wondering if any of you could tell me where I can find some source code for a simple game, such as tetris so as I may dissect the code and see how an actuall game works. I have looked through this site and have yet to find source code for a simple game. Any help would be appreciated

Share this post


Link to post
Share on other sites
Advertisement
If you''re tired of typing up all the examples and learned about that sort of thing from your book- well, all I can say to you is too bad. If you were to look at just about any game, you couldn''t understand it yet because you have to know a little bit more than JUST C. Sorry to burst your bubble, but giving you the source to just about any game in windows will not help you at all. Keep with the C- your time will come soon enough.

GO LEAFS GO!

Share this post


Link to post
Share on other sites
Actually, posting code can help alot, i learn better from code than from instruction...

and now im working on an OpenGL engine with realstic physics... (hard to explain, very expandable, built in shock obsorber handling; like enter the hight, radius, numebr of coils, and thickness of coils...and it handles it...)

And the only book ive really read was one on OpenGL...and then a few physics books, but those are really non related.

Share this post


Link to post
Share on other sites
I think that source code is by far the best way to learn game programming. By analysing and modifying existing code you can learn far more than you can from most books.

Also, Xeon said that he had already spent months learning C, I think that he should be proficient enough by now to understand a simple game like tetris.

Jon Hobson

Share this post


Link to post
Share on other sites
Really? Geez, I guess I''m just really weird then! If someone gave me the source to ANY game, I wouldn''t be able to figure out how the entire game was made so well that I could make one myself. Like, if someone gave me something like (assuming I knew NO C++)...

class Foo
{
public:
Foo();
~Foo();
void SetTimer();
};
void Foo::SetTimer()
{ }

if that was given to me and I didn''t know any programming, I couldn''t figure what that is for the life of me! To me, everything that happens in that really small piece of code would be jibberish if I didn''t know it. I know, he knows C, but the first time I saw Win32, it looked pretty alien with all the naming conventions. I mean, who would every know what LPCSTR mean without any kind of explanation?!


GO LEAFS GO!

Share this post


Link to post
Share on other sites

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

GameDev.net is your game development community. Create an account for your GameDev Portfolio and participate in the largest developer community in the games industry.

Sign me up!