what's the C++/OOP way to implement this architecture ?

Started by
20 comments, last by Norman Barrows 10 years, 7 months ago


Going defensive much?
You don't need to.
I think you should start writing something (regarding this) if you haven't already.

defensive, hardly! guess i misunderstood. writing code? or something like a blog entry?

that was just an example of the code i've written or am writing that i'm basing my observations on.

i already have pretty much all the bits and pieces for a "game engine architecture" sitting here on my hard drive, either in libraries, or as modules in game projects. but the "gestalt" of the the design has yet to fully coalesce.

its like peering through an out-of focus telescope. at first the image is general and indistinct - like the first diagram. what you're witnessing in this thread here is the slow focusing of the telescope to bring the design into clear, sharp view.

as usual, as with many of my "questions", the overall discussion is spread throughout a number of related threads, and spawned some interesting discussion.

i plan to cross link the threads for the convenience of all.

in this particular thread, at this particular time, the most helpful thing would be if someone could take a look at the snippet i posted, and tell me the c++ way to get rid of the global reference to texture[texID].

as an aside, i had another interesting insight / discovery / pattern (dare i use the term?) that i noticed, similar t the link from animation player to audio:

you can't move a ground target in a generic game engine - even given all the 3d Newtonian kinematics data required - without game specific heightmap data to set the target's new "altitude" after moving. i discovered this while turning off callbacks in the library version of the target list / game engine.

perhaps a bit tangent to the topic, but: what does everyone out there think of callbacks? like? hate? necessary evil?

i've got the engine api down to two calls:

void Zmain(Hinstance); and void Zrungame();

and about a dozen callback routines, almost half of which are empty hooks for the user' convenience, and only the remaining ones actually require any user implementation.

Norm Barrows

Rockland Software Productions

"Building PC games since 1989"

rocklandsoftware.net

PLAY CAVEMAN NOW!

http://rocklandsoftware.net/beta.php

Advertisement
Other threads related to this thread:

Norm Barrows

Rockland Software Productions

"Building PC games since 1989"

rocklandsoftware.net

PLAY CAVEMAN NOW!

http://rocklandsoftware.net/beta.php

This topic is closed to new replies.

Advertisement