Build an engine or Use One

Fillbert
Unregistered
 
Post: #1
What would be the best way to go about making a 3D space shooter. I am proficent in C++ and know an beginner to intermediate knowlege of OpenGL. Would my best bet to be to just make a simple engine using OpenGL. This isn't at first gonna be a complex Space Game. I plan on making the first simple level of it and adding on once I get. Also this has to be multipatform becasue the other people working wiht me are PC users? I've thought of useing the Cystal Space engine but it seems to get bad comments from peopel here and that it is hard to use? I've built games and some cool OGL apps before so I know that an engine is no easy task but any comments or help would be great. Thanks
-Fillbert
Quote this message in a reply
Moderator
Posts: 916
Joined: 2002.10
Post: #2
I would recommend hacking out an engine specifically for your game. This way, it will be optimized for your task. As for cross platforming, don't.
Seperate your game into 2 distinct modules. Interface, and back end. Interface will be stuff to get keys, get mouse, get window, get a life. Those kind of things. The back end should have most of the normal things like drawing routines (it's in opengl, it's crossplatform), physics, object management.
But do not completely reinvent all wheels, use sound libraries, don't go writing your own sound formats, and use code for importing models and such.
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #3
Quote:it's in opengl, it's crossplatform


Heh, you wish.

It's not too bad until you get to extensions, I guess...
Quote this message in a reply
henryj
Unregistered
 
Post: #4
Write the game. Don't waste time writing an engine.
Quote this message in a reply
ibullard
Unregistered
 
Post: #5
Writing an engine from scratch, even a simple one, is a very time consuming task. I'd just use an existing engine if you can find one that'll do what you want. That way you can get to the fun stuff (actually making the game)!
Quote this message in a reply
henryj
Unregistered
 
Post: #6
Maybe I don't have the same idea of what an engine is as everybody else on this forum but you know that it's not compulsory to write an engine to make a game right?

Quote:That way you can get to the fun stuff (actually making the game)!
Quote this message in a reply
Member
Posts: 79
Joined: 2002.08
Post: #7
I prefer to write my own engine (or whatever you want to call it), then I can optimize it for the project it's used in. I find that's just as easy as trying to figure out how somebody elses code/engine works.
If you write it yourself you will know inside and out out it works.

KenD
Quote this message in a reply
Member
Posts: 114
Joined: 2002.08
Post: #8
I haven't played a space shooter since X-Wing, what will the title be? Is there anywhere we can follow development or announcements?

"Most nutritionists say that Twinkies are bad. But they're not, they're very very good."
Quote this message in a reply
Member
Posts: 114
Joined: 2002.08
Post: #9
I haven't played a space shooter since X-Wing, what will the title be? Is there anywhere we can follow development or announcements?


BTW, use the prepackaged stuff.Wink

"Most nutritionists say that Twinkies are bad. But they're not, they're very very good."
Quote this message in a reply
Fillbert
Unregistered
 
Post: #10
Is there anywhere that I can just "borrow" or what ever code to load a model. I really don't under stand all teh binary operator and such or the file formates to write my own. I Searched the forms and not much came up and also the ones I've found arn't that great... I'd like a somewhat universal file format. Thanks for the sugestions so far. When I say engine I jsut mean the base set of code to run my game and make it somewhat custimizabel or esay revised... I'm not talking about a full blown 3D engine.
Quote this message in a reply
Moderator
Posts: 508
Joined: 2002.09
Post: #11
I just finished coding with a simple 3D engine that only shows a triangle being extruded. It's currently very buggy and it doesn't have any form of animation as it crashes when even attempting to do animation.

It's in Cocoa so it's not very crossplatform, but it started life as a Flash 3D engine. I might consider releasing it as open source though.

As for the models, with my engine it would be possible to write a simple text file with the coordinates of the vertices (you know, the dots that make up a 3D object). That's one of the things I'm thinking of adding, but first I need to add animation and make it less buggy.

Oh, and if you are curious about how long I spent coding the engine. Well, it took me a day. Ofcourse it was only porting I had to do (from ActionScript to Cocoa/Objective C), so perhaps add one day for the research and understanding of the code.

"When you dream, there are no rules..."
Quote this message in a reply
henryj
Unregistered
 
Post: #12
There is heaps of model loading code on the net. You can get code to load just about every format known to man. You just have to decide what app you're going to use to build your models with or what format the models are in that you are going to 'borrow'.

Writing model loaders generally isn't too difficult though, depending on the format.

First thing though is pick a model format.
Quote this message in a reply
Feanor
Unregistered
 
Post: #13
Quote:Originally posted by henryj
Maybe I don't have the same idea of what an engine is as everybody else on this forum but you know that it's not compulsory to write an engine to make a game right?
Clearly if people use the same word with two subtly different meanings, and think they mean the same thing, communication is just noise.

If you want a 3D program, you have to do a minimal set of tasks. The key task is rendering -- converting 3d models and a virtual environment into pictures. I don't know about you, but when I say engine, I mostly mean renderer. But it could also include scene state management, too. Even a simple, specialized renderer would have something in common with a generic renderer. But you can't not make a renderer, so you can't not make an engine -- although maybe it's implicit, but good modular programming means that's unlikely.

So the choice is:
1. Custom specialized engine
2. Custom general purpose re-usable engine
3. Off-the-shelf general purpose engine

The variation on 3 is whether you pay for it or use an open-source engine. The problem with the open source engines is finding one for Mac that is sufficiently mature and up-to-date. This is not a popular past-time for Mac programmers, with one exception -- Quesa. But other choices include Cube Engine (Mac port status: just started) and Ogre (Mac port status: unknown). Ogre rocks.

I would suggest you go with option 1, but use other existing GPL code where you can and make your own one-shot LGPL library, which you can include inside the app bundle. There's so much code out there, you may as well take advantage of it-- just don't violate any license agreements.

--FÎanor
Quote this message in a reply
Luminary
Posts: 5,143
Joined: 2002.04
Post: #14
We've had the discussion of "what is an engine" before.

IIRC, the only meaningful definition was something along the lines of "complete but content-less game". I think scripting is often implied, too.

One thing is quite clear from that definition, and that is that this person does not need an engine, and would probably be better off without one.

Calling the renderer the engine seems overly shallow to me -- after all, you'd be quite Miffed if you paid tens of thousands of US dollars to license the Quake 3 engine and didn't get sound, physics, input or networking...
Quote this message in a reply
Feanor
Unregistered
 
Post: #15
<sigh> Maybe I shouldn't have bothered being specific about rendering tasks vs. other tasks. I can be more concise: "You can avoid re-inventing the wheel (by using a library), but it may not save you time or effort on this one game. Follow common code re-use principles and you will do fine." I will point out that OP focused on graphics, so I unconsciously tailored my response likewise.

Now, it occurs to me that asking for advice without stating one's priorities is hopeless. Fillbert, since you brought up the idea of basing your game on a library, what benefits were you expecting, ideally?
Quote this message in a reply
Post Reply