I've been trying to do something very, very simple for...*checks watch* five straight months now.
All I'm trying to do is switch from frame 1 to frame 2 and back, while keeping frame 1 the way it was before. That's it. Nothing more complicated than that.
Yet MMF has fought me to the bloody bitter end about it.
The simple solution seemed to be to use the save and load frame actions. After a few days of utterly wasted work followed by a trip to the forums to find out that the frame doesn't save until the end of the event loop but frame transitions are instant, I finally got it to save correctly. However, loading it again has proven to be nothing short of demonic for what appear to be the stupidest of reasons.
Now that I've managed to fix the crashes, the problem is that frame 1 will instantly jump back to frame 2 every single time you try to return. I'm assuming this is because MMF is forcing me to set a variable that tells it when to switch to frame 2, since the frame switch event has to actually be placed before the saving event and run on the next loop (since it doesn't save until the end of the loop, meaning if I just try to save > switch nothing will get saved). I can only assume that that variable is being loaded when the rest of the frame is being loaded, meaning it's current value gets overwritten to what it was just before it jumped and it thinks it's supposed to jump to frame 2 again. All attempts to manually overwrite it after the loading event itself have no effect.
At least, this is what happens when I try using a global variable to control the frame jumps. I have also tried using an ini file; if this is the case, the game simply won't load the frame data at all (though I have verified that all of the ini data is there and correct). I tried using the named variable object to store the variable in the hopes that the save frame action wouldn't include it. This was actually the first way I tried it, and while it worked, it also left MMF in a highly unstable state where there were massive graphical glitches and objects blinking in and out of existance. I can only assume this was specifically to spite me.
The basic event sequence is exceedingly simple:
*** Frame 1
+ Variable "Load Frame Data" = 1
- Jump to Frame 2
+ Start Of Frame
+ "Load Frame Data" = 2
- Load Frame Position
- "Load Frame Data" = 0
+ Upon Pressing "`"
+ "Load Frame Data" = 0
- "Load Frame Data" = 1
- Save Frame Position
*** Frame 2
+ Upon Pressing "`"
- Jump to Frame 1
+ End of Frame
- "Load Frame Data" = 2
...Yet it manages to fail in the most spectacular ways, depending on how I tweak it. I've even crashed MMF several times. Most of the time, though, it just persistantly ignores me by either clinging with desperate tenacity to frame 2 or plodding ignorantly along using every ounce of digital willpower it has to ignore the "load frame position" command's existance.
That is the version that uses the global variable ("Load Frame Data"). It results in being trapped in frame 2; each time you try to go back to frame 1, it goes back for a split second and then returns to frame 2. I have checked for other events that might be affecting it and there are none, and everything I do has the same result: Either it won't load or it forces frame 1 to jump back to frame 2 again the second it loads.
Surely I'm not the first user who has ever wanted to have an inventory screen or somesuch? I'm going to need several such subscreens. I could do without some of them by making workarounds or integrating them into the main screen, but there are some that just can't be fudged and the game won't function without them. I can't afford to keep putting so much development time into projects only to have stupid random things like this constantly murder them. If anybody knows what's wrong or knows of a better way, please let me know.