Package net.risingworld.api.objects
Klasse Item.ConstructionItem
java.lang.Object
net.risingworld.api.objects.Item
net.risingworld.api.objects.Item.ConstructionItem
- Umschließende Klasse:
Item
Represents a construction item in the inventory of a player or in a storage box.
This is, for example, a block. Most construction items are represented by a generic "constructionitem", so they have the same item type ID, but only a different construction ID (see
This is, for example, a block. Most construction items are represented by a generic "constructionitem", so they have the same item type ID, but only a different construction ID (see
getConstructionID()
)-
Verschachtelte Klassen - Übersicht
Von Klasse geerbte verschachtelte Klassen/Schnittstellen net.risingworld.api.objects.Item
Item.BlueprintItem, Item.ClothingItem, Item.ConstructionItem, Item.ObjectItem
-
Methodenübersicht
Modifizierer und TypMethodeBeschreibungint
getColor()
Gets the (optional) color of this construction item.Gets the definition of the construction that is represented by this item.byte
Gets the type ID of the construction element that is represented by this item.Gets the name of the construction element that is represented by this item.long
getSize()
void
setColor
(int color) Sets a new color for the construction item.void
setConstructionID
(byte id) Sets the type ID of the construction element that is represented by this item.Von Klasse geerbte Methoden net.risingworld.api.objects.Item
destroy, equals, getDefinition, getDurability, getMaxStackSize, getModifier, getName, getStack, getStatus, getTypeID, getValue, getVariant, hashCode, isValid, setDurability, setModifier, setStack, setStatus, setValue
-
Methodendetails
-
getConstructionID
public byte getConstructionID()Gets the type ID of the construction element that is represented by this item.- Gibt zurück:
- the construction/block type ID.
-
setConstructionID
public void setConstructionID(byte id) Sets the type ID of the construction element that is represented by this item.- Parameter:
id
- the new type ID you want to set.
-
getConstructionName
Gets the name of the construction element that is represented by this item.- Gibt zurück:
- the internal construction element name.
-
getConstructionDefinition
Gets the definition of the construction that is represented by this item.- Gibt zurück:
- the construction definition.
-
getColor
public int getColor()Gets the (optional) color of this construction item.- Gibt zurück:
- the optional color, as RGBA integer.
-
setColor
public void setColor(int color) Sets a new color for the construction item.- Parameter:
color
- the new RGBA color (where the alpha value describes the color strength).
-
getInfoID
public long getInfoID() -
getSize
-