Posts made by Mike Evmm

It seems it's openfl.audio.Sound that's flawed -- calling play with any number of loops works fine, but playing the same sound multiple times results in a cutoff at the end, as well as Event.SOUND_COMPLETE not being called.

@starry-abyss From within the sprite itself, only if I have the sprite extend a SortableFlxSpriteor something, but I was trying to avoid that, since I can't then have the sprite extend anything else...

Which is meant to be cleaner than having to remember to call sort every time I call add. This is working now (I was calling sortSpritesByZ() before super.add(Object) and not after ), but there's still the issue of this not updating if I change a sprite's Z. Since the property comes from an Interface, I can't really have a set behaviour. Anyone have any ideas?

Why should overlapping objects have different Zs? Just found out that's precisely why the sprites flicker; I guess HaxeFlixel isn't deterministic on how it decides which sprite should be on top, if they have the same Z value.

Still wanting to know where I should put sortSpritesByZ() instead of update() to prevent my FPS from plummeting.

I'm trying to implement a Z variable system to allow for easy sprite sorting. My current code works fine on Windows, but the sprites flicker on Flash, regardless of whether I call sortSpriteByZ() before or after super.update(elapsed)!