BuildIndexMatrix.cs
/// <summary>
/// Constructs the build index matrix that we use to pull build indexes from scene names
///<see cref="buildIndexMatrix"/>
/// </summary>
Constructs the build index matrix that we use to pull build indexes from scene names
Constructs the build index matrix that we use to pull build indexes from scene names
private static void ConstructBuildIndexMatrix()
    {
        buildIndexMatrix.Clear();
        foreach (BuildIndexMapper indexMapper in instance.indexes)
        {
           if (!buildIndexMatrix.ContainsKey(indexMapper.SceneName))
            {
                buildIndexMatrix.Add(indexMapper.SceneName, indexMapper.SceneBuildIndex);
            }
            else
            {
                Debug.LogError(indexMapper.SceneName + " has already been declared as a scene with a build index. We cannot specify it twice");
            }
        }
        foreach (string sceneName in arrayOfNames)
        {
            if (!buildIndexMatrix.ContainsKey(sceneName))
            {
                Debug.LogWarning(sceneName + " was not given an index in " + instance);
            }
        }
    }
private static void ConstructBuildIndexMatrix ( ) { buildIndexMatrix . Clear ( ) ; foreach ( BuildIndexMapper indexMapper in instance . indexes ) { if ( ! buildIndexMatrix . ContainsKey ( indexMapper . SceneName ) ) { buildIndexMatrix . Add ( indexMapper . SceneName , indexMapper . SceneBuildIndex ) ; } else { Debug . LogError ( indexMapper . SceneName + " " ) ; } } foreach ( string sceneName in arrayOfNames ) { if ( ! buildIndexMatrix . ContainsKey ( sceneName ) ) { Debug . LogWarning ( sceneName + " " + instance ) ; } } }
Constructs the build index matrix that we use to pull build indexes from scene names
Constructs the build index matrix that we use to pull build indexes from scene names
//make sure every scene has a name