User Tag List

Results 1 to 4 of 4

Thread: Mouse movement sound off opportunity and work arounds

  1. #1
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleiOS Export Module
    rubes's Avatar
    Join Date
    May 2011
    Posts
    367
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Mouse movement sound off opportunity and work arounds

    I've read many times Here that we shouldn't use the mouse movement, but I'm curious as to why this is. In pong games, for example, it can cause vertical movement, but isn't this rectified with an always set y to a value? The reason I'm intrigued by it is simplicity and quick response. If I were to code the arrow keys to move the paddle, I don't know how I would replicate the panic move equivalent of spinning the dial in pong to travel very fast to one side of the screen. On the flip side, is there a way to use mouse movent while causing the object being controlled to experience a slow down in response

  2. #2
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleiOS 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)Universal Windows Platform Export Module (Steam)
    Popcorn's Avatar
    Join Date
    Jun 2006
    Location
    Norway, Bergen
    Posts
    2,366
    Mentioned
    13 Post(s)
    Tagged
    0 Thread(s)
    When you use the mouse movement, mmf deactivates the mouse conditions in the event editor, and the the mouse acts like a joystick instead, where LMB = Firebutton 1 and RMB = Firebutton 2. Most people like to keep beeing able to use the mouse condition in the event editor, and therefore code their own mousemovement, which practically works exactly the same as the built-in mousemovent, only this way they are able to use the mouse conditions. You can easily code events to make an object behave exactly as it would if it had its movement set to Mouse-movement.

    * Always
    - Paddle: Set x-position to XMouse

    This simple event is enough to make a horizontal mouse-movement.

    If you don't want the paddle to go all the way to left or right, you can add events to restrict it's movement zone.

    * X-position of Paddle < 32
    - Paddle: Set X-position to 32

    * X-position of Paddle > Frame width - 32
    - Paddle: Set X-position to Frame width - 32


    This is common practise, but it is of course up to you how you want to make your game
    This method gives more control coding wise, and that's probably why most people prefer it.

  3. #3
    Clicker Fusion 2.5 DeveloperAndroid Export ModuleiOS Export Module
    rubes's Avatar
    Join Date
    May 2011
    Posts
    367
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    OK, that makes sense. I'll add that now and see what happens. This might give me an idea on the slow down effect that i want too, but im not sure yet.....

  4. #4
    Clicker Multimedia Fusion 2SWF Export Module
    Jacob's Avatar
    Join Date
    Jul 2007
    Location
    Second pixel to the right
    Posts
    3,208
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    For a fluid movement that won't leave the frame, you could probably do something like this. I haven't tried it, but if you have an object named Paddle with the hotspot horizontally centered it should work.

    Always:
    Set X Position of Paddle to max((X Right("Paddle")-X Left("Paddle"))/2,min(Frame Width+(X Left("Paddle")-X Right("Paddle"))/2,(9*X("Paddle")+xmouse)/10.0))

Similar Threads

  1. Why doesn't clicking work with the mouse movement.
    By plusallofyou in forum Multimedia Fusion 2 - Technical Support
    Replies: 11
    Last Post: 1st January 2013, 11:54 PM
  2. Mouse movement doesn't work with tablets?
    By RayMarble in forum The Games Factory 2 - Technical Support
    Replies: 5
    Last Post: 13th December 2008, 11:13 AM
  3. Mouse Movement prevents mouse click event?
    By Tuna in forum Multimedia Fusion 2 - Technical Support
    Replies: 2
    Last Post: 2nd March 2008, 02:52 AM
  4. Mouse click doesnt work when Mouse movement used
    By Blizna in forum Multimedia Fusion 2 - Technical Support
    Replies: 3
    Last Post: 21st September 2006, 02:24 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
  •