So I’m gonna make a small game using C++ and SDL2 as a play project to learn (it’s for work so no I can’t use something else). And I’m realizing that I don’t know the basic structure of a game. I make GUI applications. They don’t have things moving around much based on user input
I’m going to do this with no threads (at least to start). So I’m gonna need a main which starts a loop, this loop will need to handle both input handling and rendering the next frame, right?
Then the input has to change the state of my... “things” (what do you call them: game objects?) and based on this state they will render differently in the next frame...
So for “update world” I will need to add in collision detection... how is that normally done? https://twitter.com/ybalrid/status/1305914733988638722">https://twitter.com/ybalrid/s...
Heh, yeah, time... I need to simulate a fixed interval for each frame or this will go fast and slow and be totally useless... https://twitter.com/sweordbora/status/1305915243466575872">https://twitter.com/sweordbor...
I need to figure out how to do this
https://abs.twimg.com/emoji/v2/... draggable="false" alt="😅" title="Lächelndes Gesicht mit offenem Mund und Angstschweiß" aria-label="Emoji: Lächelndes Gesicht mit offenem Mund und Angstschweiß"> https://twitter.com/ladyaeva/status/1305916028724154369">https://twitter.com/ladyaeva/...
This looks very useful for figuring out collision detection https://twitter.com/b4dc0ffee/status/1305918906884915201">https://twitter.com/b4dc0ffee...
Ok, this sounds like a good path of increasing difficulty https://twitter.com/amigabeanbag/status/1305922817431605248">https://twitter.com/amigabean...
Oooh... smart! https://twitter.com/amigabeanbag/status/1305923126274994177">https://twitter.com/amigabean...
This definitely sounds like the way to go with walls and ground. https://twitter.com/b4dc0ffee/status/1305924317574823937">https://twitter.com/b4dc0ffee...
Yeah, projectiles sound harder to do https://twitter.com/amigabeanbag/status/1305925072205611008">https://twitter.com/amigabean...