Interface GeyserItemDataComponents
@NonExtendable
public interface GeyserItemDataComponents
Geyser data components are data components used for non-vanilla items only. Like vanilla data components, they indicate behavior of custom items, and like vanilla data components, it is expected
that this behavior is also present server-side and on Java clients.
Most components in this class will likely be deprecated in the future as Mojang introduces Java counterparts.
- Since:
- 2.9.3
- See Also:
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final ItemDataComponent<Integer>Places a visual indicator (=tooltip) of the item's attack damage.static final ItemDataComponent<GeyserBlockPlacer>Indicates which block the item should place and whether it should replace the original item for that block.static final ItemDataComponent<GeyserChargeable>Marks this item as chargeable, meaning an item functions as a bow or a crossbow.static final ItemDataComponent<Unit>Marks the item as an entity placer, meaning it can place entities, e.g.static final ItemDataComponent<Unit>Marks the item as a projectile, meaning it can be used as ammunition in the chargeable component.static final ItemDataComponent<GeyserThrowableComponent>Marks the item as throwable, meaning it can be thrown continuously by holding down the use button, and also allows specifying if the client should display a swing animation when the item is thrown.
-
Field Details
-
CHARGEABLE
Marks this item as chargeable, meaning an item functions as a bow or a crossbow. A list of bedrock item identifiers can be given as ammunition.- Since:
- 2.9.3
- See Also:
-
ATTACK_DAMAGE
Places a visual indicator (=tooltip) of the item's attack damage. Must be at or above 0.Attribute modifiers are automatically translated for custom vanilla items, but not for non-vanilla ones, which is why this component is here.
- Since:
- 2.9.3
-
BLOCK_PLACER
Indicates which block the item should place and whether it should replace the original item for that block.- Since:
- 2.9.3
- See Also:
-
THROWABLE
Marks the item as throwable, meaning it can be thrown continuously by holding down the use button, and also allows specifying if the client should display a swing animation when the item is thrown.- Since:
- 2.9.3
- See Also:
-
PROJECTILE
Marks the item as a projectile, meaning it can be used as ammunition in the chargeable component.- Since:
- 2.9.3
- See Also:
-
ENTITY_PLACER
Marks the item as an entity placer, meaning it can place entities, e.g. a boat or minecart item.All items placing entities should be marked with this component to prevent client-side desyncs.
- Since:
- 2.9.3
-