Enum Class MapObjectType
- All Implemented Interfaces:
Serializable, Comparable<MapObjectType>, Constable
Enumerates the built-in map object types LITIengine recognizes when loading
.tmx maps. Each value matches the type attribute used
by the engine's map object loaders to instantiate the matching engine entity.-
Nested Class Summary
Nested classes/interfaces inherited from class Enum
Enum.EnumDesc<E> -
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionA generic area without a dedicated entity representation.A static collision rectangle.A creature entity.A particle emitter.A dynamic light source.A prop entity.A point/area emitting a sound.A spawn point for dynamically spawned entities.A static (baked) shadow.A trigger that fires messages when activated. -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final StringSentinel value used to identifyIMapObjectinstances without an explicit type attribute. -
Method Summary
Modifier and TypeMethodDescriptionstatic MapObjectTypefromOrdinal(int n) Returns the enum value at the given ordinal.static MapObjectTypeReturns the enum value matching the supplied name, ornullif the name is blank or does not match any known value.static MapObjectTypeReturns the enum constant of this class with the specified name.static MapObjectType[]values()Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
AREA
A generic area without a dedicated entity representation. -
COLLISIONBOX
A static collision rectangle. -
EMITTER
A particle emitter. -
LIGHTSOURCE
A dynamic light source. -
PROP
A prop entity. -
CREATURE
A creature entity. -
SOUNDSOURCE
A point/area emitting a sound. -
SPAWNPOINT
A spawn point for dynamically spawned entities. -
TRIGGER
A trigger that fires messages when activated. -
STATICSHADOW
A static (baked) shadow.
-
-
Field Details
-
UNDEFINED_MAPOBJECTTYPE
Sentinel value used to identifyIMapObjectinstances without an explicit type attribute.- See Also:
-
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum class has no constant with the specified nameNullPointerException- if the argument is null
-
fromOrdinal
Returns the enum value at the given ordinal.- Parameters:
n- the ordinal- Returns:
- the matching enum value
-
get
Returns the enum value matching the supplied name, ornullif the name is blank or does not match any known value.- Parameters:
mapObjectType- the type name- Returns:
- the matching enum value, or
null
-