Description
The Description
property of the PrefabVariable
class provides a user-friendly description for the variable. This property is intended to offer additional context or information about the variable, making it easier for users to understand its purpose or usage within the application.
Usage
To set or retrieve the description of a PrefabVariable
, use the Description
property. This property is a string
and can be accessed publicly. It is decorated with the TextAreaAttribute
to allow for multi-line input in the editor, and a DescriptionAttribute
to provide metadata about its purpose.
Example
// Example of setting the Description property
PrefabVariable myVariable = new PrefabVariable();
myVariable.Description = "This variable controls the speed of the character.";
// Example of getting the Description property
string variableDescription = myVariable.Description;
// variableDescription now holds the value: "This variable controls the speed of the character."