2
0
00ll00 6 жил өмнө
parent
commit
bea98b6cfd

+ 9 - 0
data/mini/functions/tntrun/checkfloor.mcfunction

@@ -0,0 +1,9 @@
+#as player at @s positioned ~ ~-1 ~
+# 以下为检测并控制方块消失的命令
+execute if block ~ ~ ~ #mini:tntrun_floor align xyz run tag @e[tag=tntrun_edge,dx=0,dy=0,dz=0] remove tntrun_edge
+execute if block ~ ~ ~ #mini:tntrun_floor align xyz unless entity @e[tag=tntrun_as,dx=0,dy=0,dz=0] run summon minecraft:area_effect_cloud ~.5 ~ ~.5 {Tags:["tntrun_as"],Age: -2147483648, Duration: -1, WaitTime: -2147483648,}
+execute positioned ~0.31 ~ ~0.31 if block ~ ~ ~ #mini:tntrun_floor align xyz unless entity @e[tag=tntrun_as,dx=0,dy=0,dz=0] run summon minecraft:area_effect_cloud ~.5 ~ ~.5 {Tags:["tntrun_as","tntrun_edge"],Age: -2147483648, Duration: -1, WaitTime: -2147483648,}
+execute positioned ~-0.31 ~ ~-0.31 if block ~ ~ ~ #mini:tntrun_floor align xyz unless entity @e[tag=tntrun_as,dx=0,dy=0,dz=0] run summon minecraft:area_effect_cloud ~.5 ~ ~.5 {Tags:["tntrun_as","tntrun_edge"],Age: -2147483648, Duration: -1, WaitTime: -2147483648,}
+execute positioned ~0.31 ~ ~-0.31 if block ~ ~ ~ #mini:tntrun_floor align xyz unless entity @e[tag=tntrun_as,dx=0,dy=0,dz=0] run summon minecraft:area_effect_cloud ~.5 ~ ~.5 {Tags:["tntrun_as","tntrun_edge"],Age: -2147483648, Duration: -1, WaitTime: -2147483648,}
+execute positioned ~-0.31 ~ ~0.31 if block ~ ~ ~ #mini:tntrun_floor align xyz unless entity @e[tag=tntrun_as,dx=0,dy=0,dz=0] run summon minecraft:area_effect_cloud ~.5 ~ ~.5 {Tags:["tntrun_as","tntrun_edge"],Age: -2147483648, Duration: -1, WaitTime: -2147483648,}
+execute if block ~ ~ ~ minecraft:air align xyz positioned ~0.5 ~ ~0.5 run tag @e[tag=tntrun_edge,distance=..1.51] remove tntrun_edge

+ 1 - 7
data/mini/functions/tntrun/tick1.mcfunction

@@ -2,13 +2,7 @@
 tag @a add tntrun_pc
 
 # 以下为检测并控制方块消失的命令
-execute as @a[tag=tntrun_pc,nbt={OnGround:1b}] at @s positioned ~ ~-1 ~ align xyz if block ~ ~ ~ #mini:tntrun_floor positioned ~0.5 ~ ~0.5 run tag @e[tag=tntrun_edge,distance=..0.1] remove tntrun_edge
-execute as @a[tag=tntrun_pc,nbt={OnGround:1b}] at @s positioned ~ ~-1 ~ align xyz if block ~ ~ ~ #mini:tntrun_floor positioned ~0.5 ~ ~0.5 unless entity @e[tag=tntrun_as,distance=..0.1] run summon minecraft:area_effect_cloud ~ ~ ~ {Tags:["tntrun_as"],Age: -2147483648, Duration: -1, WaitTime: -2147483648,}
-execute as @a[tag=tntrun_pc,nbt={OnGround:1b}] at @s positioned ~0.31 ~-1 ~0.31 align xyz if block ~ ~ ~ #mini:tntrun_floor positioned ~0.5 ~ ~0.5 unless entity @e[tag=tntrun_as,distance=..0.1] run summon minecraft:area_effect_cloud ~ ~ ~ {Tags:["tntrun_as","tntrun_edge"],Age: -2147483648, Duration: -1, WaitTime: -2147483648,}
-execute as @a[tag=tntrun_pc,nbt={OnGround:1b}] at @s positioned ~-0.31 ~-1 ~-0.31 align xyz if block ~ ~ ~ #mini:tntrun_floor positioned ~0.5 ~ ~0.5 unless entity @e[tag=tntrun_as,distance=..0.1] run summon minecraft:area_effect_cloud ~ ~ ~ {Tags:["tntrun_as","tntrun_edge"],Age: -2147483648, Duration: -1, WaitTime: -2147483648,}
-execute as @a[tag=tntrun_pc,nbt={OnGround:1b}] at @s positioned ~0.31 ~-1 ~-0.31 align xyz if block ~ ~ ~ #mini:tntrun_floor positioned ~0.5 ~ ~0.5 unless entity @e[tag=tntrun_as,distance=..0.1] run summon minecraft:area_effect_cloud ~ ~ ~ {Tags:["tntrun_as","tntrun_edge"],Age: -2147483648, Duration: -1, WaitTime: -2147483648,}
-execute as @a[tag=tntrun_pc,nbt={OnGround:1b}] at @s positioned ~-0.31 ~-1 ~0.31 align xyz if block ~ ~ ~ #mini:tntrun_floor positioned ~0.5 ~ ~0.5 unless entity @e[tag=tntrun_as,distance=..0.1] run summon minecraft:area_effect_cloud ~ ~ ~ {Tags:["tntrun_as","tntrun_edge"],Age: -2147483648, Duration: -1, WaitTime: -2147483648,}
-execute as @a[tag=tntrun_pc,nbt={OnGround:1b}] at @s positioned ~ ~-1 ~ align xyz if block ~ ~ ~ minecraft:air positioned ~0.5 ~ ~0.5 run tag @e[tag=tntrun_edge,distance=..1.51] remove tntrun_edge
+execute as @a[tag=tntrun_pc,nbt={OnGround:1b}] at @s positioned ~ ~-1 ~ run function mini:tntrun/checkfloor
 
 # 修改下面这一行的数字以调整方块消失的延迟(刻)
 # tntrun_timer=12