🎉 Celebrating 25 Years of GameDev.net! 🎉

Not many can claim 25 years on the Internet! Join us in celebrating this milestone. Learn more about our history, and thank you for being a part of our community!

Progress Too Slow!

posted in A Keyboard and the Truth for project 96 Mill
Published July 12, 2007
Advertisement
So I spent some time last night and this morning trying to get some graphics on the engine screen. Naturally I had my old faithful radial menus there, but I wanted something a bit better; I tried to just create a sphere mesh via the D3DX functions and draw-segment it, however that didn't give me anything, I of course neglected setting a shader and everything else so I dunno why I expected it to work *shrug*, I need more time to do it properly but I was hoping for some fast gratification.

I spent some time creating my game-state hierarchy, which consists of a base class StateNode, which contains a parent node and child nodes in a typical tree structure; a few classes extend this such as World, Room, Actor.

World acts as the root Game-State node and it's the root of rendering,transformation,serialization, etc.

Rooms exist within the world and are places that can be viewed, the World has a currentRoom property which specifies which room the player is looking at. Children of rooms can be Actors, and likely other nodes for static geometry that I've not dreamed of yet.

Actors are interactive entities that have animated geometry attached to them, which can move around, act as lights, have conversational topics associated with them etc.

It's a pretty standard object grouping combined with some SceneGraph traits.

Multiple operations will traverse this tree, especially for rendering.

I've yet to decide how to deal with rendering; I know that I'll want to group things I render by their translucency then shaders then textures; given this it seems that a Renderable interface for renderable objects might be used, then starting at a root point (the selected room perhaps) execute getRenderables() which returns back a list of all the nested renderable objects.

To keep things sorted perhaps a 'RenderingBucket' is passed in getRenderables() this object allows you to submit a renderable to the bucket which sorts it appropriately based on it's attributes, then when finished the rendering bucket can be flushed and rendered by the graphics object?

Changes are this design will be in flux for a while, but it seems like i'm on the right path.

I would love some insight if anyone has any to share :)
Previous Entry New Engine: Recycling
Next Entry More Design...
0 likes 2 comments

Comments

johnhattan
Yep, good focus there. If you spend all your time on menu special effects now, you'll have the game completely done by 2018.
July 12, 2007 07:02 PM
jpetrie
I have a bucket-based rendering infrastructure implemented now. It works pretty well; I can describe the system if you like, although it may be a bit overcomplex for your situation.
July 13, 2007 08:00 AM
You must log in to join the conversation.
Don't have a GameDev.net account? Sign up!
Profile
Author
Advertisement
Advertisement