I know I shouldn't be asking because its probably simple. How do you load tiles in MMF2? I know you can use text blitter 1.5 to use tiles or use the 'snapshot n' save' method although is there a faster and easier way? If I were to use text blitter then how would I command collisions and such?
I believe Active Picture object can do blitting and stuff as well, since they fixed the Add Backdrop action in MMF2. How is collision detection a problem, if you're using Text Blitter?
I just tried it. In a 512x512 frame, I laid out a level using a simple Text Blitter with an AB charset. A is a 32x32 square, and B is completely blank/transparent. I stuck a platform active in there and added the condition "Active collides with Text Blitter -> Stop Active." I stuck the active in the blank area, and when I started up, the Active was nowhere to be seen. I turned off the event, tried again, and then saw the Active fall through the screen like I expected. I didn't see any "Add Backdrop" option for Text Blitter, either.
If wishes were fishes then we'd all smell like ladies' underwear.
see thats what I mean. I tried it before with no luck so I didn't think text blitter was the answer. BTW I never got a chance to use overlay untill now because MMF1 would crash every time I tried to use it and I even reinstalled it with no prevail.
Reborn Again
DaVince This fool just HAD to have a custom rating
Try Active Picture then. It's got working collision detection, and it can blit a specific part of a picture onto the frame (which means you could have an entire tileset in one bitmap, and then just set the X and Y offset depending on the tile you want to blit). What else do you need?
"BTW Axel would this method of blitting tiles with active picture be effective and efficiant?"
Compared to what? If there's only one candidate, then there's only one choice. Yes, it should be pretty efficient. All you you have to do to load an entire level, is you run a fastloop, blit the tiles as backdrop objects (on obstacle mode), and you're done.
Or, you could ask Fifth if he knows some better way to do it.
No, there's no fine collision detection for the Text Blitter. I think that's what makes it run so fast (relatively).
So instead, you have to make your collisions relative to the level file itself, if that makes any sense. You can allocate a few values for your objects to test what kind of tile is above, below, and to either side, and use those to do appropriate collision detection.
Hmm, maybe an article would be a better means to explain it...
"paste into background kills the background when you move away"
But Add Backdrop doesn't?
"instead, you have to make your collisions relative to the level file itself, if that makes any sense. You can allocate a few values for your objects to test what kind of tile is above, below, and to either side, and use those to do appropriate collision detection."
Yes, that sounds about right. I've done it in another game I made in C++ some time ago, so it should be pretty much the same in MMF.
Yes, if you simply use Text Blitter for display ONLY, and have collision/movement done by just checking/adjusting values on a matrix, its the most efficient way.