Make an engine from scratch's resources?

Started by
12 comments, last by L. Spiro 9 years, 1 month ago

I would like to know what programs I would need to make my own engine from scratch. Yes I know it is highly un-recommended to make one from scratch if your just by yourself... But I've been learning multiple variations for multiple scripting languages. I am motivated to put in all the effort and I have alot of free time to do this. ( I know it will probably take me years ). I want to be able to control all the vertices of the models and know exactly all my limits of my engine. I don't want any criticism or asking why would you do this... I just want a slap into the right direction

Advertisement
Arguably the basics you need for a game engine would be a language, a compiler, and then the "engine" itself(code of course,) which I would say at the very least needs some way to interact with the user. From there we can say that the simplest game engine would be you creating an interactive simulation that can somehow show things to the user and react to their input.

Or put more simply, decide what you want your engine to do and get the basic steps to get it going. Want to make a 3d game engine centered around some kind of FPS? Well you'll want to get a game loop going and set up rendering and input handling. From there its all cherries on top really. Figure out how you want maps laid out, create or pick some tools to create world geometry, load it in, display it, add collision detection.

Engine is just a descriptive word for a bunch of common code, you can't make an engine without having some kind of game type in mind at least.

If you don't have anything in mind then maybe you should try making a simple game instead, make pong or something. Making a game shows you a lot about what an engine needs to be able to do and you'll have to research what you need to do it. But at the very least you need a compiler, and an IDE is very useful.

Ya im planning on something like a fps, but I want to build it from scratch and not use Unread engine or Cry-engine or stuff for this.

You just need a compiler/IDE for your language of choice, e.g. Microsoft Visual Studio for C++.

You'll then use that to create all the other tools that you require...

I would like to know what programs I would need to make my own engine from scratch. Yes I know it is highly un-recommended to make one from scratch if your just by yourself... But I've been learning multiple variations for multiple scripting languages. I am motivated to put in all the effort and I have alot of free time to do this. ( I know it will probably take me years ). I want to be able to control all the vertices of the models and know exactly all my limits of my engine. I don't want any criticism or asking why would you do this... I just want a slap into the right direction

I decided to do something similar for the purposes of learning, and I must say, you really do learn far more with this route than the typical "use a pre-existing game engine" route. For your own sanity though, I would strongly suggest using some 3rd party libraries until you have at least some game engine programming experience under your belt. Some libraries that you may want to look in to are: SDL2/SFML/GLFW (Windowing/Input), OpenGL/DirectX (Rendering), irrKlang (Audio), Assimp (Model Loading), Bullet/PhyX/Havok (Physics), GLM (Math), and GLEW if you're using OpenGL. Of course, use Visual Studio 2013/2015 with C++. Look into Trello and Github as well if you haven't already done so.

I personally believe it's better to tailor an engine for a specific game that you want to make so you have some realistic endpoint (and you have some semblance of focus, which is extremely important in project management). Once you've completed the game, you can throw away as many designs as you want, and keep the designs you liked when you start a new project. I guess what I'm saying is that the best way to evaluate your engine is to make a game with it, and following the process of game engine -> game -> next game engine iteration -> next game is far more effective than simply working on an engine. I think this is the process that people are referring to when they say to "make games, not engines" but hey, I could be wrong.

Good luck!

You just need a text editor or IDE, a compiler, a language, a brain, and patience. Oh and a large library of technical books helps too.


As for engine design. I don't recommend starting off programming an engine if it's your first time. Just do some cmd prompt games first.

If you are going to go ahead and design the engine, I personally recommend designing the engine for the genre you want. It's easier to adapt the engine that way, and there is less code to throw out. The problem is... that it's going to take longer. But it's a learning experience. As I am learning that myself.

Although I think it might be hard for absolute beginners (but I have no idea about your level of C++ expertise) I'd say www.rastertek.com does just what you want.
I also went through the entire tutorial and am in the never ending process of writing an engine although I'm now slowly thinking game rather than engine and will add more to it accordingly.
After rastertek I have learned a few useful libraries like Bullet, Assimp etc as suggested above.
Trying to use them in rastertek tutorials is an excellent exercise btw.

As an aside, I started with rastertek knowing very little about classes. My knowledge of C++ was purely procedural never truly knowing when or for what purpose to put something in a class and it's doing these tuts that not only taught me DirectX but also basic OOP. In the meantime I kept reading about C++ and DirectX from as many sources as possible.

About 10 years ago I started making my own engine from scratch. The way that I did this was based on what I was planning on doing with the engine at the time. I knew that I was going to be doing medical simulators for work, so I started building my engine around that. When that project was done, and I needed to start working on the next, I had my engine code base as a starting point for the next one. After 10 years of projects I now have an engine that has a bunch of capabilities that came from using it for different tasks.

So my advice to you would be, start small, and start with a project in mind. Build that project to completion without worrying too much about the engine. Then pick another project to work on, but this time start with the engine you already have and improve upon it.

I made the decision you did the over ten years ago now using C++, OpenGL, DirectX and some other stuff. Although my then code structure is embarrassing I actually got a good 3D game going that a few people actually played on Windows Millenium and XP. If you are curious,

https://github.com/ButchDean/AntiVirusGame2

Should give you an idea at least of the effort involved from a realistic standpoint to get it done.

This topic is closed to new replies.

Advertisement