User Tag List

Results 1 to 5 of 5

Thread: Speed calculation

  1. #1
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleSWF Export ModuleUnicode Add-on
    Boba Fonts's Avatar
    Join Date
    Jan 2009
    Location
    Northern Italy
    Posts
    228
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Speed calculation

    I wonder if I can convert the pixel-based movement of an active object into a numeric value valid for the MMF built-in movements speeds.

    My character is a static active moved by a custom event editor series of events; he moves by a certain amount of pixels every 8 milliseconds to simulate realistic footsteps and avoid a gliding effect. That amount of pixels depends on a scale value, since there's perspective in the game. So he doesn't move by the same amount of pixels in every area of the screen: very few pixels if he's small on top of the screen, near the horizon, and many pixels if he's big, on the bottom of the screen, in a close-up.

    I need to measure the "MMF speed" of that pixel-moving character in order to have a bouncing ball thing that moves at the same speed (as precisely as possible) with its built-in bouncing ball movement.

    Anyone can help me?
    Thanks

  2. #2
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleSWF Export ModuleUnicode Add-on
    Looki's Avatar
    Join Date
    Aug 2006
    Location
    Karlsruhe, Germany
    Posts
    3,741
    Mentioned
    5 Post(s)
    Tagged
    1 Thread(s)

    Re: Speed calculation

    After about 1 minute of testing, I figured out that the conversion factor is exactly 0.125.

    Speed 60 = 60*0.125 = 7.5 pixels per frame

    I'll add a FusionWiki entry for that so you and others can always look it up.

  3. #3
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleSWF Export ModuleUnicode Add-on
    Boba Fonts's Avatar
    Join Date
    Jan 2009
    Location
    Northern Italy
    Posts
    228
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Re: Speed calculation

    Thank you Looki!

    When you say 7.5 pixels per frame you mean the frames the game is rendered in runtime? FPS?

    So, now that I know the conversion factor from *pixels per frame* to *MMF speed*, how exactly can I measure the pixels per frame of my character who moves differently based on scale and perspective?

  4. #4
    Clicker Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleSWF Export ModuleUnicode Add-on
    Looki's Avatar
    Join Date
    Aug 2006
    Location
    Karlsruhe, Germany
    Posts
    3,741
    Mentioned
    5 Post(s)
    Tagged
    1 Thread(s)

    Re: Speed calculation

    I'm not sure what you mean to be honest.

    Are you working with the timer conditions? Every 00'00'08... (By the way, 0.08 seconds are 80 milliseconds, not 8)

    You should not use these for movements in the first place.
    Rather, make a counter, or a variable, and count it up. When it has reached a certain value set it back to 0 and do something.

  5. #5
    Clickteam Clickteam
    LB's Avatar
    Join Date
    Jun 2007
    Location
    Richardson, Texas, North America
    Posts
    8,937
    Mentioned
    4 Post(s)
    Tagged
    0 Thread(s)

    Re: Speed calculation

    Looki I think he means he has a sort of 3D thing with Scaling actives and such.
    Working as fast as I can on Fusion 3

Similar Threads

  1. calculation help
    By aylictal in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 21st May 2013, 02:45 PM
  2. Max() calculation error
    By DavidN in forum XNA Export Module Version 2.0
    Replies: 7
    Last Post: 11th October 2012, 07:12 AM
  3. Angle Calculation
    By lincore in forum Multimedia Fusion 2 - Technical Support
    Replies: 4
    Last Post: 17th October 2008, 12:53 PM
  4. HWA for intensive calculation on GPU
    By felinex in forum Hardware Accelerated Runtime
    Replies: 1
    Last Post: 13th January 2008, 03:48 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
  •