User Tag List

Results 1 to 10 of 10

Thread: Completely Stuck With INI Object in Flash

  1. #1
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleSWF Export Module
    redpandagames's Avatar
    Join Date
    Dec 2011
    Posts
    378
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Completely Stuck With INI Object in Flash

    I read through all of the INI posts, but it seems to continue to elude people including myself despite all documentation. When I figure out how to do this, I will write a tutorial.

    I read through all of the INI tutorials and I can get everything to work, but once I build the Flash application, I can't read data from ini as a string because of the path, I'm sure. This is because when I try to load the string, it returns noting and deletes the current string.

    I know what everyone will say. "Check the box and put the file in the application folder."

    This won't work for me because I am not actually writing to the INI. I'm just reading from it. This is because I am using it for dialogue and the whole ini is already written.

    The question is:

    1) Where do I put the ini file so that it is bundled with the application and not created when started? Also, how do I reference the path from which to pull the string because the apppath thing doesn't work for Flash.
    2) Will I need to write all of the dialogue to the ini before being able to read it for Flash? If so, how would I go about doing that for 12000 words in an ini file. I don't want to create an entry for every item.

    I am sure that other people have run into this. I can successfully read data that I have written to the ini when in the application folder is checked and not specifying a path, but I don't think I need to write all of the data to the ini first if it is already created. What am I missing?

    Just to be clear, the ini isn't working for Flash, but works fine during testing.

  2. #2
    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)
    You should put the ini file in the binary data of the application (button in the toolbar).
    I confirm to you : only the name.ini is taken into consideration when loading/creating an INI file in Flash.

  3. #3
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleSWF Export Module
    redpandagames's Avatar
    Join Date
    Dec 2011
    Posts
    378
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Francois View Post
    You should put the ini file in the binary data of the application (button in the toolbar).
    I confirm to you : only the name.ini is taken into consideration when loading/creating an INI file in Flash.
    I don't understand where the "binary data of the application" button is. There are a lot of toolbars, so it is in the application, properties, or workspace toolbar, or is it in the file toolbar? I can't find it in any of those.

    As for the actual name.ini... I should put that in the folder with the name.mfa, right? I just don't see how the build pulls in a prewritten ini file that you can read from.

  4. #4
    Clickteam Clickteam
    Danny's Avatar
    Join Date
    Aug 2007
    Location
    United Kingdom
    Posts
    3,016
    Mentioned
    21 Post(s)
    Tagged
    2 Thread(s)
    Data Elements.

    Put the initial INI file in the same directory as the MFA, then use Data Elements > Binary to add the INI file. You can then call it with AppPath$+"nameofini.ini"
    Want to learn Clickteam Fusion 2.5?




  5. #5
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleSWF Export Module
    redpandagames's Avatar
    Join Date
    Dec 2011
    Posts
    378
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by Danny View Post
    Data Elements.

    Put the initial INI file in the same directory as the MFA, then use Data Elements > Binary to add the INI file. You can then call it with AppPath$+"nameofini.ini"
    Okay, I got it. Thanks!

  6. #6
    Clickteam Clickteam
    Danny's Avatar
    Join Date
    Aug 2007
    Location
    United Kingdom
    Posts
    3,016
    Mentioned
    21 Post(s)
    Tagged
    2 Thread(s)
    No problem, let me know if you run into any trouble along the way!
    Want to learn Clickteam Fusion 2.5?




  7. #7
    Clicker Multimedia Fusion 2 DeveloperiOS 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)
    King_Cool's Avatar
    Join Date
    Aug 2008
    Posts
    2,335
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Im having problems with this as well.
    This is what i did:

    - Im using the Hiscores Object
    - Generated a default ini file using the Hiscores Object
    - Edited the ini and changed the Names and Scores
    - Copied the ini to the Application folder
    - Included the ini ( in the Appliction folder ) in Data Elements ( Binary Data )

    The Hiscore Object does have the same filename ( with extencion ) property as the ini file in the Application folder has.
    Still when i run the App as Flash, the Hiscore Object does not load the ini and only displays "EMPTY, EMPTY, EMPTY... 0, 0, 0..."

    Never though hicores would be this troubblesome.
    What am i doing wrong?

    EDIT:
    Ive been told that i only need to specify the INis file name and extencion ( example: "hiscores.ini" ) for MMF2 Flash to be able to read and use them.
    Is this still true?

  8. #8
    Forum Moderator

    Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleUniversal Windows Platform Export ModuleSWF Export ModuleXNA Export ModuleInstall Creator Pro
    nivram's Avatar
    Join Date
    Jul 2006
    Location
    Bandon, Oregon
    Posts
    6,773
    Mentioned
    12 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by King_Cool View Post
    EDIT:
    Ive been told that i only need to specify the INis file name and extencion ( example: "hiscores.ini" ) for MMF2 Flash to be able to read and use them.
    Is this still true?
    The last time I read and heard, yes, it is still true.

    Marv
    ​458 TGF to CTF 2.5+ Examples and games
    http://www.castles-of-britain.com/mmf2examples.htm

  9. #9
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleSWF Export Module
    redpandagames's Avatar
    Join Date
    Dec 2011
    Posts
    378
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Is there any specific reason why you're using the Hiscore Object? I would probably make my own chart because it would probably be easier. Did you make sure to add everything to the binary elements as stated above?

  10. #10
    Clicker Multimedia Fusion 2 DeveloperiOS 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)
    King_Cool's Avatar
    Join Date
    Aug 2008
    Posts
    2,335
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by redpandagames View Post
    Is there any specific reason why you're using the Hiscore Object? I would probably make my own chart because it would probably be easier. Did you make sure to add everything to the binary elements as stated above?
    The Highscore Object was just a temporary solution untill i got the Flash Array working.
    The Hiscore Object seems to work in Flash now, i was probably doing something wrong before.

Similar Threads

  1. How to make your Flash games play sounds AND why the game looks completely different
    By YeOldeLuke in forum Multimedia Fusion 2 - Technical Support
    Replies: 11
    Last Post: 3rd June 2013, 10:01 PM
  2. object not completely destroyed?
    By pikzilla in forum Multimedia Fusion 2 - Technical Support
    Replies: 8
    Last Post: 30th June 2010, 04:23 PM
  3. Object gets stuck in wall
    By Winston in forum Multimedia Fusion 2 - Technical Support
    Replies: 2
    Last Post: 15th September 2009, 09:55 PM
  4. How can I completely delete the object.
    By ASD in forum Multimedia Fusion 2 - Technical Support
    Replies: 27
    Last Post: 4th May 2009, 03:52 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
  •