Class EventProperty.Choice
EventProperty class for the Choice property.
Implements
Inherited Members
Namespace: Modding
Assembly: Assembly-CSharp.dll
Syntax
public class Choice : EventProperty, IValidatable
Constructors
Choice()
Declaration
public Choice()
Fields
Default
Corresponds to the default XML attribute.
Declaration
public int Default
Field Value
| Type | Description |
|---|---|
| Int32 |
DefaultSpecified
Whether the default attribute was specified.
Declaration
public bool DefaultSpecified
Field Value
| Type | Description |
|---|---|
| Boolean |
Options
The available options, specified in the XML file.
Declaration
[RequireToValidate]
public EventProperty.Choice.Option[] Options
Field Value
| Type | Description |
|---|---|
| EventProperty.Choice.Option[] |
Properties
CurrentIndex
Which option is currently selected. This is an index into the Options array, not to be confused with the Index property of the Option class.
Declaration
public int CurrentIndex { get; set; }
Property Value
| Type | Description |
|---|---|
| Int32 |
Methods
SetIndex(Int32)
Selects the option with the given index. The index here is compared with the Index property of the Option class.
Declaration
public void SetIndex(int index)
Parameters
| Type | Name | Description |
|---|---|---|
| Int32 | index | Which option to select. |