I’ve got this strange problem.
I’m trying to find memory leaks in my application, and I got to one, which is kind of… strange.
I’m creating a sprite instance and decorate it with some functions. Then I run some transition and remove it from screen. I make sure to remove all references, transitions etc.
After some debugging and code commenting I end up with two scenarios:
Scenario 1:
- Create object
- Decorate object
- Add it to the group
- Wait 2 seconds
- Remove object
Scenario 2:
- Create object
- Decorate object
- Add it to the group
- Remove object
After running scenario 1 I can see that no memory is released.
After running scenario 2 all memory is released soon after object is removed.
There are no other differences between scenarios. During decoration nothing is going on with object apart from decorating it with functions. No transitions, no timers, no listeners - nothing.
I would appreciate any tips on what should I do now
[import]uid: 109453 topic_id: 26064 reply_id: 326064[/import]