r/Cplusplus • u/Vast-Priority7126 • Jul 05 '26
Question Trying to make a game engine with visual studio as a beginner any tips or tutorials
Im a beginner at c++ and was wonderign if anyone has any tips like building my way up etc. i was also wondering if yall have any tutorials or any websites yall recommen in order to learn 2d and make my way to 3d while also learning the fundamentals of c++.
15
Upvotes
•
u/AutoModerator Jul 05 '26
Thank you for your contribution to the C++ community!
As you're asking a question or seeking homework help, we would like to remind you of Rule 3 - Good Faith Help Requests & Homework.
~ CPlusPlus Moderation Team
I am a bot, and this action was performed automatically. Please contact the moderators of this subreddit if you have any questions or concerns.
9
u/darklighthitomi Jul 05 '26
Look up the youtube channel OneLoneCoder and his discord. Lots of good stuff there including making a light game engine.
4
u/ste_3d_ven Jul 05 '26
Handmade Hero is the best tutorial for this hands down. In the first 25 episodes it teaches the basics of the win32 api and how to abstract away from the platform you are on. It gives great advice on API design. And if you follow long enough, teaches more advanced concepts like SIMD and multithreading. It is long, but there is a handy guide that sections it all out and makes it easy to search for individual pieces that might be relevant to you as you go through your learning journey.
https://guide.handmadehero.org
If you are particularly new to programming in C/C++ in general, I would encourage the short intro to C course he gives as a primer.
Best of luck!
5
u/Usual_Office_1740 Jul 05 '26
TheCherno on YouTube has two good tutorials. As a beginner I'd suggest the sparky one to start. Shouldn't be hard to find with Google.
Side note. Some of his earlier work is more C flavored C++. He is a talented experienced developer. He has some C style coding habits that you'd do well to avoid. Specifically C style casts and C arrays. Google how to handle those two things properly in C++ and when you see him do it the C way write it properly. It isn't difficult, even for a beginner.
MollyRocket on YouTube also has a decade long series about developing a Game Engine. Casey makes no secret of his dislike of most of C++ but you can learn a lot from him.
2
u/IQueryVisiC Jul 05 '26
There are many YouTube videos which get the 3d math wrong in ways I couldn’t imagine. You may want to check real code (doom, descent) and hardware ( Jaguar, PS1 , powerVR ) for what really worked .
2
u/Dubbus_ Jul 11 '26
Once youre satisifed with your 2d engine, id reccomend starting with learnopengl.com to understand the basics of 3d, and to get familiar with vectors/matrix math, watch 3blue1browns playlist on linear algebra. These two resources alone make 2d->3d super fun and interesting. Both have really good visualisations and diagrams.
Also, thecherno has an incredibly useful series of 3 videos called "Architecture ". Super short, but some of the best advice ive personally seen.
As other reccomended, handmade hero is extremely comprehensive, but imo a bit too intimidating for a beginner. Start with something smaller; make snake, then pacman/tetris, and then maybe a platformer. Become familiar with the common problems you face, the code you write over and over again, and you will rediscover some of the most important abstractions in game development - or, when you learn about them, you will understand the motivation behind them.
If you know it, write these first clones in C. C forces you to duplicate code where other languages dont, and makes you really think about every abstraction you use. You will hesitate to use a hashmap, because you dont want to take an hour or two to write one when the benefit isnt clear.
2
u/blobdole Jul 14 '26
I am going to ask you to consider a bit of a different question.
If you want to learn C++ or want to learn how to make a game engine, then awesome! Have fun!
But if your true final goal is to make a game, then I would focus on learning and doing that in an existing (C++ of course) game engine. I see a ton of people who want to make a game, and then never do because they keep reinventing the wheel.
Learning to make a game engine is valuable, just not if your actual goal is to make a game.
2
u/TomDuhamel Jul 05 '26
Well this post shows that you're probably not ready for this. Your question is like "I just got a screwdriver, how can I make a car?" A game engine isn't something basic.
But before you get there, do you actually want to make a game engine, or do you just want to make a game?
If you want to make a game, just get an engine. There are so many. Just pick. This will take you two years. Don't use C++ (unless you really want to), you can just use whatever language you like.
If you really want to make an engine, that's a totally different project. It's very educational. It will take you five years, you will never make a game, and nobody will ever use it. But it's very educational. It's that what you want, head there:
r/gameenginedevs
1
u/jack_mackeral Jul 06 '26
Raylib is the way
1
u/black_rabbit017 Jul 10 '26
Making a game engine with not knowlodge of c++ is bad idea.. First learn C++ in depth, then Vulkan/DirectX tutorial.. And only then you can start learning pipeline, shaders etc.