• Advertisement
Sign in to follow this  

Home Grown game engine

This topic is 4517 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I'm looking into becoming a game programmer and while i know that there are ALOT of rendering engines out there. I can't find one thats right for me. soo.... i have decided that i am going to build my own rendering/game engine from scrach and learn all of the rendering, game logic, networking and everything else as i go along. is this a horribly bad approach and couldn't possible benefit me in any way or could this be a valuable learning experence that i won't want to pass up? (please don't use this as a plug for whatever engine you like) and if anyone knows a place where i can find information on game engine and rendering engine design/archetexture. or any good books PLEASE point me in the right direction

Share this post


Link to post
Share on other sites
Advertisement
It's probably somewhere in between.

You'll likely learn a fair bit, since something of that size is useful for design practice if anything.

That said, you're mostly likely guaranteeing that the game won't be finished for years to come.

Share this post


Link to post
Share on other sites
Hey, I'm making a inhouse engine as well. Let me tell you that it is a long way. I have been (trying at) designing my engine for a few years now (amoung other projects) and I was never satisfied with my design. =( Anyways, now that I know a lot more, I think I've stumbled upon a satisifying design. (hey I was like in middle school back then) So, I may have something to show in about a year ;).

Anyways I really do think that looking at the structure of other game engines can really help you, even if it's just the class heiarchy. The more you know about interaction between classes, the more likely you are to succeed. You can also take a look at the sources of the few that are open source, they will inspire you (hopefully)

Ogre3d and CrystalSpace are two open source engines. (Note that I really don't like Ogre's design, but that's just me...[you might like it - who knows])

[edit]: yours may be alot less complex than what i intend to do because I'm making more of a game engine/general purpose engine than just a graphics engine.

Share this post


Link to post
Share on other sites
Writing your own engine is a learning experience you definitely shouldn't pass up. However, if you want to produce a game in less than a few years from now, you may want to consider middleware.

Share this post


Link to post
Share on other sites
I think it's a great idea to make your own. Granted it will take at least a year to have a good engine and it may never be as feature rich as some out there already, but it will be a great and rewarding learning experience. I've written 2 graphics engines so far that both took me about 2 years to write. I've learned a great deal through them and my design ideas keep improving.

Share this post


Link to post
Share on other sites
Quote:
Original post by Ravuya
Writing your own engine is a learning experience you definitely shouldn't pass up. However, if you want to produce a game in less than a few years from now, you may want to consider middleware.


well right now i'm starting school for basic computer classes and won't be finished with my bachelors for a few years
then i'll work on getting a real game ;)

Axiverse i have been looking at other rendering engines like you said, but they are sooooo complex that i'm somewhat dumbfounded on how to start getting a code base working, but i guess thats one of those things that i want to be learning

Share this post


Link to post
Share on other sites
So many times I see people post on here that they want to make a game so they set out to design an engine right off the bat. A game engine is meant to be a reusable library that can be the basis of several games. It shouldn't be a one-off deal. And making an engine when you really want to make a game is often setting yourself up for failure.

I think it's always a good idea to set out to make games rather than engines when you are just starting out. Learning the concepts behind engine design & architecture comes much more easily when you have knocked out 3 or 4 games. If you've never made any games, you have to rely on studying other engines to get an idea of how to architect your own - otherwise you're just guessing at what you need. And engine A will most likely do things differently than engine B, which is structured differently than engine C. Getting some games under your belt will show you the common systems between games, what's reusable, and give you some ideas on simplifications and generalizations of your own. It can also help you to understand the differences between other engines out there.

Architecting a good engine is no easy task. Your frame of mind is just as important in game programming as your knowledge. If you view the problem from the wrong angle, you'll wind up with a skewed solution. It's much simpler to think in terms of 'game' than 'engine' in the beginning.

Of course, to each his own, YMMV, yadda, yadda. Some people are gifted enough or persistent enough to pull off anything they set their minds to. Just make sure you understand the big picture before diving in head first.

Share this post


Link to post
Share on other sites
I was interested in writing a graphics engine, and so, because I had worked with irrlicht previously, that's the one I focused on. Now, if you go to the irrlicht site he's up to version 0.12 I believe, with shaders and everything.

There is no way that I'd be able to understand all the code for all of that, so, I went to sourceforge and downloaded the source for irrlicht version 0.1

The first release, and I've found that looking at that code is not incredibly complex, but it is useful enough that I just stole the class heirachy and structure, and now I have my basic design firmly imprinted in my mind, I rarely look at the code.

Moral of the story: If you see an open source engine that looks good, find its first release and look at that code.

Oh, and if you are starting from scratch, probably forget the networking and one or two other things, because, once you have a framework, or an engine (partial or completed) that you are satisfied with, you can re-design, re-write it to incorporate networking, and you'll have a much easier time with the graphics, so you'll be able to spend most of your concentration on learning the networking part.

My opinion. [smile]

Share this post


Link to post
Share on other sites
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

Share this post


Link to post
Share on other sites
Why is everyone saying it takes years to develop an engine and make a game with it? That's bullcrap. If you're wanting to write a full blown engine with a bunch of bells and whistles, then yeah... but an engine for a first time game maker? Shouldn't take too long unless you're trying to write a Half-Life 2 clone. The current engine for my game is rather simple, and it is reusable. It didn't take me years to write (granted i've been working on the game for about a year, but maybe for a few hours every month... i'm very lazy, heh).

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.

Share this post


Link to post
Share on other sites
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.

Share this post


Link to post
Share on other sites
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.

Share this post


Link to post
Share on other sites
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.

Share this post


Link to post
Share on other sites
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.

Share this post


Link to post
Share on other sites
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.

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
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.

Share this post


Link to post
Share on other sites
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]

Share this post


Link to post
Share on other sites
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."

Share this post


Link to post
Share on other sites
Guest Anonymous Poster
if you want to make a game engine do it,
but as alreayd mention making a reuseable game engine may take a long time but if you just want a one time thing cut out any unessisary feature and hard code as much as you like and youl cut years off the development time.

Share this post


Link to post
Share on other sites
I honestly think it's a great idea to develop a game engine, but! how can you develop anything more than a shell without knowledge of how to actually make a game? I tried this a few years back and failed. It's better to know how to make an actual game before diving into the engine. It makes sense.

Share this post


Link to post
Share on other sites
Quote:
Original post by Laz
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."
Amen, brudda.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement