User Tag List

Results 1 to 5 of 5

Thread: Array Save/ Load problems

  1. #1
    No Products Registered

    Join Date
    May 2007
    Posts
    13
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Array Save/ Load problems

    Well I just bought MMF2 waiting for it to be delivered I am playing with the demo. I am trying to port one of my trading sim games into MMF2.
    For testing I have a 3x3 array. Every 5 seconds I put random values into the various positions.
    Now I have an action to save array when the space bar is pressed. Then one to load the array when L is pressed. But the numbers it is comming up with are different than the ones when I saved it.
    Sometimes I have to press L 2 times and get 2 different sets of numbers. (this is before new values are picked)
    I have messed with the clear array option but apparently have not hit it on the head yet. Not quite sure if I actually have to clear it...

    How do I get my array to save and load properly ? Is there something I am missing such as not clearing at the right time or perhaps something else ?
    Thanks in advance.
    RageO



  2. #2
    Forum Moderator Fusion 2.5 DeveloperHTML5 Export ModuleiOS Export ModuleSWF Export Module
    DavidN's Avatar
    Join Date
    Jun 2006
    Location
    Boston, MA, USA
    Posts
    4,044
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Array Save/ Load problems

    Sounds strange - I don't remember anything like this happening to anyone else. It might be easiest if you upload a small example demonstrating the problem to the File Archive forum.

    (You've made sure that the on-screen array isn't being overwritten by your random values once it's loaded?)

  3. #3
    No Products Registered

    Join Date
    May 2007
    Posts
    13
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Array Save/ Load problems

    Here is the test file. You will have to change the path to the array on the spacebar and L action.

    http://www.sendmefile.com/00537058

    It should save when I hit space then Load when I hit L then it carries on picking values but its not working properly.

    Just to clarify. I have it picking random numbers every 5 seconds(This is so I can uptate on time intervals) I save at a point in between these picks. Then load in between this period but when I load the numbers do not reflect the ones present when I saved.
    Hope that helps.

    Thanks for looking.

  4. #4
    Forum Moderator Fusion 2.5 DeveloperHTML5 Export ModuleiOS Export ModuleSWF Export Module
    DavidN's Avatar
    Join Date
    Jun 2006
    Location
    Boston, MA, USA
    Posts
    4,044
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Array Save/ Load problems

    Your loading actions are in the wrong order - if you go into the Action editor (double click on the event row) or Event List, you'll see that you're setting all the counter values before the array is actually loaded. Drag that "Load array from file" action to the top of the list of actions, and everything should work.

    Incidentally, you can use expressions such as "./array" (for the curent folder) or 'AppDrive$ + AppDir$ + "array"' (for the folder in which the application file resides) expressions instead of hard-coded paths for files - this avoids the problem of the application looking in a specific folder.

  5. #5
    No Products Registered

    Join Date
    May 2007
    Posts
    13
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Array Save/ Load problems

    I got it thanks! At first it still did not quite work but I was setting the counters then picking a random number for the array which was causing the strange results. But I got the order right now.
    Thanks for putting me on track!

Similar Threads

  1. LOAD/SAVE clone file in ARRAY FILE
    By daniele in forum Multimedia Fusion 2 - Technical Support
    Replies: 20
    Last Post: 24th July 2015, 01:47 AM
  2. Beta RC3- [BUG] Save & Load ini file to Array not functioning
    By Kisguri in forum Android Export Module Version 2.0
    Replies: 3
    Last Post: 16th January 2013, 08:44 PM
  3. Save/Load external Array
    By Fanotherpg in forum SWF/Flash Export Module Version 2.0
    Replies: 7
    Last Post: 6th May 2012, 11:31 AM
  4. Array/Table save and load in LUA
    By zellix in forum Lua Scripting
    Replies: 12
    Last Post: 11th February 2010, 02:19 PM
  5. Binary Array Save/Load File gets it Wrong
    By dragonguy in forum Multimedia Fusion 2 - Technical Support
    Replies: 24
    Last Post: 6th November 2008, 11:11 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •