tick2.mcfunction 1.0 KB

123456789101112
  1. # 检测玩家死亡
  2. execute as @a[tag=mini_running] at @s if block ~ ~-1 ~ magma_block run function mini:colormatch/player_lose_heart
  3. execute as @a[tag=mini_running] at @s if block ~ ~-2 ~ magma_block run function mini:colormatch/player_lose_heart
  4. # 开始新的一轮
  5. execute if score $countdown_fast mem matches 0 if score $color_match_type mem matches 0 run function mini:colormatch/game/remove_ground
  6. execute if score $countdown_fast mem matches 0 if score $color_match_type mem matches 1 run function mini:colormatch/game/start_new_round
  7. # 显示当前剩余秒数
  8. execute if score $countdown_fast mem matches 1.. if score $color_match_type mem matches 0 run title @a actionbar [{"text":"地板消失: ","color":"red","bold": true},{"score": { "name": "$countdown_fast","objective": "mem"}}]
  9. execute if score $countdown_fast mem matches 1.. if score $color_match_type mem matches 1 run title @a actionbar [{"text":"下一轮: ","color":"green","bold": true},{"score": { "name": "$countdown_fast","objective": "mem"}}]