User Tag List

Results 1 to 3 of 3

Thread: Stop processing after one action or another method to achieve this

  1. #1
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)

    Join Date
    Jun 2015
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)

    Stop processing after one action or another method to achieve this

    Hi, as a total noob to f2.5 to learn I'm basicallytrying to make super simple tablet game for my little daughter and I've hit a little roadblock in the logic. I'm trying keep it as simple as possible to use as few options as possible. I have a background image, when the user clicks it spawns an item. This aspects works fine. When you click on the spawned object I want to animate & destroy it. I've both both of these working in isolation, but in practice, with both events active, when I'm clicking it's instantly spawning and destroying. Is there a way I can tell it to exit from processing the user click event after the object is spawned. Essentially I want to implement:

    Click
    > if clicking on existing item - explode item
    > if not click on existing item - spawn new random

    I'm trying to find someway to process one action without the other depending on what's clicked, which sounds simple. I've tried five different ways from Sunday, for something that sounds really simple, so I'm assuming I'm missing something really fundamental with fusion2.5. I've tried searching for similar issues, I've tried setting a global value on creation of the object, with this value reset after a short duration, and the value checked to see whether the destroy action should be carried out. No joy. I've tried the counter object set to 100, reset to zero on create and incremented back on a timer to check whether. I've tried using NEGATE on whether the cursor is already over one of the explody objects before spawning. I've tried making the background an active picture and only spawning when the mouse is over this, and only destroying when the mouse is over one of the spawned objects. I haven't seem to hit on the right combination. In programming logic this one of several simple methods such as a condition statement etc.. but I'm struggling to translate this into f2.5 logic. One example failed rule attached. Attachment 21065

    Is there any way anyone could suggest that would allow me to use the same left click/tap to both create and destroy, depending what the mouse is directly over. I'm assuming that the mouse over object considers all objects in the layers below, is it possible to limit it this to the object directly below the cursor position for instance?

    I'm fully expecting that I'm doing something really stupid so if you could point me in the right direction I'd really appreciate it.

  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,367
    Mentioned
    13 Post(s)
    Tagged
    0 Thread(s)
    Yes, this can be a little tricky. What you need to do, is to tell Fusion to only create an object if the mouse is not over any objects. Even this sounds straight forward, couldn't you just use a [Negate] overlap condition? But it isn't that simple. You need to make separate events to find out if the mouse is overlapping an object or not.

    * Always
    - Set value of Counter to 0. // You can use a global value instead of a counter if you want.

    * Mouse is overlapping Item:
    - Set value of Counter to 1.

    Now you can test if counter is 0 (not overlapping) or 1 (overlapping).

    * User clicks with left button
    + Counter = 0
    - Create Item
    - Item: Set Xpos to XMouse
    - Item: Set YPos to YMouse

    * User clicks on Item
    - Item: Destroy

  3. #3
    Clicker Fusion 2.5 (Steam)Fusion 2.5 Developer (Steam)Android Export Module (Steam)HTML5 Export Module (Steam)

    Join Date
    Jun 2015
    Posts
    3
    Mentioned
    0 Post(s)
    Tagged
    0 Thread(s)
    Popcorn, you sir are a pro! Thanks. I had to make a slight tweak:

    * User clicks on Item + condition = 1
    - Item: Destory.

    You've solved several more hours of frustration than I'd like to admit, so thank you again

Similar Threads

  1. How do I temporarily stop a recurring action?
    By Exoaria in forum Fusion 2.5
    Replies: 2
    Last Post: 10th January 2016, 10:58 AM
  2. Video Integration - Processing/Handling
    By Superpie in forum Multimedia Fusion 2 - Technical Support
    Replies: 2
    Last Post: 10th September 2013, 10:47 PM
  3. [Request] Image processing
    By SolarB in forum iOS Export Module Version 2.0
    Replies: 0
    Last Post: 22nd October 2012, 03:50 PM
  4. processing XML
    By life2searching in forum SWF/Flash Export Module Version 2.0
    Replies: 3
    Last Post: 16th February 2011, 03:15 PM
  5. Bug in the stop action
    By lsproc in forum The Games Factory 2 - Technical Support
    Replies: 7
    Last Post: 28th July 2006, 10:27 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
  •