EditorSceneUtils.EnforceSceneComponents Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Goes through a scene's objects and checks for components that aren't found in permittedComponentTypes If any are found, they're added to the violations list.
public:
static bool EnforceSceneComponents(UnityEngine::SceneManagement::Scene scene, System::Collections::Generic::IEnumerable<Type ^> ^ permittedComponentTypes, System::Collections::Generic::List<UnityEngine::Component ^> ^ violations);
public static bool EnforceSceneComponents (UnityEngine.SceneManagement.Scene scene, System.Collections.Generic.IEnumerable<Type> permittedComponentTypes, System.Collections.Generic.List<UnityEngine.Component> violations);
static member EnforceSceneComponents : UnityEngine.SceneManagement.Scene * seq<Type> * System.Collections.Generic.List<UnityEngine.Component> -> bool
Public Shared Function EnforceSceneComponents (scene As Scene, permittedComponentTypes As IEnumerable(Of Type), violations As List(Of Component)) As Boolean
Parameters
- scene
- UnityEngine.SceneManagement.Scene
- permittedComponentTypes
- IEnumerable<Type>
- violations
- List<UnityEngine.Component>