User Tag List

Results 1 to 5 of 5

Thread: My global values are rounding in strange ways

  1. #1
    Clicker Fusion 2.5 (Steam)

    Join Date
    Aug 2011
    Posts
    9
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    My global values are rounding in strange ways

    Hey, I've been using MMF for several years off and on, I haven't used it in a few months so I'm a little rusty but I shouldn't be this rusty. I was working on an app when I hit a snag and couldn't figure it out so I created a completely new app to see if it was an issue with part of my code. This new blank app has only the following properties

    GV a = 3.5
    GV b = 0
    GV c = 0

    Always --> set GV b to (GV a)/2
    Always --> set GV c to sqrt(GV a)

    Before I even run the frame, GV a does some kind of auto round and sets itself to 3. With the frame running, I check the global values and GV a is 3, GV b is 1, and GV c is 1.732.

    My question is, why are my global values rounding like this? Is this just something I've never noticed before?

    I'm confused why GV a is jumping to 3 before a frame even begins, why both A and B are rounding down at *.5, and why one formula yields me a proper value (GV c) and the other does the weird rounding scenario. Any help is appreciated. I know this is probably a simple fix but I'm about to start losing hair over it.

  2. #2
    Forum Moderator Fusion 2.5 DeveloperAndroid Export ModuleHTML5 Export ModuleSWF Export ModuleXNA Export Module
    ProdigyX's Avatar
    Join Date
    Jan 2011
    Posts
    1,197
    Mentioned
    2 Post(s)
    Tagged
    0 Thread(s)
    Global Values may only be integer values during edittime. If you set one to something like "3.5414" it will round to 3 after the respective edit box loses focus.

  3. #3
    Clicker Fusion 2.5 (Steam)

    Join Date
    Aug 2011
    Posts
    9
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Thanks for the reply, I figured that might be the case, which explains GV a resets to 3, but why can't I get division to work properly? I've tried several other equations just out of curiosity with the Always --> set GV b to (GV a)/2 scenario and it always rounds.

    For example I tried setting GV a to 7 (during edit time) and creating the only event to be always --> set GV b to (GV a)/3 and it yields 2 instead of 2.33 while running. I'm worried I'm going to have to create large numeric work arounds to balance gameplay if I can't use decimals at all.

  4. #4

  5. #5
    Clicker Fusion 2.5 (Steam)

    Join Date
    Aug 2011
    Posts
    9
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Awesome, thanks for you help.

Similar Threads

  1. Global Values & Alterable Values with same names
    By Gustav in forum Multimedia Fusion 2 - Technical Support
    Replies: 8
    Last Post: 7th November 2012, 07:15 PM
  2. Expression returns some strange values...
    By Hawanna in forum Multimedia Fusion 2 - Technical Support
    Replies: 14
    Last Post: 24th October 2011, 03:23 PM
  3. Rounding Values up or down
    By Mantoid in forum Multimedia Fusion 2 - Technical Support
    Replies: 1
    Last Post: 18th June 2008, 08:11 PM
  4. Negative values in a List, and Global Values
    By aidmm in forum Multimedia Fusion 2 - Technical Support
    Replies: 4
    Last Post: 20th January 2007, 07:08 AM

Tags for this Thread

Posting Permissions

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