0 Favourites

Destroy/Create Objects: Family membership is wrong

  • Problem Description

    Immedeatly after destroying an object, which is part of the family, that family is not being "updated". I have similar issues on creating objects by Func´s. The uploaded example contains only the destroying issue.

    Attach a Capx

    see uploaded file

    Description of Capx

    On touch (end): 2 sprites get destroyed and created, inbetween debug messages show the familiy.Count, which is partly wrong during the process.

    Steps to Reproduce Bug

    • Touch/Klick anywhere
    • See debug message, especially: ("Family.Count = 2" -> "sprite 1 and 2 destroyed" -> "Family.Count = 2")
    • Enable "Wait 1.0s"
    • See debug message, especially: ("Family.Count = 2" -> "sprite 1 and 2 destroyed" -> "Family.Count = 0")

    Observed Result

    Family membership is not being updated immedeatly after creating/destroying objects? Or between Func calls?

    Expected Result

    see step 3-4 (with Wait 1.0)

    Affected Browsers

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

    Operating System and Service Pack

    Windows 8 SP1

    Construct 2 Version ID

    R168 64bit

  • Closing as won't fix: due to the way the event engine works, objects are not really actually created or destroyed until the end of the next top level event or trigger. In this case since everything happens in one event, the destroyed objects will not actually be removed until after everything else has already run.

  • Construct 3

    Buy Construct 3

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

    Buy Now Construct 3 users don't see these ads
  • Thanks for clarification!

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