Ver Fonte

重构传土豆检定

HerobrineXia há 6 anos atrás
pai
commit
577ef587a9

+ 1 - 1
data/mini/functions/hotpm/game/damage_dealt.mcfunction

@@ -1,5 +1,5 @@
 # 如果是土豆持有者在热土豆游戏中打到人,才执行下一步
-execute if entity @s[tag=pm_holding] if entity @a[tag=pm_damage_taken] unless entity @s[tag=pm_damage_taken] at @s run function mini:hotpm/game/damage_dealt2
+execute if entity @s[tag=pm_holding] if entity @a[tag=pm_damage_taken,tag=!pm_holding] at @s run function mini:hotpm/game/damage_dealt2
 
 # 结束伤害判断
 tag @a remove pm_damage_dealt

+ 1 - 0
data/mini/functions/hotpm/player_lose_heart.mcfunction

@@ -12,5 +12,6 @@ summon minecraft:area_effect_cloud ~ ~ ~ {Tags:["pm_boom"]}
 function mini:main/player_lose_heart
 # 最远的人新土豆
 execute if score $player_alive mem matches 2.. as @e[type=area_effect_cloud,tag=pm_boom] at @s as @a[sort=furthest,tag=mini_running,tag=!watcher,limit=1] run function mini:hotpm/game/pm_init
+
 # 强制观战
 # execute at @s as @a[gamemode=spectator,distance=..0.1] run spectate @p[tag=pm_holding]