ItemBase
Package: com.hypixel.hytale.protocol
public class ItemBaseComprehensive item type definition containing all identity, visual, category, tool/weapon/armor/glider/utility specializations, interaction configuration, and durability properties.
Fields
Section titled “Fields”| Type | Name | Nullable | Description |
|---|---|---|---|
String | id | Yes | |
String | model | Yes | |
float | scale | No | |
String | texture | Yes | |
String | animation | Yes | |
String | playerAnimationsId | Yes | |
boolean | usePlayerAnimations | No | |
int | maxStack | No | |
int | reticleIndex | No | |
String | icon | Yes | |
| AssetIconProperties | iconProperties | Yes | |
| ItemTranslationProperties | translationProperties | Yes | |
int | itemLevel | No | |
int | qualityIndex | No | |
ItemResourceType[] | resourceTypes | Yes | |
boolean | consumable | No | |
boolean | variant | No | |
int | blockId | No | |
| ItemTool | tool | Yes | |
| ItemWeapon | weapon | Yes | |
| ItemArmor | armor | Yes | |
| ItemGlider | gliderConfig | Yes | |
| ItemUtility | utility | Yes | |
| BlockSelectorToolData | blockSelectorTool | Yes | |
ItemBuilderToolData | builderToolData | Yes | |
| ItemEntityConfig | itemEntity | Yes | |
String | set | Yes | |
String``[] | categories | Yes | |
ModelParticle[] | particles | Yes | |
ModelParticle[] | firstPersonParticles | Yes | |
ModelTrail[] | trails | Yes | |
| ColorLight | light | Yes | |
double | durability | No | |
int | soundEventIndex | No | |
int | itemSoundSetIndex | No | |
Map<InteractionType, ``Integer``> | interactions | Yes | |
Map<``String``, ``Integer``> | interactionVars | Yes | |
| InteractionConfiguration | interactionConfig | Yes | |
String | droppedItemAnimation | Yes | |
int``[] | tagIndexes | Yes | |
Map``<``Integer, ItemAppearanceCondition[]``> | itemAppearanceConditions | Yes | |
int``[] | displayEntityStatsHUD | Yes | |
| ItemPullbackConfiguration | pullbackConfig | Yes | |
boolean | clipsGeometry | No | |
boolean | renderDeployablePreview | No |
Serialization Layout
Section titled “Serialization Layout”| Constant | Value |
|---|---|
NULLABLE_BIT_FIELD_SIZE | 4 |
FIXED_BLOCK_SIZE | 147 |
VARIABLE_FIELD_COUNT | 26 |
VARIABLE_BLOCK_START | 251 |
MAX_SIZE | 1,677,721,600 |
Binary layout: 4 null-bit bytes + 147 bytes of fixed fields + 26 variable-length fields (4-byte offset slots). All multi-byte primitives use little-endian encoding.
Methods
Section titled “Methods”@Nonnullpublic static ItemBase deserialize(@Nonnull ByteBuf buf, int offset)Deserializes a ItemBase from the given buffer at the specified offset.
public static int computeBytesConsumed(@Nonnull ByteBuf buf, int offset)Returns the total number of bytes consumed by this ItemBase starting at the given offset.
public void serialize(@Nonnull ByteBuf buf)Serializes this ItemBase into the given buffer.
public int computeSize()Returns the serialized size in bytes.
Related Types
Section titled “Related Types”
Hydex is an independent community resource. Hytale is a trademark of Hypixel Studios. Hydex is not affiliated with or endorsed by Hypixel Studios.