Sup guys, so I was wondering as my needs for using this engine include using multiple "levels" or maps if you will, whats the best way of handling multiple play areas. I know that Scrolls does this, which I'm working on implementing, but I wanna know how to do it another way, just to keep options open.Thx in advance. :laugh:
Easiest way is probably to create an [level1] object in your ini files setting up all the objects, and a [level2] etcetera. When creating a level, you just CreateFromObject("level1"), and it'll spawn your entire level into life.
Of course, after this you'll probably need to iterate the Objects to setUserData if you're using that.
If I were starting a new game today, I'd use Scroll's map loading functions. I've never used this, actually. It may be the subject of my next Scroll tutorial once I finally try it out.
If you mean parent in the frame hierarchy sense, no there's no linked deletion.
However deleting an object that owns other objects (think orxObject_SetOwner and ChildList property) will trigger their deletion as well.
However, you should probably consider the lvl files as separate files, so that'll only work to make a list of levels outside of the program's code. I wouldn't do something akin to:
that's bound to weird results
(Note: That was pseudo code, plz have a look at that ini file for the real code.