phaser icon indicating copy to clipboard operation
phaser copied to clipboard

quad 3.16.1 crash

Open charmingny opened this issue 7 years ago • 5 comments

Version

  • Phaser Version: 3.16.1

Description

I was using a lot of quads in my game because I wanted perspective card flips animation. When 3.16.1 introduced, I was excited about new scale manager and immediately use it.

** If I use container and quad , the game will crash. caused by "child.setAlpha(childAlpha);" I understand quad alpha is removed but phaser framework is still trying to set that alpha.

** quad setOrigin() is gone. I don't know what am I supposed to change to get that feature back with other way around because I need to rotate my quad with custom center I want to set. It was working the way I want with 3.15.1. May be there is another way now and I need to find and adapt. if there is no other way around this feature is really needed for me.

** quad is not rendering at all if I put inside a container. ( I don't change any code except commenting out setOrigin parts. it was fine with 3.15.1) Need to temporarily commenting out child.setAlpha(childAlpha) in Phaser to test my game

** fullscreen code works fine with windows and android. but with latest ios 's safari (both iPad and iPhone , both orientations ) it doesn't do anything.

** I am not sure about this one. but with 3.15.1, my game on mobile safari is really fast 60 fps most of time. jumping scene to scene is really fast as well. but with 1.16.1, starting a new scene from a splash/boot scene take 4 to 5 seconds (with mobile safari as well) which is unacceptable performance. I need to test more about this whether this is just my problem or phaesr 3.16.1.

charmingny avatar Feb 05 '19 12:02 charmingny

Interesting, nothing has actually changed with Quad's at all in 3.16. They've not been touched since July 2018! The quad tests I ran worked fine, but they weren't in Containers (I'm shocked they even work in Containers tbh)

Fullscreen on iOS requires it to be enabled in Safari Experimental settings.

photonstorm avatar Feb 05 '19 12:02 photonstorm

I opened a similar ticket a few days ago with some simple test code: https://github.com/photonstorm/phaser/issues/4338#issue-405730091

pfdtravalmatic avatar Feb 05 '19 13:02 pfdtravalmatic

restoring ./gameobjects/mesh/mesh.js inside my custom build fix those errors. it also render my quads in my game inside containers.

I also edit in my custom build to use rawDelta time for the game. altough this is not related to any bugs. Please could you allow us to use rawDelta instead of Capped Delta time via some game config?

charmingny avatar Feb 06 '19 18:02 charmingny

The setAlpha method has been restored, so Quad/Mesh works inside a Container again.

I'm not adding setOrigin back because it never did anything anyway. It was never used in rendering and calling it had no impact on rotation or anything. I tested this in 3.15.1 too, and changing the origin does nothing, no matter inside a Container or not.

Delta times are unrelated to this issue and should be opened as a separate feature request.

photonstorm avatar Feb 07 '19 00:02 photonstorm

Thank you for submitting this issue. We have fixed this and the fix has been pushed to the master branch. It will be part of the next release. If you get time to build and test it for yourself we would appreciate that.

photonstorm avatar Feb 07 '19 00:02 photonstorm