Destroy/Create Objects: Family membership is wrong

Bugs will be moved here once resolved.

Post » Thu May 15, 2014 4:19 pm

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
You do not have the required permissions to view the files attached to this post.
B
5
S
1
Posts: 4
Reputation: 288

Post » Tue May 20, 2014 12:10 pm

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.
Scirra Founder
B
387
S
230
G
88
Posts: 24,251
Reputation: 192,454

Post » Sun May 25, 2014 9:21 pm

Thanks for clarification!
B
5
S
1
Posts: 4
Reputation: 288


Return to Closed bugs

Who is online

Users browsing this forum: Elliott and 2 guests