Hi!
While working on my own custom platform movement engine i discover a problem. I use thin obstacle backgrounds to determine where you can stand and if you are not standing on one of these you fall, consequently. however, when i make another backdrop and places it in front of my obstacle backdrop the obstacle backdrop is no longer recognized and I always fall thru it. (damn, donŽt know how to spell it, through maybe?)Well, anyone know what the problem is?
Kind of had a hard time understanding, but from the sounds of your problem heres my little tip.
If you put a backdrop isnt set as an obsticle over a backdrop that is set as an obsticle, you will be able to go through the backdrop set obsticle as long as your over the piece of the object that isnt. Its almost like it creates a hole, not sure if its an actial bug in MMF, but if its something you dont want, then its something you want to watch out for. I have a perfect example of this in my distructable terrain example in my tutorial pack, if you want to check it out.
It's not really a bug in MMF, more of a convenience really. It can be used to your advantage. If you want a non-backdrop object over the top of it your best bet is to create two copies of the non-obstacle backdrop. The normal one, and one which is only the parts of it which will cover the obstacle. The latter one would then be made into an obstacle and placed over the top and the players are none the wiser.
Well its annoying when we dont want it there, but useful when we do want it there. Thats the best way to explain it. I think the best use for it though, is basicly a worms style game where you destroy terrain, that way its easy to simply create blasted craters that you are able to walk in to.
Well, it's very useful for situations such as winding corridors surrounded by darkness; rather than using a bunch of black obstacle tiles as well as the corridor tiles you can simply make a large black obstacle quick backdrop and place non-obstacle corridor tiles over the top. Since I always use a tile system for backgrounds (which generally looks best anyway) it's never, ever a problem.
Dave Matthew: You've got two options. Either create obstacles that look like the area overlapped by the non-obstacle backdrop (for example, where a thing obtacle overlaps a tree trunk, create a thin slice of tree trunk as an obstacle and place it over the position where the trunk overlaps the obstacle backdrop), or use active ojects for overlaps since the backdrops will still be detected behind them. If you've got a large number of these overlapping objects that might be fastest, although it's somewhat less efficient.
I would go with Radix' first option, because it also allows you to determine the heigh of the actual collision, thus allowing you to also create a semi 3D effect.
The part outlined in red is just a duplicated version of the backdrop below it.
You dont even neccesarily have to take all of the lower part, stopping at the dotted line will do aswell , but I think you figured it all out by now hehe
I was thinking about doing as radix said, but to me it seemed like "shooting ducks with big guns". Anyway, I guess this is the way IŽll have to do it. Thank you.