User Tag List

Page 1 of 2 1 2 LastLast
Results 1 to 10 of 11

Thread: INI problem

  1. #1
    Clicker Fusion 2.5 DeveloperiOS Export Module
    Czentnar's Avatar
    Join Date
    Jan 2007
    Location
    Budapest, Hungary
    Posts
    819
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    INI problem

    I've got a problem with the INI object (it works in Java quite well, anyway):
    Once an ini file is loaded, it won't be refreshed in the next time.

    For example:
    - Start of frame:
    Set INI file -> apppath$+"file.ini" //this file contains an item
    - Always:
    Set global value A to -> get INI item value

    Now, if you change the item of the INI file during runtime, the global value will also be changed in the MMF2 editor. But it won't be changed in Java. You have to restart the frame or the application to have the effect.

  2. #2
    Clicker Multimedia Fusion 2 DeveloperSWF Export Module
    RickyRombo's Avatar
    Join Date
    Mar 2008
    Location
    Somewhere between here and there
    Posts
    3,167
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: INI problem

    Hm... I don't know if I'm right about this, but it seems to me that you would have to reload the INI because the INI is loaded in the cache at start of frame (I think)

    Something like that.

    I'm probably wrong but try reloading the file after changing it at runtime :S

  3. #3
    Clicker Multimedia Fusion 2 DeveloperSWF Export Module

    Join Date
    Jun 2006
    Posts
    6,773
    Mentioned
    1 Post(s)
    Tagged
    0 Thread(s)

    Re: INI problem

    It's probably better behaviour if the INI values are cached - parsing the INI file again and again every time you read a value is pretty nasty.

  4. #4
    Clicker Fusion 2.5 DeveloperiOS Export Module
    Czentnar's Avatar
    Join Date
    Jan 2007
    Location
    Budapest, Hungary
    Posts
    819
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: INI problem

    Thanks RickyRombo and Jamie for your reply!
    I will try to make an example because it isn't as simple as I explained.

    There's one INI file and a frame with a Sub-Application in it.
    The frame contains a String that is always changed to the item of the INI file.
    The Sub-Application modifies the INI file - for example on key pressing.
    (So there's an INI object in the parent frame and in the Sub-Application's frame as well).

    When the Sub-Application changes the INI file, the parent frame should pass the changed value to the String. This will work in MMF2 but not in Java.

    Thanks,

  5. #5
    Clicker Multimedia Fusion 2 DeveloperiOS Export ModuleSWF Export Module
    Francois's Avatar
    Join Date
    Jul 2006
    Location
    Montpellier, France
    Posts
    6,920
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)

    Re: INI problem

    Yes, the INI is cached in Java. I cannot save a load the ini file each time you change something, this would waste a lot of processing time. The INI is saved after 10 seconds of inactivity after the last change. But it is never reloaded if you change it externally.
    Putting a new action just for Java would not be really good.

  6. #6
    Clicker Fusion 2.5 DeveloperiOS Export Module
    Czentnar's Avatar
    Join Date
    Jan 2007
    Location
    Budapest, Hungary
    Posts
    819
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: INI problem

    That's good to know. I think I can solve the problem somehow, it isn't a big problem.
    Thanks!

  7. #7
    Clicker Multimedia Fusion 2 DeveloperSWF Export Module
    RickyRombo's Avatar
    Join Date
    Mar 2008
    Location
    Somewhere between here and there
    Posts
    3,167
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: INI problem

    :shocked:

    For once I was right!! First time for everything...

  8. #8
    Clicker Fusion 2.5 DeveloperiOS Export Module
    Czentnar's Avatar
    Join Date
    Jan 2007
    Location
    Budapest, Hungary
    Posts
    819
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: INI problem

    Quote Originally Posted by Francois
    Yes, the INI is cached in Java. I cannot save a load the ini file each time you change something, this would waste a lot of processing time. The INI is saved after 10 seconds of inactivity after the last change. But it is never reloaded if you change it externally.
    Putting a new action just for Java would not be really good.
    Back to this topic for a question:
    Does the "Named Variable Object" behave in the same way? Or is it more flexible?
    I haven't experienced with it yet, but if it caches the data during runtime and it can write and read external files as frequently as the user wants, then I will use it.
    Thanks!

  9. #9
    Clicker Multimedia Fusion 2 DeveloperiOS Export ModuleSWF Export Module
    Francois's Avatar
    Join Date
    Jul 2006
    Location
    Montpellier, France
    Posts
    6,920
    Mentioned
    1 Post(s)
    Tagged
    1 Thread(s)

    Re: INI problem

    I would guess so. But I cant look at the source code today.

  10. #10
    Clickteam Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleUniversal Windows Platform Export ModuleSWF Export Module
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)
    Simon's Avatar
    Join Date
    Jun 2006
    Location
    UK
    Posts
    2,735
    Mentioned
    65 Post(s)
    Tagged
    3 Thread(s)

    Re: INI problem

    Francois is there any potential problem with writing to the INI file just before ending the application on a java mobile platform? Will this result in data not being saved due to the 10 second inactivity counter not being triggered as the application may have already closed?

Page 1 of 2 1 2 LastLast

Similar Threads

  1. Pulling Problem and Shooting Problem
    By Duggabboo in forum Multimedia Fusion 2 - Technical Support
    Replies: 2
    Last Post: 21st March 2010, 05:24 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
  •