KitType

Methods
8
Fields
12

Getting one

KitType.valueOf(…)
KitType.HEAD
KitType.CAPE

Methods

MethodReturnsDescription
name()stringThe constant's name as declared.
ordinal()numberThe constant's 0-based position in values().
toString()stringname(); tostring(c) answers the same.
compareTo(KitType)numberThis ordinal less other's.
equals(any)booleanWhether other is this constant. == answers the same.
getIndex()numberThis constant's getIndex() value, listed on each constant.
values(){KitType}Every constant in ordinal order, as a 1-based array: the same frozen array every values() call, so table.clone it before changing it.
valueOf(string)KitTypevalueOf(name): the constant named name; any other name is an error.

Fields

FieldTypeDescription
CAPEKitTypeCAPE: ordinal 1; getIndex() 1.
AMULETKitTypeAMULET: ordinal 2; getIndex() 2.
WEAPONKitTypeWEAPON: ordinal 3; getIndex() 3.
TORSOKitTypeTORSO: ordinal 4; getIndex() 4.
SHIELDKitTypeSHIELD: ordinal 5; getIndex() 5.
ARMSKitTypeARMS: ordinal 6; getIndex() 6.
LEGSKitTypeLEGS: ordinal 7; getIndex() 7.
HAIRKitTypeHAIR: ordinal 8; getIndex() 8.
HANDSKitTypeHANDS: ordinal 9; getIndex() 9.
BOOTSKitTypeBOOTS: ordinal 10; getIndex() 10.
JAWKitTypeJAW: ordinal 11; getIndex() 11.

Returned by

MethodReturnsDescription
KitTypeClass.valueOfKitTypevalueOf(name): the constant named name; any other name is an error.
KitTypeClass.values{KitType}Every constant in ordinal order, as a 1-based array: the same frozen array every values() call, so table.clone it before changing it.

Method details

name

name: (KitType) -> string

The constant's name as declared.

ordinal

ordinal: (KitType) -> number

The constant's 0-based position in values().

equals

equals: (KitType, any) -> boolean

Whether other is this constant. == answers the same.

getIndex

getIndex: (KitType) -> number

This constant's getIndex() value, listed on each constant.

values

values: () -> {KitType}

Every constant in ordinal order, as a 1-based array: the same frozen array every values() call, so table.clone it before changing it.

valueOf

valueOf: (string) -> KitType

valueOf(name): the constant named name; any other name is an error.