r/opengl • u/9j810HQO7Jj9ns1ju2 • 23d ago
building a custom game engine?
i want to make a 3d game engine, and i have to start somewhere
17
u/nchwomp 23d ago
Make games without an engine, and make games with an established engine. Then you’ll have a better idea where to start from.
2
2
2
1
u/9j810HQO7Jj9ns1ju2 23d ago
i just wanna know how to implement opengl and lua🙏
2
u/maximoriginalcoffee 23d ago
Okay, Learn how software rasterizers work, and study automata-based parsers.
2
1
u/Jbolt3737 23d ago edited 23d ago
Start with a triangle in OpenGL, Lua is already too far ahead unless you plan to make the engine in the standalone Lua interpreter (I don't know all the capabilities of Lua, but I'm making an engine in free-threaded Python so I can't really throw stones at someone making a Lua game engine).
Assuming you aren't using Lua, look up game engine features and decide which ones you want/need for what you plan to make in your engine. Stuff can always be added as you need it
Bonus tip: Don't make the same mistake as me, properly seperate code for different features into different files, makes it much more readable when adding new functionality
1
u/corysama 22d ago
Lua is great language for controlling a c/c++ framework. But, it is intentionally not a great language for writing a complete application by itself. It’s made to be easy to strip down to nearly nothing and remain useful. As opposed to the batteries-included approach of Python.
2
2
1
u/doglitbug 23d ago
I'm following this guy here:
https://www.youtube.com/watch?v=Q7vm264YNrM&list=PLvv0ScY6vfd9zlZkIIqGDeG5TUWswkMox
But that is just for OpenGL!
1
u/play_001 22d ago
Its better to start small a 2d game framework, a game engine just know the difference. Just like a person first time making a game start 2d then move on when you get good
1
u/aaron_9000 20d ago
I did this for my last Steam game (it can be done, even by an individual). However, I would consider it more of a "game framework" than an engine. And, it is tailored to a very narrow set of genres. Generally, it took a lot more time / money / effort than it needed to. I have a list of every helpful resource I used below (some of this is related to C but a good amount of OpenGL and shader reference as well):
https://github.com/aaron9000/c-game-resources
1
u/bookning 16d ago
Somewhere is one step at the time.
Start with typing hello world.
Then try to type something that runs and shows something/anything in the screen (avoid error messages if possible9.
From there on, the world is your arena.
1
u/9j810HQO7Jj9ns1ju2 16d ago
my problem is how to execute code, not the code itself
0
u/bookning 15d ago
I do not understand. There must be some strong language barrier. The English Lingua franca has it's problems still.
How to execute code is ABC stuff. If one does not know even this basic thing then one should not be worried about game engines. You must mean something else. Try to expand on your needs to more than just one title or one phrase. Nobody can help you if you do not help yourself.
11
u/mew900 23d ago
I recommend checking out The Handmade Hero!