GetActiveComponent<T>()
Returns a component of type T from the active build profile. For PlayerSettings, returns the global fallback if no PlayerSettings component is found. Returns null if the component isn't available.
読み終わるまでの所要時間 1 分最終更新 21日前
Definition
- Type: Method
- Namespace: UnityEditor.Build.Profile
- Assembly: UnityEditor.CoreModule
public static T GetActiveComponent<T>() where T : Object
Returns
Type | Description |
|---|---|
| T | A component of type |
Remarks
For BuildProfilePlayerSettings, returns if no build profile is active or if the active build profile uses the global Player settings. To get the Player settings that apply in either case, pass PlayerSettings as .
nullTNote: This method is restricted to ScriptableObject types, PlayerSettings, and BuildProfilePlayerSettings.