Is getting an image to the screen in SDL an accomplishment?

Started by
8 comments, last by Willy The Vinyl Frog 11 years, 11 months ago
I mean it wholeheartedly ... is getting an image blitted, capable of taking input, understanding the very most basic concepts of SDL, along with some C++, an achievement?

Does it mean that there's hope for me to succeed?

Because lately I've been VERY discouraged with coding due to the horror involved with pong pong game development ... perhaps I should practice more with SDL and C++ before diving in to a ping pong game?

Any help would certainly give me a new direction.

Thanks.

PS: To add, I managed to strictly write all the code from scratch with no references at all. Is that a bonus?

By "no references" I mean that I started from #include all the way to the very last
;
.

And I looked up nothing about SDL or C++ to my aid. However, pursuing a game like ping pong put me off VERY easily.

The mechanics, implementation of the code, how it works, the pointer use, functions, memory passing, collision detection entities from enums with pointers(that also confused me), text implementation from SDL_ttf, classes, data altogether, etc., etc., etc.

It was very difficult to break down because I'm not too novice with C++ beyond the basics to work with APIs alone.

And the specific implementation to apply certain aspects and parts of the game's functionality to proper use with endless possible ways to tackle problems also confused me - I just thought, "How the hell should I implement something when I'm not sure how to implement and implementation of something through many other things?".

I tried learning all that stuff, but it just pushed me in other directions further and further away from the goal - I eventually gave up is what I'm saying because it got too absolutely incomprehensible to completely understand and write with no assisted help , copy/pasting, etc.

Any ideas on how you managed to just "get it" all as well, and be able to independently structure a game without reference to some key aspects, self-implementation techniques you learned, maybe something else?

It would be nice to share.

Thanks twice.
Advertisement
It's something, but I don't think the way you did it was to your benefit. Resources, documentation, tutorials, etc are there to be used, and even the most experienced people will use them.

Direct3D has need of instancing, but we do not. We have plenty of glVertexAttrib calls.

I'm sure you've learned a thing or two about this endeavor, however keep in mind that all good programmers use all sorts of different references and resources, and most also provide back to the community by providing the very same.

I think you'll find that you'll improve more quickly if you improve your knowledge of the language first; learning how computers work with memory, then onto pointers, will provide you a great deal of insight and knowledge that you'll find useful if you wish to program without automatic memory management.
Definitely use more tutorials, and you will understand more and more as you go along. Most things have been written thousands of times already by different people, and by learning from those with experience you avoid making a thousand unnecessary mistakes.
That said it's always very good for learning purposes to try and solve something using the knowledge you already have, before looking up the answer, but if you hit a wall then don't hesitate to search for an answer, and if you can't find one, ask for help. Then when it works, try to understand the answer.
Hello!

You could say that walking from sweden, where I live, to Spain is an accomplishment (roughly 2500KM).
However, taking an airplane would also get me there and probably faster.
If I walk there, there is a huge(!) chance I'll get tired before I reach my goal, and stop walking.
However there is always a chance the plane crashes if i fly there...

Which one is the better? Well it depends on your objective I guess, but if it was up too me, I'd take the plane.

Edit: to not be a total douchebad, the point I'm trying to get across is that it is OK and often better to use avaiable resources than "doing it from scratch"
For SDL, use the Lazy Foo tutorials. They're my SDL bible, I've used them to help create my own pong game, as well as breakout and tic tac toe clones.
Yeah, Lazy Foo's tutorials seem exceptionally easy, and provide lots of basics and details.

However, I feel that most of these answers here are not specific to the entirety of my question's purpose, or what I wanted to hear. :(

I feel that most of these answers here are not specific to the entirety of my question's purpose, or what I wanted to hear.

The advice you've been given is very on-point and helpful though, and you would do well to take it on board. That being said, I'll have a go at responding to your original question myself and hopefully expanding a little more on what has been said.


is getting an image blitted, capable of taking input, understanding the very most basic concepts of SDL, along with some C++, an achievement?

Absolutely! It's one that will mean less and less to you as you gain more experience, and which a lot of more experienced developers may have even completely forgotten the joys of, but when you're first starting out it's a huge achievement to get an image on-screen and responding to input, and this is the basic foundation of all the games you'll end up building. You should definitely be proud of it, especially if you did everything yourself without using references. That being said -- and as everyone else has already covered -- this isn't necessarily an ideal approach, and there's absolutely no reason to avoid using any reference materials available to you.

