[英]How to wait for orientation change completely before changing scene in Unity
如何在完成下一个任务之前完全等待屏幕切换方向?
IEnumerator ChangeOrientation()
{
Screen.orientation = ScreenOrientation.LandscapeLeft;
// Fix background not completely rotate on unpacking story
yield return Timing.WaitUntilTrue(() => Screen.orientation == ScreenOrientation.LandscapeLeft);
bool unpack = storyData.sceneBundleName.Length > 0; //If we have loaded a scene bundle
StoryManager.Instance.StartStory(this, unpack);
}
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.