RemoveComponent
Removes a component of type T from a given build profile.
阅读时间1 分钟最后更新于 14 天前
Definition
- Type: Method
- Namespace: UnityEditor.Build.Profile
- Assembly: UnityEditor.CoreModule
RemoveComponent<T>()
Removes a component of type from a given build profile.
Tpublic void RemoveComponent<T>() where T : Object
Remarks
To make a build profile use the global Player settings, graphics settings, or quality levels again, remove its BuildProfilePlayerSettings, BuildProfileGraphicsSettings, or BuildProfileQualitySettings component. Unity destroys the removed object.
If you remove BuildProfilePlayerSettings from an active build profile, Unity recompiles scripts when the scripting define symbols change, and logs a warning for Player settings that only take effect after you restart the Editor.
Note: This method is restricted to ScriptableObject types and doesn't support all settings visible in the Build Profiles window.
RemoveComponent<T>(T)
Removes a component of type from a given build profile.
Tpublic void RemoveComponent<T>(T objectToRemove) where T : Object
Parameters
Remarks
To make a build profile use the global Player settings, graphics settings, or quality levels again, remove its BuildProfilePlayerSettings, BuildProfileGraphicsSettings, or BuildProfileQualitySettings component. Unity destroys the removed object.
If you remove BuildProfilePlayerSettings from an active build profile, Unity recompiles scripts when the scripting define symbols change, and logs a warning for Player settings that only take effect after you restart the Editor.
Note: This method is restricted to ScriptableObject types and doesn't support all settings visible in the Build Profiles window.