BlockWaterContainerComponent Class
Caution
This class is still in pre-release. Its signature may change or it may be removed in future releases.
Extends
Represents a fluid container block that currently contains water.
Methods
addDye
addDye(itemType: ItemType): void
Adds an item and colors the water based on a dye item type.
Parameters
- itemType: ItemType
Important
This function can't be called in read-only mode.
Warning
This function can throw errors.
getCustomColor
getCustomColor(): RGBA
Retrieves a custom base color used for the sign text.
Returns RGBA - Color that is used as the base color for sign text.
Warning
This function can throw errors.
setCustomColor
setCustomColor(color: RGBA): void
Sets a custom base color used for the sign text.
Parameters
- color: RGBA
Important
This function can't be called in read-only mode.
Warning
This function can throw errors.
Constants
componentId
static read-only componentId = "minecraft:waterContainer";
Type: string
Feedback
https://aka.ms/ContentUserFeedback.
Coming soon: Throughout 2024 we will be phasing out GitHub Issues as the feedback mechanism for content and replacing it with a new feedback system. For more information see:Submit and view feedback for