Changes
Page history
Revert "added ClearTarget mechanic"
authored
Oct 02, 2025
by
Lxlp
This reverts commit 1f8283a3389908f340de3fcb5bc030ebbd4ae456.
Hide whitespace changes
Inline
Side-by-side
skills/mechanics/breakBlockAndGiveItem.md
0 → 100644
View page @
38502e7a
## Description
Breaks the block at a target location and gives item(s). This mechanic will also drop the block (with exception of Bedrock). REQUIRES
`forcesync=true`
.
## Attributes
| Attribute | Aliases | Description | Default |
|-----------|-----------|----------------------------------------------------------------------|---------|
| dodrops | drops, d | Whether or not to drop the block/s | true |
| doeffect | effect, e | Whether or not to play the break block particles (?) | true |
| usetool | tool, t | Whether or not to use the tool in the players hands (?) | true |
| doFakeLooting | fakeLooting, fl | Plays the pickup-item animation from the origin | false |
| items | item, i | An array of item materials, or droptables. | |
## Examples
Using Crucible Items:
Instead of dropping dirt, it'll instead give diamonds to the player.
```
yaml
#Items Document
CustomItem
:
Id
:
GOLDEN_SHOVEL
Display
:
'
Lucky
Shovel'
Skills
:
-
skill{s=dirtToDiamonds;sync=true} @origin ~onBreakBlock
#Skills Document
dirtToDiamonds
:
TargetConditions
:
-
blocktype{t=DIRT,GRASS_BLOCK}
true
Skills
:
-
breakBlockAndGiveItem{dodrops=false;items=diamond}
```
## Aliases
-
[x] blockBreakAndGiveItem
<!--TAGS-->
<!--tag:World-->
<!--tag:Inventory-->
<!--tag:Item-->
\ No newline at end of file