I just started a similar project a few days ago, you can check it out on GitHub .
He should give you some ideas on how the game works. Like some details of a scrolling 2D map with a collision (which turns out to be quite complicated if you want to get a 100% error). Oh, and he uses SDL, as many of them have already suggested.
As for me, this is my first C project. But I have to admit that I used to do similar things in Java and Python, so it was a good way to quickly learn C. And since it is learning, not some productive material, I use a simple C99, which makes the task even “funnier”.
But back to the game, you really need to think about your design before you start coding, write it on a piece of paper or, if you look like me, and you are not a tree in which you can write it in pseudocode.
Think about as many possible game states as possible, nothing worse than reinstalling the entire player / card / everything from scratch, just because you had not thought about the XYZ function before.
Design is very important if you do not have a goal to start, your project will reach the point where it fails, like my Tuff , it also failed due to the lack of music and someone who would develop enemies, etc.
Speaking of graphics, etc., keep in mind that a game will consist of much more than just simple code. If you are not good at graphics, then consider this when designing. Because you quickly lose your motivation when the only things on the screen are colored rectangles.
source share