Archived

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

How long would it take to learn SDL?

This topic is 5148 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

I am pretty confident in my C++ skills but im getting really bored with it. Making programs that have no purpose, everything in a little DOS window, and most importantly, just text! I want to start learning SDL, how long do you think it would take until I can get a decent build of something running? I always wanted to make a 2d platformer but I dont want to get ahead of myself. Im still trying to figure out how design works. Up until about a month ago I didnt know for a game to work right you have to program it in order (Start of game-level 1-end).

Share this post


Link to post
Share on other sites
if you dont have any C++ difficulties and are good with searching thorugh documentation. It wont take more then a few minutes to get the simplest sdl app running.

follow a tutorial and it will take even less time.


:::: [ Triple Buffer ] ::::

Share this post


Link to post
Share on other sites
My only problem is that the tutiorals at Cone3D are a little confusing. They use C most of the time, which I dont know or understand. Is there any other tutiorals for SDL rather then those that are a little easier? Is there a SDL book that I could find at Barnes and Noble or something?

Share this post


Link to post
Share on other sites
Woah, you know C++ but you can't understand C? Cone3D is IMHO simpler than the SDL Documentation. The only book that I know of that teach SDL is "Programming Linux Games", not to be confused with "Linux Game Programming".

[edited by - Skeletal on November 8, 2003 9:08:27 PM]

Share this post


Link to post
Share on other sites
C is more or less C++ without classes (there are some other differences, but at the level of the tutorial they shouldn't come up). If its the code you don't understand, you aren't ready. If you find the tutorial to be confusing in the way its written, you only really have three other choices. One is the SDL documentation, which probably isn't any better than Cone3D, I found it worse from the first parts of each that I read. Two is Programming Linux Games, I'm not sure how good that is. There is also another SDL book, called Focus on SDL. I'd say either download PLG or get used to Cone3D. You can probably have a clone of pong after an hour or so, probably less.

[edited by - Aerolithe on November 8, 2003 10:29:43 PM]

Share this post


Link to post
Share on other sites
SDL is really easy to get going with - you can have a app coded to create a window and display an imge in about 5 minutes, the tutorials at Cone3D may not be the best out there for SDL but they will introduce you to SDL and help you get started. Once you have a understanding then the SDL docs may not seem so intimidating

Share this post


Link to post
Share on other sites
quote:
Original post by Aerolithe
You can probably have a clone of pong after an hour or so, probably less.



Unlikely. He needs to understand timers, collision detection, keyboard handling, basic animation and scoring system, even for Pong. Plus learning SDL. No way is an hour enough.

Share this post


Link to post
Share on other sites
Personally, I find the SDL docs are fine (the ''SDL Guide'' section in particular.

Richard "Superpig" Fine
- saving pigs from untimely fates, and when he''s not doing that, runs The Binary Refinery.
Enginuity1 | Enginuity2 | Enginuity3 | Enginuity4 | Enginuity5
ry. .ibu cy. .y''ybu. .abu ry. dy. "sy. .ubu py. .ebu ry. py. .ibu gy." fy. .ibu ny. .ebu
"Don''t document your code; code your documentation." -me

Share this post


Link to post
Share on other sites
quote:
Original post by Thrust
Im still trying to figure out how design works. Up until about a month ago I didnt know for a game to work right you have to program it in order (Start of game-level 1-end).


Actually, for anything but pretty simple games, that''s a really, really bad way of doing it - writing code for each individual level.

What you want is a data-driven architecture. This means that you have a single CLevel object, which can load in a text file as source data (containing, for example, the positions of all objects in the level).

If a given level needs special functionality, you could either provide that functionality to all levels and just not use it on any others, or you could derive a class from CLevel, modify the behaviour, and use it specially for that level ("if(level==10)return new SpecialisedLevel(); else return new Level();")

Why''s it so great? It means that you (or indeed others) can make changes to the level data without having to rebuild the program.

Richard "Superpig" Fine
- saving pigs from untimely fates, and when he''s not doing that, runs The Binary Refinery.
Enginuity1 | Enginuity2 | Enginuity3 | Enginuity4 | Enginuity5
ry. .ibu cy. .y''ybu. .abu ry. dy. "sy. .ubu py. .ebu ry. py. .ibu gy." fy. .ibu ny. .ebu
"Don''t document your code; code your documentation." -me

Share this post


Link to post
Share on other sites