Little OOP Design Problem

BlitzMax Forums/BlitzMax Programming/Little OOP Design Problem

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

Sorry about the late reply. I was trying my hand at some linux installation and I had... troubles. Finally got it to work though.

Anyway this can probably be cleaned up (a lot). To use it as is though you need to do the following.
-The setupRelation() method only needs to be implimented once in the first object, and needs to be called once for the first created object of a type. This is just so the list knows what is a parent of what.
-The init method could be replaced by a new method... i can't remember why i didn't do that in the 1st place.
-The ForList function could be implemented once I think.
Both of the following could probably be implemented as global mapping of some kind so not every object would be carrying the same information.
-p_Type is the id of the parent object should be set in the new method
-o_Index is used internally by the list

It's late right now so in the morning I'll rework it and see what I can to to make it more userfriendly and efficient.