Skip to content

Commit

Permalink
Merge pull request #57 from mofrison/develop
Browse files Browse the repository at this point in the history
Fix adding buildIndex scenes to freeIndexes
  • Loading branch information
PixeyeHQ authored Jul 3, 2020
2 parents 1de66b7 + c1df5ef commit cd9d978
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Runtime/Core/SceneSub.cs
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ static void RemoveOp(string sceneName)
LayerKernel.LoadJobs.Add(SceneManager.UnloadSceneAsync(sceneName));
LayerKernel.LoadJobs.Add(Resources.UnloadUnusedAssets());
loadedScenes.Remove(sceneName);
freeIndexes.Push(layerIndex);
if (layerIndex >= SceneManager.sceneCountInBuildSettings) { freeIndexes.Push(layerIndex); }
}

internal static int GetLayerIndex(string sceneName)
Expand Down

0 comments on commit cd9d978

Please sign in to comment.