LdtkFieldInstance
ceramic.LdtkFieldInstance (Class)
An instance of a custom field value.
Represents the actual value of a custom field for an entity or level instance. The value can be of various types: Int, Float, String, Bool, Color, Enum, etc.
Instance Members
The related field definition
Actual value of the field instance. The value type varies, depending on type
.
- For classic types (ie. Integer, Float, Boolean, String, Text and FilePath), you just get the actual value with the expected type.
- For Color, the value is an int value using
0xRRGGBB
format (aceramic.Color
value). - For Enum, the value is a String representing the selected enum value.
- For Point, the value is a
ceramic.Point
object. - For Tile, the value is a
LdtkTilesetRectangle
object. - For EntityRef, the value is a corresponding
LdtkEntityInstance
object. If the field is an array, then this value will also be an array.
Optional tileset rectangle used to display this field (this can be the field own Tile, or some other Tile guessed from the value, like an Enum). (can be null
)
Returns |
---|
String |
ldtk
new(?ldtkData: LdtkData, ?ldtkWorld: LdtkWorld, ?json: haxe.DynamicAccess<Dynamic>, ?def: LdtkFieldDefinition): Void
Name | Type | Default |
---|---|---|
ldtkData |
LdtkData | (optional) |
ldtkWorld |
LdtkWorld | (optional) |
json |
haxe.DynamicAccess<Dynamic> | (optional) |
def |
LdtkFieldDefinition | (optional) |
Private Members
Name | Type | Default |
---|---|---|
ldtkData |
LdtkData | (optional) |
ldtkWorld |
LdtkWorld | (optional) |
rawValue |
Any | (optional) |
type |
String | (optional) |
Returns |
---|
Any |