/// <summary> /// Executes an action on each component of the given type in the scene. /// </summary> static public void ForEachComponent <T>(this Scene inScene, bool inbIncludeInteractive, SceneComponentAction <T> inAction) { List <T> allComponents = new List <T>(); GetAllComponents <T>(inScene, inbIncludeInteractive, allComponents); for (int i = 0, count = allComponents.Count; i < count; ++i) { inAction(inScene, allComponents[i]); } }
/// <summary> /// Executes an action on each active component of the given type in the scene. /// </summary> static public void ForEachComponent <T>(this Scene inScene, SceneComponentAction <T> inAction) { ForEachComponent <T>(inScene, false, inAction); }