User Tag List

Results 1 to 7 of 7

Thread: Inputs being lost or eaten under specific conditions (.MFA included)

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

    Join Date
    Mar 2015
    Posts
    14
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Inputs being lost or eaten under specific conditions (.MFA included)

    I am having an easily replicable issue where two inputs will refer to an INDIVIDUAL AV, Counter, String, Flag, Object, etc. on the exact same frame and lose one of the inputs. If I instead reference MULTIPLE AVs, Counters, Strings, Flags, Objects, etc. on the exact same frame this issue ceases to exist.

    I would like to ask someone to try out my .mfa and explain to me why several conditions will result in a lost input, while similar conditions will not lose an input.

    The examples I have provided that DO lose an input are CRITICAL to my Input Handler for key rebinding. If I can't find an example for completely thorough key rebinding (all keys, all or most controllers), or resolve the issues I am having my game cannot ship. I will accept alternatives but if I can't fix the input loss in these specific examples I will have to dramatically increase the number of events in my game.

    Several playtesters have encountered this bug multiple times over the course of an hour, and I frequently do as well. My game is pure action.

    Please help!
    Attached files Attached files

  2. #2
    Clicker Fusion 2.5Android Export ModuleSWF Export Module
    EE's Avatar
    Join Date
    Sep 2009
    Posts
    200
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    I looked at it and it's due to the event order, take Q and W for example, if you press both at the same time "Fire" will always be set to 2 since W comes after the Q event(remember, CF reads events from top to bottom).
    You literally tell the program;
    *Upon Q - Set Fire to 1 (Fire = 1)
    *Upon W - Set Fire to 2 (Fire = 2)
    *If Fire = 1 - Shoot Left (won't happen since Fire = 2)
    *If Fire = 2 - Shoot Right (will happen instead)

    You can see for yourself by moving the shoot events so they are directly after the button events ie;
    *Upon Q - Fire = 1
    *If Fire = 1 - Shoot Left
    *Upon W - Fire = 2
    *If Fire = 2 - Shoot Right

    Then it works. But that's a messy fix, instead you could change it so that a button triggers a loop and apply the on loop condition to the shooting event.
    //EE

  3. #3
    Clicker 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)

    Join Date
    Mar 2015
    Posts
    14
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I appreciate the help! Could you show how you would:

    Quote Originally Posted by EE View Post
    change it so that a button triggers a loop and apply the on loop condition to the shooting event.
    and possibly within the example I made, just so I don't end up doing the messy solution for lack of understanding?

    I may have a tangled web of code that wasn't built with a full understanding of the order it was made.

  4. #4
    Clicker Fusion 2.5Android Export ModuleSWF Export Module
    EE's Avatar
    Join Date
    Sep 2009
    Posts
    200
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    Hey!
    Sorry for not replying, I've been on vacation for the summer.
    I hope you managed to solve your problem, otherwise just tell me!
    //EE

  5. #5
    Clicker 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)

    Join Date
    Mar 2015
    Posts
    14
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    I have not yet come up with a solution given the system I have in place. I am currently looking into replacing the key/controller rebinding entirely. I have not found an example of a way to rebind every key on a keyboard or any button an a controller so I attempted to make one myself. Since making it myself didn't work yet, I would be really interested in finding an example that was already created to learn from or re-engineer for my game. Any help is appreciated!

  6. #6
    Clicker 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)

    Join Date
    Mar 2015
    Posts
    14
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Quote Originally Posted by EE View Post
    Hey!
    Sorry for not replying, I've been on vacation for the summer.
    I hope you managed to solve your problem, otherwise just tell me!
    //EE
    I finally managed to fix it!

    My Major problem was running a ton of events through a single bottleneck, a String. As you said, everything that was pressed up until the String was registered was overwriting each other until only the last button pressed registered. I even tried putting my original code through an input queue that filled up faster than the String registered and emptied the queue, and it failed because of the same reasons. I replaced the code entirely a few times until I found something that worked, and each "Action" such as Jumping is now an AV on a unique object (this is for visual clarity as arrays are not my thing except for saving the game).

    As a bonus I also reduced the amount of buttons the player can press down to the built-in directions and Fire 1-4. This has improved my game's clarity and accessibility.

    It took me longer than I had hoped to discover exactly what Control X and Joystick 2 Object wanted me to ask of it so that it behaved like the built-in Player expressions that I was already very comfortable with.

  7. #7
    Clicker Fusion 2.5Android Export ModuleSWF Export Module
    EE's Avatar
    Join Date
    Sep 2009
    Posts
    200
    Mentioned
    3 Post(s)
    Tagged
    0 Thread(s)
    Good job and a smart soloution!
    //EE

Similar Threads

  1. Replies: 11
    Last Post: 28th February 2017, 03:00 PM
  2. Replies: 2
    Last Post: 30th June 2014, 05:51 AM
  3. Suggestion: Allow keyboard inputs to be added to conditions
    By mobichan in forum iOS Export Module Version 2.0
    Replies: 8
    Last Post: 29th May 2012, 05:39 PM
  4. BUG: Mouse inputs stop working if the app window loses focus in the debugger
    By mobichan in forum iOS Export Module Version 2.0
    Replies: 0
    Last Post: 3rd February 2012, 02:40 PM
  5. Simple way to read keyboard letter inputs?
    By mobichan in forum Multimedia Fusion 2 - Technical Support
    Replies: 10
    Last Post: 29th January 2012, 11:40 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
  •