Porting MMF2 Games to Flash with External Files?

Noyb's picture

So... I want to use the MMF2 Flash exporter to port Zambonis to Flash.

I originally structured the conversation engine to play external .ogg files in a convoluted way that basically generates at runtime the filename of the sound file to play for the current line of dialogue.

Is there an quick way to refactor this subsystem for the Flash exporter without, say, adding every line of dialogue into the game manually and creating a separate event for each sound?

(And for another game, it looks like there's little chance of Cellosoft's Text Blitter extension being Flash-compatible in the future, so without upgrading to Pro I'd need to fake it with active objects?)

Noyb's picture

Bumping this since I

Bumping this since I released the full version of Zambonis, but still have no idea if the way I structured the game's code/assets prevents me from using the MMF2 Flash Exporter to make it easily playable outside of Windows.

Quick details:

  • made the game in Multimedia Fusion 2
  • ~300 .ogg files for dialogue, each named [number].ogg and stored externally in a separate folder
  • conversation engine uses internal list objects per conversation, each line preceded with a tag referencing a filename (e.g. @0001Hello World.)
  • is there any way to restructure this for the flash exporter without manually importing and making an event for each sound?

Danni's picture

When I think of

When I think of cross-platform, I don't typically think of Flash... Have you tried the Anaconda runtime?

Noyb's picture

Oh, that's what Nifflas used

Oh, that's what Nifflas used to port Knytt Underground? Good call. I only mentioned flash since it was the only other exporter I had access to and it was relatively painless to port other games.

Spent a half hour on an Anaconda PC runtime. Seems like there's a lot of major consistency issues with the speed of built-in ball/path movements, active object animation speeds, and the 1 frame = 1/50 seconds = rate of Always events assumption, which mucks up a lot of my game's timing. Worse, it introduced some major game-breaking bugs (characters not showing up, certain movements not triggering/changing properly) that I haven't spent much time looking into, but look nasty to debug without access to the normal MMF2 debugging tools. Always the chance there are bugs in Anaconda itself, which might be difficult since it doesn't seem to be maintained/updated anymore. Might give it another shot later.

Is there a list of any Anaconda gotchas somewhere?

I also see there's an official mac runtime eventually coming with Clickteam Fusion 2.5, but it's too early to tell if that would be a cleaner job.

It actually looks like it's solid? (went back and added ?)

and one button click convert to flash, see. I don't see any issues. There's still an unresolved issue with q&a objects but they at least somewhat work in flash now.

I've never physically tried an swf with external sound files but presume it's gonna want them to be mp3 first off.

I actually used to chill in the clickconverse chat when it was still part of an irc bridge, but I don't know if that is apparent or not.

I'm not backspacing all that but I presume you made some sort of string that plays the external files in a certain order. I didn't know there was a practical reason for your files to be external, I just assumed you wanted to show off some of your wares and showcase some external files so we can see what is in the filesize, like "hey, why are you x amount of megs? i wanna reason."

I'm not sure exactly if/how the default exporter works that theoretically does html5 or if that came out. If I had the extra time to watch Johnny Mnemonic and listen to the right musicians and get into that 90s cyberpunk frame of mind I might have some better answers, but channeling all that can be tough.

Your game will end up being around 23-24 megs flash, which I don't know is convenient for flash or not. I know NG requires it be under 20 megs, but it recently started taking unity/html5 and the meg limit's around 70-100. Sounds fishy to me, but if I go into it that will turn into a "viv is not making any sense" rant which I try to dodge.

I actually started a review of it and it didn't send because I've always got 28 tabs open and multitask till my browser crashes and i lose (or loose depending on your circle) what i wrote, but remind me and I'll post my insights if there were any again. Or who knows, I might give it a writeup right after this.. l'm glad you bumped it so I can post this so/so reply that sort of exists.

Noyb's picture

Yeah, the game's large

Yeah, the game's large enough that I'm not sure it makes sense to host it online as a Flash (without maybe first lowering the quality of the audio), but offering the option of downloading a multiplatform build would be nice. Good point about the Clickteam Fusion 2.5 build options, will have to research that further.

The issue is that "Play Sample File on a Specific Channel" seems to be grayed out when targeting Flash, which I think means there isn't a way to simply choose sounds without having a separate event for each sample. It wouldn't be hard, just a lot of tedious "if counter = [number] play sample [number].ogg" that would take a while, might be prone to mistakes and that I'd rather avoid if there's a better way.

AttachmentSize
playsamplefile.png5.46 KB
pensive-mosquitoes