User Tag List

Results 1 to 2 of 2

Thread: Scaling number set ( X, Y ) to nearest 1 ( uniformly )

  1. #1
    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)

    Scaling number set ( X, Y ) to nearest 1 ( uniformly )

    Hi
    What is the easiest, most efficient method of scaling a set of numbers ( uniformly ) to the nearest 1?

    ...
    Example A
    X = 10 Y = 5

    Diesired result:
    X = 2 Y = 1
    ( scaled down )

    Example B
    X = 0.2 Y = 0.05

    Diesired result:
    X = 1 Y = 0.25
    ( scaled up )

  2. #2
    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)
    Oh man, the solution was very simple :P

    - If X > Y
    -> Set Y to Y / X
    -> Set X to X / X

    - If X > Y
    -> Set X to X / Y
    -> Set Y to Y / Y

    ...
    However, i wonder if it is possible to do this through a single expression without needing 2 seperate Events?

Similar Threads

  1. Getting Nearest Enemy
    By MangoMan in forum Multimedia Fusion 2 - Technical Support
    Replies: 19
    Last Post: 21st December 2011, 03:04 PM
  2. Nearest neighbour scaling in window mode
    By Grillchips in forum Multimedia Fusion 2 - Technical Support
    Replies: 0
    Last Post: 4th February 2010, 12:30 PM
  3. Going to object that is nearest?
    By Solgryn in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 19th July 2009, 08:24 PM
  4. "Create [x] at 0,0 from nearest [y]"
    By CASEY in forum Multimedia Fusion 2 - Technical Support
    Replies: 5
    Last Post: 25th April 2007, 08:47 PM
  5. always move towards nearest enemy?
    By falkon in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 24th July 2006, 02:02 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
  •