Currently I’ve been trying to learn sdl2 alongside c++ as my first language, and my goal has simply to make a game with a Sprite that can be moved by the keyboard and maybe jump and eat things? I wanted my first game to be some sort of tamagotchi game. besides that, I’ve been starting with online YouTube videos I’ve found and it’s been difficult to debug and understand any issues from a video where I can’t really see the final code. Luckily errors can be googled but right now I don’t even understand the code thats in the tutorial, much less a problem and solution example. My idea to tackle this was to try and break down the code in the error documentations one by one somehow, researching each line, but that has been difficult because I’ve been falling into a rabbit hole trying to research to understand the semantics. The other idea was to focus on the SDL library, research each part to the very basics, then string a program together. But that sounds tedious to research everything when I only want the functions and values to make a game, much less find documentation that can give me a deep understanding of semantics starting from roughly understanding statements and hello world. What resources are good for getting to that point?
Whenever someone on this forum asks for tutorial resources, I always gives them a link to Lazy Foo’s SDL tutorial site, and I will do it this time too: https://lazyfoo.net/tutorials/SDL/
I’m not the author of the site.
The site is very good when it comes to teaching SDL, aswell as other stuff, and it’s this site that helped me learn SDL and helped me get the knowledge I have today. I really recommend you to check it out.
So Lazy Foo starts out with by saying this:
These tutorials were designed for C++ programmers who want to move from text based games to real time games with graphics.
And I would say that anybody who wants to learn c++ (as a first language none the less!) should start with any of the many free, online tutorial systems and complete it, before picking something as complex as a video game, alluring as that is for a first project.