Class LockedProperty
java.lang.Object
group24.escaperoom.entities.properties.ItemProperty<LockingMethod>
group24.escaperoom.entities.properties.LockedProperty
- All Implemented Interfaces:
com.badlogic.gdx.utils.Json.Serializable
-
Nested Class Summary
Nested classes/interfaces inherited from class group24.escaperoom.entities.properties.ItemProperty
ItemProperty.MenuType -
Field Summary
Fields inherited from class group24.escaperoom.entities.properties.ItemProperty
owner -
Constructor Summary
ConstructorsConstructorDescriptionEmpty constructor forJson.Serializablecompatability constructor -
Method Summary
Modifier and TypeMethodDescriptioncloneProperty(Item newOwner) com.badlogic.gdx.utils.Array<PlayerAction>Get aPropertyConfigurationthat contains all fields necessary to configure this property in theItemEditorcom.badlogic.gdx.utils.Array<LockingMethod>getType()booleanisLocked()voidread(com.badlogic.gdx.utils.Json json, com.badlogic.gdx.utils.JsonValue jsonData) voidset(LockingMethod value) Set the value of this property to value It is the responsibility of the caller to only pass values that are recieved fromItemProperty.getPotentialValues()voidwrite(com.badlogic.gdx.utils.Json json) Methods inherited from class group24.escaperoom.entities.properties.ItemProperty
apply, defaultConfiguration, getActions, getCurrentValues, getOwner, getPopOut, set, setOwner, unsafeSet, unsafeSet, updateTexture
-
Constructor Details
-
LockedProperty
public LockedProperty()Empty constructor forJson.Serializablecompatability constructor
-
-
Method Details
-
getDescription
- Specified by:
getDescriptionin classItemProperty<LockingMethod>- Returns:
- the
PropertyDescriptionof this Property
-
isLocked
public boolean isLocked() -
getPotentialValues
- Specified by:
getPotentialValuesin classItemProperty<LockingMethod>- Returns:
- all possible values for this property
-
getDisplayName
- Specified by:
getDisplayNamein classItemProperty<LockingMethod>- Returns:
- name of this property, used as a display string in menus
-
getType
- Specified by:
getTypein classItemProperty<LockingMethod>- Returns:
PropertyTypeof this property. This allows us to get the property of an item from it's property map- See Also:
-
set
Description copied from class:ItemPropertySet the value of this property to value It is the responsibility of the caller to only pass values that are recieved fromItemProperty.getPotentialValues()- Overrides:
setin classItemProperty<LockingMethod>- Parameters:
value- to set
-
getCurrentValue
- Overrides:
getCurrentValuein classItemProperty<LockingMethod>- Returns:
- the current value of this property
-
getInputType
- Specified by:
getInputTypein classItemProperty<LockingMethod>- Returns:
- the
ItemProperty.MenuTypethat should be used to recieve and display theItemPropertyValueassociated with this property - adding a new input type requires updatingItemMenuto support it
-
getAvailableActions
- Specified by:
getAvailableActionsin classItemProperty<LockingMethod>- Returns:
- all available
PlayerAction
-
cloneProperty
- Overrides:
clonePropertyin classItemProperty<LockingMethod>- Parameters:
newOwner- the new owner of this property- Returns:
- a clone of this item property (along with state and values) for a new item
-
write
public void write(com.badlogic.gdx.utils.Json json) -
getEmptyLockMethod
-
read
public void read(com.badlogic.gdx.utils.Json json, com.badlogic.gdx.utils.JsonValue jsonData) -
getValueClass
- Specified by:
getValueClassin classItemProperty<LockingMethod>- Returns:
- the class of the
ItemPropertyValuefor this property
-
getCustomItemConfigurationMenu
Description copied from class:ItemPropertyGet aPropertyConfigurationthat contains all fields necessary to configure this property in theItemEditor- Overrides:
getCustomItemConfigurationMenuin classItemProperty<LockingMethod>- Returns:
- Some(
PropertyConfiguration) should this property need configuration
-