Skip to content

Commit a0dec37

Browse files
committed
fix soul glass removing beacon data
1 parent 25e7293 commit a0dec37

2 files changed

Lines changed: 14 additions & 8 deletions

File tree

gm4_soul_glass/data/gm4_soul_glass/function/destroy.mcfunction

Lines changed: 0 additions & 8 deletions
This file was deleted.

gm4_soul_glass/data/gm4_soul_glass/function/machine/destroy.mcfunction

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,20 @@
33
# located at @s
44
# run from gm4_smelteries:machine/verify_destroy
55

6+
# restore beacon effect
7+
execute if score @s gm4_sg_primary matches 1 run data modify block ~ ~-1 ~ primary_effect set value "minecraft:speed"
8+
execute if score @s gm4_sg_primary matches 3 run data modify block ~ ~-1 ~ primary_effect set value "minecraft:haste"
9+
execute if score @s gm4_sg_primary matches 5 run data modify block ~ ~-1 ~ primary_effect set value "minecraft:strength"
10+
execute if score @s gm4_sg_primary matches 8 run data modify block ~ ~-1 ~ primary_effect set value "minecraft:jump_boost"
11+
execute if score @s gm4_sg_primary matches 11 run data modify block ~ ~-1 ~ primary_effect set value "minecraft:resistance"
12+
13+
execute if score @s gm4_sg_secondary matches 1 run data modify block ~ ~-1 ~ secondary_effect set value "minecraft:speed"
14+
execute if score @s gm4_sg_secondary matches 3 run data modify block ~ ~-1 ~ secondary_effect set value "minecraft:haste"
15+
execute if score @s gm4_sg_secondary matches 5 run data modify block ~ ~-1 ~ secondary_effect set value "minecraft:strength"
16+
execute if score @s gm4_sg_secondary matches 8 run data modify block ~ ~-1 ~ secondary_effect set value "minecraft:jump_boost"
17+
execute if score @s gm4_sg_secondary matches 10 run data modify block ~ ~-1 ~ secondary_effect set value "minecraft:regeneration"
18+
execute if score @s gm4_sg_secondary matches 11 run data modify block ~ ~-1 ~ secondary_effect set value "minecraft:resistance"
19+
620
# kill entities related to machine block
721
execute store result score $dropped_item gm4_machine_data run kill @e[type=item,distance=..1,nbt={Age:0s,Item:{id:"minecraft:brown_stained_glass",count:1}},nbt=!{Item:{components:{}}},limit=1,sort=nearest]
822
kill @s

0 commit comments

Comments
 (0)