Undo removes wrong condition

0 favourites
  • 7 posts
From the Asset Store
Customize the animation of character when item changed
  • Problem Description

    Adding any trigger, adding a condition referencing an object, and then changing that object will cause the undo states to get messed up.

    Attach a Capx

    https://1drv.ms/u/s!AhHSZHEulqh_gWaBvD2nZ1GY7tD7

    Description of Capx

    has comment with instructions to reproduce the undo error.

    Steps to Reproduce Bug

    • create 'on any animation finished' trigger (possibly any trigger will do? edit: I just checked with other triggers and same thing happens!)
    • add any condition that references an object
    • right click and change object sprite to sprite2
    • now undo all states- it will end up remove the first trigger and leaving the condition (it removes the wrong condition)

    Observed Result

    the wrong condition is undone.

    Expected Result

    undo should be in correct order.

    Affected Browsers

    • Chrome: (YES/NO)
    • FireFox: (YES/NO)
    • Internet Explorer: (YES/NO)

    Operating System and Service Pack

    vista sp2

    Construct 2 Version ID

    r227

  • Also, should note that I have experienced this exact same issue with the actions- but haven't figured how to reproduce those cases. It might be related to this case though.

    edit: I figured out the issue with the Actions too! I filed another bug report for that one.

    edit2: seems as if the trigger step is not needed.. So this bug is exact same issue as the action bug (changing object causes undo state to mess up)

  • I can't reproduce, following these steps:

    • I open your .capx file
    • it looks like the event you describe is already created
    • you say "right click and change object sprite to sprite2" so I try right-clicking the first trigger ("on any animation finished"), choose "replace object", replace Sprite with Sprite2
    • you say "now undo all states" - so I press undo

    Result: it correctly undoes the "replace object", and nothing has been removed.

    Did I misunderstand your instructions?

  • Ashley , Yes, you misunderstood. You didn't follow all the steps.

    You have to start with no event. So you need to first CREATE the conditions, so that when you undo later, it will undo he creations of those conditions. Then do the rest of the steps.. create a condition that references one sprite, then right click and change it to another sprite.. then undo so that it has to remove the conditions.. it will remove the conditions in the wrong order..

  • I still can't reproduce this. It's a pretty confusing report for me. Your .capx includes the event you describe, but I'm not meant to use that? OK, so I just create an identical event beneath it? Then when you say "right click and change object...", what exactly am I supposed to right click? I tried following the steps again, and replaced the object for the second condition, and it still worked fine.

    You have to be absolutely precise, thorough and unambiguous with your steps to reproduce, otherwise it's a struggle to follow along with what you're doing.

  • Ashley, here is a youtube video showing the steps: https://youtu.be/LmDXZrNIZBc

    As you see in the video, the On start of layout gets incorrectly undone before the other condition.

    I also show the same issue with undoing actions.

    I create the On start of layout condition.

    Then I create another condition that uses an object.

    Then I right click that condition and choose replace object, replacing with another object.

    Then I undo once to undo the replacement, but then I undo again, and the On start of layout condition is removed instead of the second condition (because replacing the object somehow has now messed up the undo/redo stack).

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Closing as is same underlying issue as https://www.scirra.com/forum/undo-removes-wrong-action_t179505

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)