Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

I'm looking for a little direction.

I'm building a game engine as a part of my university project, and I'm having a little trouble about what to look for when it comes to indoor 3D game worlds.

Now I say indoor specifically because I have already set up an outside environment with heightmaps and skyboxes, so I'm roughly in the know with that.

What I'm struggling with is what I should be looking at to help me build an indoor level of my game, for instance on board a spaceship.

So my question is, how would I go about building an indoor world with walls, doorways, windows etc?

I'm using C++ OpenGL and SFML to build the engine, and the game levels in mind will be fairly big, so it would be appreciated if this was kept in mind whilst answering my question.

Any tutorials or guides will also be appreciated.

share|improve this question
    
Any information will be appreciate guys... –  Tom Burman Jan 27 '13 at 18:12
    
Your question is very general. It's not much different than building outdoor levels, as far as I'm concerned. So I have a hard time understanding what you have trouble with now. You put a couple of walls and props to create rooms and walkways, then create a pathing grid so people can't walk through walls. A very simple window to look out into the space could just be a border with some texture inside it. If you want to be fancy you can move the texture based on the view angle of the camera to create the illusion of depth. –  s3rius Jan 28 '13 at 20:30
    
Are you asking an art question about how to build the geometry etc. for an indoor level, or are you asking a technical question about how you might approach rendering differently for indoor vs outdoor levels? –  Nathan Reed Apr 25 '13 at 18:37

1 Answer 1

up vote 3 down vote accepted

There haven't been many answers, so I'll just chip in what I can. Disclaimer: I really do not have much experience in 3D. This is from what little experience I do have.

I am fairly sure UDK and many other engines use, for indoor surfaces, static meshes. They block out levels using rough polygon geometry and use these to playtest in the beginning, but then have artists build meshes and substitute these for the geometry when it's time to start thinking about releasing.

However, I do know for a fact that nearly everything in Valve's Source Engine (TF2, Half-life 2) is polygon geometry. Stairs, buildings, most of the levels are just made of rectangles and the occasional wedge. To be honest, I'm not sure how exactly they're defined in the .bsp format, but I'd imagine it's fairly simple.

Even then, they do need some static meshes (represented, during collision, by axis-aligned bounding boxes) so they can represent things like trees, or fences, or other complex geometry. In addition, they have heightmaps (named displacements) to take care of terrains. Using these three tools (brushes, meshes & displacements), good level designers, and a hell of a lot of optimization tricks, Valve manages to make some pretty impressive maps. Here's an example (credit goes to visualwalkthroughs.com for the screenshot):

half life 2 screenshot

Nearly everything you see here is simple convex geometry (except for the robot, of course). The arch is made up of triangles approximating a curve.

What I'm trying to get at here is that there's no shame in using plain block geometry, just defined as coordinates & length/width/height. Basically, your hallways would just be made of four rectangular prisms - a floor, two walls, and a ceiling. Doorways would also basically be walls, except the wall would have to be made into three rectangles - two for the sides, one for the top of the doorway. Windows... well, you'd have to think about those yourself, because 3D lighting is beyond the scope of this post.

If I were starting out, I'd probably just go with that kind of static geometry at first, and then work on some sort of mesh loader later to pretty up the maps. Hope that helps.

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.