I’ve been trying to figure out this problem for a bit tonight and thought I’d ask if anyone’s run into this with Director. I have a splash screen set up as the first director screen which transitions to a setup screen using a timer to create a delay between the two. This works fine on the simulator but running it on the iPhone it doesn’t perform the transition, but just draws the setup screen on top of the splash screen… [EDIT - Cut the rest of the message]
[import]uid: 8692 topic_id: 9571 reply_id: 309571[/import]
So I thought I’d respond to my own question in case anyone runs into a similar problem which I found to be pretty nasty. It turns out the problem was caused by a corrupted PNG image file. It took me a while to track it down to this but I found that the file opens up fine on the simulator which is why everything worked fine but not on the iPhone.
I verified something was wrong with the file when trying to open it in Photoshop getting an error message saying it was unable to parse the file. Other programs were able to get past the issue and open the file so this made it a hard thing to isolate. Replacing the file with a clean version fixed everything.
It would be nice if Corona would spit out some helpful debug output to the console in this case as it just failed silently.
[import]uid: 8692 topic_id: 9571 reply_id: 35046[/import]
I’m having the same problem and just in case re-saved all png files I have with XnView, but I still can’t see transitions happening on the phone (Android 2.2), only in the emulator.
Here is the sample code:
http://vitalyk.com/test_game.zip
Any thoughts about what could be wrong? [import]uid: 52103 topic_id: 9571 reply_id: 38956[/import]
In my case this has to do with dynamic image scaling, all png’s are fine.
I have background images for each scene and when @2x background image is present there is no visible transition effect on device.
Transitioning to a scene with no @2x version of background works just fine, while transitioning to a scene that has a high-res version of background goes without any animation (although, effect is specified).
The regular background image is 480x320 (landscape orientation) and @2x version is 960x640, while the
[lua]imageSuffix = { ["@2x"] = 1.5 }[/lua]
Test device is HTC Desire Android 2.2 with screen resolution of 800x480 (thus the 1.5 ratio).
Maybe somebody from Ansca could have a look at the example code above?
Also, I have to say that scenes contain other high-res version of images (buttons) that don’t prevent Director class from working as it should, unlike hi-res backdrop images.
EDIT: I modified the attached example to transition from one scene to another without Director class and it transitions just fine both on device and emulator. So it doesn’t look like a [lua]transition.to[/lua] bug, as I thought initially, and probably has something to do with Director. Here is the modified example:
http://vitalyk.com/transition_test2.zip [import]uid: 52103 topic_id: 9571 reply_id: 38957[/import]