Home Grown game engine

Started by
21 comments, last by johnhattan 18 years, 6 months ago
Quote:Original post by counterrabbit
depends how good you are at c++, if youve only been doing it a couple of months id give it another year before you even start to try or you will ed up like me bald


I disagree. It depends more on the principles of software engineering than your knowledge of your chosen language. A bad design is a bad design and is often nothing to do with the implementation language.
Advertisement
Quote:Why is everyone saying it takes years to develop an engine and make a game with it?
Because, without some very intensive study, it takes months if not years to recognize what the requirements of an engine are, to familiarize oneself with the mathematical and conceptual knowledge needed to design an engine, and to become profficient enough with a language to be able to implement the design in a robust manner.

You're right that starting small is good. Even a novice could probably write a simple but attractive Pong game after a few weeks of study, perhaps with a basic kernel and rendering system. But it's unlikely that the code could be reused to write some other type of game, so I personally wouldn't classify it as an engine.
MumbleFuzz
Quote:Original post by MumbleFuzz
Quote:Why is everyone saying it takes years to develop an engine and make a game with it?
Because, without some very intensive study, it takes months if not years to recognize what the requirements of an engine are, to familiarize oneself with the mathematical and conceptual knowledge needed to design an engine, and to become profficient enough with a language to be able to implement the design in a robust manner.

You're right that starting small is good. Even a novice could probably write a simple but attractive Pong game after a few weeks of study, perhaps with a basic kernel and rendering system. But it's unlikely that the code could be reused to write some other type of game, so I personally wouldn't classify it as an engine.


And that is why so many people never get shit done. They concentrate too much on that sort of stuff. Just make the game. Make it work. You can arse yourself with designing a "perfect" engine with as much total reusability as possible if you want to, but by the time you get to a certain point, you will be all burnt out. There is nothing wrong with making a reusable engine, but it's not something that a novice needs to screw around with. He needs to learn the concept of making games, the flow, the logic, the CODE.

Did YOUR first game use an engine that YOU wrote that was 100% reusable and perfectly modular with all the bells and whistles that Quake 4 has? Didn't think so.
I think evolution in your design and coding skills means that no matter what you code when you first start out in a new field you produce total crap. I scare myself when I look back at code I wrote just a couple years ago let alone 5 or 10. I can't believe how much of a dumb, horrible coder I was and probably still am! But that's natural. As you gain more experience you improve.

That why I'm jumping onto the fence in this discussion and say it doesn't matter if you choose to write your own engine or use an existing one. Either way you're just in the learning phase. Anything you produce will be crap!

The key is to find the path that will keep you motivated to keep producing crap until you start to get better.

(my byline from the Gamedev Collection series, which I co-edited) John Hattan has been working steadily in the casual game-space since the TRS-80 days and professionally since 1990. After seeing his small-format games turned down for what turned out to be Tandy's last PC release, he took them independent, eventually releasing them as several discount game-packs through a couple of publishers. The packs are actually still available on store-shelves, although you'll need a keen eye to find them nowadays. He continues to work in the casual game-space as an independent developer, largely working on games in Flash for his website, The Code Zone (www.thecodezone.com). His current scheme is to distribute his games virally on various web-portals and widget platforms. In addition, John writes weekly product reviews and blogs (over ten years old) for www.gamedev.net from his home office where he lives with his wife and daughter in their home in the woods near Lake Grapevine in Texas.

Flow diagram = good.
Ah.. so THAT'S what they call that last step.

I'm not blind yet.. so I guess I can go optimize my rendering pipeline.
I think do (engine wise) something you can make a game with. Get the game working then add features to the engine (but keep them seperate) then improve the game. Clean up the code and rewrite if you need too (just not both sides at once).

A working graphics engine (with sound but no networking) should take maybe a month or two to complete. Make a test application that is seperate that tests new engine features as you create them too. You likely only need to put in 20 hours a week of time to do this (weekends are great). If you have less time expend the period. It's a time for learning not perfecting.

I love listening to people say an engine takes years. Yes it does, if like mentioned before you are attempting a HL2, Unreal 3 or Quake 4 killer engine. Start small, start modular. It might run slower but you should be out to learn.
Quote:Original post by Laz

Write a simple engine that doesn't have real-time lighting, doesn't have bump mapping, etc etc etc... and you should be good to go. Start small.


I agree.

Writing a game engine is a good experience, even for a beginner, because it requires a better foundational knowledge of software engineering than game design. When you're designing a game with a pre-built engine you get to use pre-packaged code. The code you're actually writing won't be used by anyone - even yourself. Once you're done with it the only time you'll ever need to touch it is for maintenance later on.

A game engine is different. When it's done you're going to be using this code. If you've done a poor job with it you'll know, because it'll be difficult to work with or improve. You'll also be able to more clearly see where you've gone wrong and to improve upon it, if necessary.

I also agree that it doesn't take years if you start small. I think the best way to approach this particular problem is to decide on and do some preliminary design work for a simple game. Maybe not Pong simple, but nothing much more complex than Asteroids. Look at your game and decide what the requirements for it are. What does the engine need to be able to do to support the game?

Once you've worked that out you can get to work, being careful to build your engine with flexibility and extensibility in mind. I know it's easier said than done, but if you work with that goal in mind the limited scope of your first project won't limit the scope of the engine. Once you finish your simple game project, you can decide on a slightly more complex game and extend your existing engine code to support that.

By the time you get to the third iteration, your engine will probably be good enough that you can reuse it for a lot of easy projects. You could also continue to extend its functionality and build more and more complex games. Is it going to be better than a commercial engine? Of course not. It won't even be as good as the vast majority of free engines, but there's no reason it can't be good enough for your own purposes and there are some definite advantages to using your own code. Building everything from the ground up will also give you a deeper understanding of the decisions other people have made with their engines, should you ever choose to use one.

In short: I think building an 'engine' is the best thing you can do to start out. If nothing else, it'll help to teach you the benefit of designing clean, reusable code. I know it's not a popular opinion, but I think starting by building an actual game isn't the best idea, since the ease of using pre-built engines can mask some of the actual difficulty in game development enough that it's easy to bite off more than you can chew.

[Edited by - Paradoxish on October 11, 2005 3:33:05 PM]
Heh, this whole discussion is moot, really. What's the use in trying to write an engine (or use a pre-existing one) if you don't have simple game logic figured out?

Pong doesn't require a freakin engine. Neither does Tetris.

Make Pong. Make Tetris. Make a game. Don't try using Torque to make Pongtris.

I think arsing yourself over a choice of engine or a decision of an engine design is WAAAY to premature at this point for the OP ... keep in mind, his first 7 words were "I'm looking into becoming a game programmer."

This topic is closed to new replies.

Advertisement