User Tag List

Results 1 to 5 of 5

Thread: Decimal places?

  1. #1
    Clicker Fusion 2.5 DeveloperiOS Export Module
    ChrisBurrows's Avatar
    Join Date
    May 2011
    Location
    Tasmania, Australia
    Posts
    622
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)

    Decimal places?


    I am doing a calculation inside an expression and converting the result to a string and I'm not exactly sure how but my answer is to 12 decimal places.
    When I perform the equation 1 / 3.0 which MMF will normally return as 0.333333, I get 0.333333343267.

    I am running the equation in a loop and calling on the LoopIndex plus using 2 different extensions to get my final answer so I'm guessing somewhere along the way of doing all this, I'm getting an extra 6 decimal places.

    Can I limit the decimal places from inside the expression?

  2. #2
    Clicker Fusion 2.5 MacFusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export ModuleXNA Export ModuleUnicode Add-on
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Fusion 2.5+ DLC (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)Firefly 3D Module (Steam)
    Phi's Avatar
    Join Date
    Jan 2010
    Location
    England
    Posts
    1,964
    Mentioned
    25 Post(s)
    Tagged
    0 Thread(s)

    Re: Decimal places?

    Try FloatToString$() instead of Str$(). It's in the Special/General object.

  3. #3
    Clicker Fusion 2.5 DeveloperiOS Export Module
    ChrisBurrows's Avatar
    Join Date
    May 2011
    Location
    Tasmania, Australia
    Posts
    622
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)

    Re: Decimal places?

    What exactly does FloatToString$() do? I can't seem to tell from Str$()

  4. #4
    Clicker Fusion 2.5 MacFusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleSWF Export ModuleXNA Export ModuleUnicode Add-on
    Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Fusion 2.5+ DLC (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)iOS Export Module (Steam)Universal Windows Platform Export Module (Steam)Firefly 3D Module (Steam)
    Phi's Avatar
    Join Date
    Jan 2010
    Location
    England
    Posts
    1,964
    Mentioned
    25 Post(s)
    Tagged
    0 Thread(s)

    Re: Decimal places?

    MMF2 Help File should explain it. Press F1 and search for FloatToString.

  5. #5
    Clicker Multimedia Fusion 2Android Export ModuleiOS Export ModuleSWF Export Module

    Join Date
    Jun 2011
    Posts
    35
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Decimal places?

    Damn...

    It's not included in my Help File (German)...

Similar Threads

  1. How to use copys of an active in different places
    By Brooks2000 in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 9th July 2011, 06:52 PM
  2. Where has the extension DL places gone?
    By Tiny in forum Extension Development
    Replies: 4
    Last Post: 29th June 2011, 05:10 PM
  3. Setting decimal places on a counter
    By maestro1 in forum Multimedia Fusion 2 - Technical Support
    Replies: 2
    Last Post: 14th April 2008, 06:13 AM
  4. Problems With Significant Digits / Decimal Places
    By drnebula in forum Multimedia Fusion 2 - Technical Support
    Replies: 10
    Last Post: 2nd January 2008, 09:25 AM
  5. Decimal Places
    By SharpS in forum Multimedia Fusion 2 - Technical Support
    Replies: 4
    Last Post: 18th December 2007, 01:06 AM

Posting Permissions

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