@minecraft/server / BlockPrecipitationInteractionsComponent
Class: BlockPrecipitationInteractionsComponent ​
Defined in: @minecraft/server/index.d.ts:5343
Represents a how a block interacts with precipitation (such as rain or snow).
Extends ​
Properties ​
block ​
readonlyblock:Block
Defined in: @minecraft/server/index.d.ts:4377
Remarks ​
Block instance that this component pertains to.
Inherited from ​
isValid ​
readonlyisValid:boolean
Defined in: @minecraft/server/index.d.ts:6234
Remarks ​
Returns whether the component is valid. A component is considered valid if its owner is valid, in addition to any addition to any additional validation required by the component.
Inherited from ​
typeId ​
readonlytypeId:string
Defined in: @minecraft/server/index.d.ts:6240
Remarks ​
Identifier of the component.
Inherited from ​
componentId ​
readonlystaticcomponentId:"minecraft:precipitation_interactions"='minecraft:precipitation_interactions'
Defined in: @minecraft/server/index.d.ts:5345
Methods ​
accumulatesSnow() ​
accumulatesSnow():
boolean
Defined in: @minecraft/server/index.d.ts:5358
Returns ​
boolean
Remarks ​
Returns true if falling snow will accumulate naturally on the block. Returns false if snow will not accumulate on the block.
Throws ​
This function can throw errors.
LocationOutOfWorldBoundariesError
isSnowLoggable() ​
isSnowLoggable():
boolean
Defined in: @minecraft/server/index.d.ts:5371
Returns ​
boolean
Remarks ​
Returns true if this block can have snow within it, like a flower submerged in snow. Returns false if this block cannot have snow within it.
Throws ​
This function can throw errors.
LocationOutOfWorldBoundariesError
obstructsRain() ​
obstructsRain():
boolean
Defined in: @minecraft/server/index.d.ts:5383
Returns ​
boolean
Remarks ​
Returns true if rain will not go through the block. Returns false if rain should go through the block.
Throws ​
This function can throw errors.