User Tag List

Results 1 to 3 of 3

Thread: Inconsistent event triggering when same condition is met

  1. #1
    Clicker

    Fusion 2.5Android Export Module

    Join Date
    Jan 2007
    Posts
    277
    Mentioned
    6 Post(s)
    Tagged
    1 Thread(s)

    Inconsistent event triggering when same condition is met

    Hiya,

    I'm working on some very basic card/array sorting functions for the Array object.

    Cards are stored in an Array/Deck as strings, as I will be storing cards using their actual names. I need to count the number of cards in the deck whenever cards are added or removed, but I am having an issue.

    If I run the following code:

    // * On loop "Count"
    // + StrAtX( "Deck", LoopIndex("Count") ) = ""
    // Count : Add 1 to Counter

    NOTHING happens

    If I run this code:
    * On loop "Count"
    + StrAtX( "Deck", LoopIndex("Count") ) = ""
    Count : Destroy

    The counter named "Count" gets destroyed


    As you can see the conditions are identical. The MFA is attached. The lines in question are 13 and 14.

    Controls:

    Z - Count Cards
    + - Add 1 to selected card index
    - - Sub 1 from selected card index
    Space - Remove card from current index and restack deck


    Try removing one card then running the "Count" code with Z. You will see that nothing happens .
    Attached files Attached files

  2. #2
    Clickteam Fusion 2.5 DeveloperFusion 2.5+ DLCAndroid Export ModuleHTML5 Export ModuleiOS Export ModuleUniversal Windows Platform Export ModuleInstall Creator Pro
    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)
    BartekB's Avatar
    Join Date
    Aug 2013
    Posts
    643
    Mentioned
    14 Post(s)
    Tagged
    0 Thread(s)
    Check event 12 in your example. You run the fast loop and then you set the counter's value, basically overriding what was set by the fast loop.


    You can enter the list event editor by pressing this button, to the right of the event editor button to better see action order:


    You can also double click on the grid to open that event's actions.
    - BartekB, a.k.a Uppernate
    Join the Click Converse Discord! - https://discord.gg/7RNXFrC
    Dungeon Raiders! - Link soon™

  3. #3
    Clicker

    Fusion 2.5Android Export Module

    Join Date
    Jan 2007
    Posts
    277
    Mentioned
    6 Post(s)
    Tagged
    1 Thread(s)
    Good catch! I did check the event list, but missed that.

    Thanks!

Similar Threads

  1. Duplicate event not triggering
    By SteevTee in forum Multimedia Fusion 2 - Technical Support
    Replies: 0
    Last Post: 9th February 2018, 10:14 PM
  2. Replies: 3
    Last Post: 5th March 2017, 08:42 PM
  3. Testing position of item event isn't triggering
    By Janette5 in forum Fusion 2.5
    Replies: 1
    Last Post: 6th February 2015, 10:46 AM
  4. Replies: 1
    Last Post: 7th November 2014, 07:16 AM
  5. Inconsistent triggering of Q&A, take 2
    By Teero in forum File Archive
    Replies: 2
    Last Post: 20th January 2011, 04: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
  •