Class BaseSetting<T>
Base class for implementing Tutorial Framework settings.
Implements
Inherited Members
Namespace: Unity.Tutorials.Core.Editor
Assembly: Unity.Tutorials.Core.Editor.dll
Syntax
public class BaseSetting<T> : UserSetting<T>, IUserSetting
Type Parameters
Name | Description |
---|---|
T | The Type of the value this Setting contains |
Constructors
BaseSetting(string, string, T, SettingsScope, string)
Constructs the setting.
Declaration
public BaseSetting(string key, string name, T value, SettingsScope scope, string tooltip = null)
Parameters
Type | Name | Description |
---|---|---|
string | key | Key for EditorPrefs (User) or JSON file (Project). |
string | name | Use Tr() in order to have localization support. |
T | value | The value to initialize this new BaseSetting to |
Settings |
scope | The SettingScope defining the scope of that new setting |
string | tooltip | Use Tr() in order to have localization support. |
Properties
Name
Name of the setting.
Declaration
public string Name { get; set; }
Property Value
Type | Description |
---|---|
string |
Tooltip
Tooltip for the setting.
Declaration
public string Tooltip { get; set; }
Property Value
Type | Description |
---|---|
string |
Methods
GetGuiContent()
Returns Name and Tooltip as GUIContent.
Declaration
public GUIContent GetGuiContent()
Returns
Type | Description |
---|---|
GUIContent | A GUIContent containing the Name and Tooltip of that setting |