start_gameparty.mcfunction 791 B

123456789101112131415161718192021222324
  1. # 开始派对模式
  2. # 设置旁观
  3. tag @a add watcher
  4. tag @a[tag=hub_ready,sort=random,limit=8,tag=!debug] remove watcher
  5. tellraw @a[tag=debug] "你正处于 Debug 模式中, 将忽略游戏开始!"
  6. # 设置数据
  7. scoreboard players reset * total_score
  8. scoreboard players set @a[tag=!watcher] total_score 0
  9. scoreboard players reset * total_score_disp
  10. scoreboard players set @a[tag=!watcher] total_score_disp 0
  11. scoreboard players set $round mem 1
  12. scoreboard players set $game_type mem 1
  13. scoreboard players add $ game_id 1
  14. scoreboard players operation @a game_id = $ game_id
  15. # 重置物品
  16. clear @a[tag=!watcher,tag=!debug]
  17. execute as @a[tag=!watcher,tag=!debug] at @s run function item:shop/refresh_equip
  18. # 开始小游戏
  19. function lib:sounds/music/stop
  20. function ltw:state/3/state_enter