data containers
Moritz
mpipahl at gspgmbh.com
Wed Jul 2 14:04:09 PDT 2008
Hello,
Im currently working on a gui framework for my game, and Im trying to
find a versatile way to build my screens.
I thought about a generic "Screen" class, which has functions like
"add_element()" to insert a sprite or text into a layer on the screen.
Rendering is then done from the lowest layer to the highest one.
My question is now how I can implement these Layers, since I didnt find
LikedLists or Hastables in Phobos.
My Idea in C++ would be to have a hashtable int to linked list, which
gives me the linked list for a layer upon inserting the layer number,
and the linked list then contains my ScreenObjects (a base class for
images, text, buttons and so on).
What would be the best way to do this in D?
More information about the Digitalmars-d-learn
mailing list