-
Notifications
You must be signed in to change notification settings - Fork 48
Reorderable Attribute Options
Jeiel Aranal edited this page Jul 5, 2017
·
2 revisions
Optional settings when using the Reorderable
attribute that changes how the reorderable list is displayed.
Reorderable(string elementLabel, bool isZeroIndex=true, bool isSingleLine=false)
Custom string for the element label
public class ListReorderTest : MonoBehaviour
{
[Reorderable("String")]
public string[] stringArray; // Array elements listed as: "String 0"
[Reorderable("Other String", isZeroIndex:false)]
public List<string> stringList; // Array elements listed as: "Other String 1"
}
Does the array display start from 0?
Force the element to be drawn as a single line in the list. Useful for serialized classes or structs that don't contain that many elements.