Jump to content

[TOPIC: topicViewTemplate]
[GLOBAL: userSmallPhoto]
Photo

Change in 2016.2994 causes increased transition times between scenes
Started by Reaver Apr 11 2017 02:35 AM

2 replies to this topic
black screen load time scene change transition gotoscene
[TOPIC CONTROLS]
This topic has been archived. This means that you cannot reply to this topic.
[/TOPIC CONTROLS]
[modOptionsDropdown]
[/modOptionsDropdown]
[reputationFilter]
[TOPIC: post.html]
#1

Reaver

[GLOBAL: userInfoPane.html]
Reaver
  • Enthusiast

  • 87 posts
  • Corona SDK

Hi,

 

We recently tried to update the version of Corona we use to build. After the change we noticed a black screen flashing when doing some scene changes. We narrowed the change down to something that was included in 2016.2994. It only happens on some scene changes so I suspect larger scenes are causing this.

 

Does anyone else have this issue? Is there a way around it? Is this extra delay something we just need to live with now?

 

Here is how the scene change is coded.

composer.gotoScene("nextScene")
composer.removeScene("currentScene")


[TOPIC: post.html]
#2

Rob Miracle

[GLOBAL: userInfoPane.html]
Rob Miracle
  • Moderator

  • 25,922 posts
  • Enterprise

Hi Matthew. I responded to the support query on this, but for the benefit of others, we generally do not recommend removing the scene you're in. In this case composer.gotoScene() dispatches multiple events and returns before the scene is created. If you remove the current scene, if the other scene takes some time to build and show. 

 

You can either remove the scene from another scene (remove a scene before you go to it or remove the scene you just left). However, we've recently tested scene removal and if you put your removeScene() call in the scene:hide() function's "did" phase. At that point the scene you're going to is completely on screen and should avoid the flicker.

 

Rob



[TOPIC: post.html]
#3

Reaver

[GLOBAL: userInfoPane.html]
Reaver
  • Enthusiast

  • 87 posts
  • Corona SDK

Thanks Rob!

 

Doing the remove in the hide function sounds like the best solution and seems like an easy change to make.




[topic_controls]
[/topic_controls]