Programming is all about solving problems, so it's a good idea to try to figure out the actual game logic yourself, but you should feel free to look up reference materials for C++ syntax, SDL functions, etc., and there's also no shame in getting help with the game logic if you run into a roadblock. Over time you'll find yourself able to do more and more from memory, you'll learn which functionality can simply be re-used rather than re-writing it, and you'll refer to references much less, or for more complicated things.


Any ideas on how you managed to just "get it" all as well, and be able to independently structure a game without reference to some key aspects, self-implementation techniques you learned, maybe something else?

This comes with practice and experience! You'll learn what works and how to approach certain problems by creating programs and experiencing first-hand what does and doesn't work, as well as what works but could be improved.


It seems to me like you're on the right track, and you should do just fine if you continue writing gradually more complex programs and spending the time to learn along the way. Don't be afraid of making mistakes -- they're an excellent learning experience as long as you take the time to understand why an approach didn't work and what you can do instead.

Practice, practice, practice.


Does that help at all? smile.png

- Jason Astle-Adams

Hi again Willy.

Since my last response maybe was a bit lacking I'm going to try to offer some more advice that might be valuable to you.

Lets talk a little about accomplishments...

As a person I used to get really proud of myself whenever I accomplish something. And I mean anything. Small things like adding a new type of monster to my game used to have me running to my friends or even call up my sister all excited and be all up in their faces like "look at this monster! It's soo cool, look at the spells it's using and the AI and this and that, I used this new technique bla bla..". And they would ofcourse be polite and tell me how good I was even though they didn't understand what the f*ck I was going on about.

That feeling I got from recieving (more like taking) compliments from the people close to me made me feel like I had accomplished something.
Was that a good thing? I used to think so.

Now, I had started so many games and I hadn't finished even one, and it's not that I didn't want too or that I thought the games I was working on was bad so I started thinking what it was that made me stop before i was finished, and what I realized was that in my head I had already finished them!
It turned out that the feeling of accomplishment I got from all that posetive reinforcement really was a false feeling of accomplishment, because the truth was that I hadn't accomplished anything.

My goal was to finish a game but I fealt accomplished for just putting a monster in to some tech-demo without any production value at all.
Now, whenever I really want to finish something, I keep that dream to myself in my hearth until I've seen it fulfilled, then I tell everyone but not before I'm done :-)

I really do not want to disheart you, but at the same time I do not want to feed you with false feelings of accomplishment, because the truth is this:
If you accomplished a task you set out to do, then it is an accomplishment!
Is your task to blit an image to the screen or make a game?

Now I will try to answer your questions so that I do not just ramble out of context:

[background=rgb(250, 251, 252)]Does it mean that there's hope for me to succeed?[/background]


[/quote]
As long as you belive there is hope, there is hope.


[color=#282828][font=helvetica, arial, verdana, tahoma, sans-serif]

[background=rgb(250, 251, 252)]Any ideas on how you managed to just "get it" all as well, and be able to independently structure a game without reference to some key aspects, self-implementation techniques you learned, maybe something else?[/background][/font]


[/quote]
I studied programming, game development and game design by buying books, doing online tutorials and talking to people online and then I used the skills i had learnt to build a game.

BR / AS
Well, thanks again jbadams.

You've been a great help. Way better than most of the other answers(no offense).

But I want to know if it's normal to be put off by 3-D programming as a beginner to game programming as a whole(in terms of accomplishment, not actually trial and error).

I've been put off terribly by a desire to create advanced games and inability to comprehend every from code to syntax, maths used, etc.

So I should best stick to the little information I know and move forward slowly?

I want to know some specifics on this - should I work up as slow as possible keeping my learning pace good rather than trying to tackle bigger things faster, like artificial intelligence?

Or would me completing a simple object moving through walls with collision be a good accomplishment?

I've set forth a goal to make a 20x20 pixel block slide between several bigger block objects that are 40x40s and reach checkpoints.

Later on I can add levels, saves, etc(but that would be WAY later on).

I don't want to actually "get down" with doing it yet because I'd like to know the ins and outs of many things before muddling in to possibly more confusion and such.

This topic is closed to new replies.

Advertisement