فهرست منبع

添加提示与音效

LTCatt 6 سال پیش
والد
کامیت
9e1709af21

+ 1 - 1
data/mini/functions/main/game_start.mcfunction

@@ -20,7 +20,7 @@ execute if score $mini_type mem matches 6 run scoreboard objectives setdisplay b
 execute if score $mini_type mem matches 6 run scoreboard objectives setdisplay sidebar kill_phantom
 execute if score $mini_type mem matches 7 run scoreboard objectives setdisplay list health_disp
 execute if score $mini_type mem matches 7 run scoreboard objectives setdisplay belowName total_score
-execute if score $mini_type mem matches 7 run scoreboard objectives setdisplay sidebar total_score
+execute if score $mini_type mem matches 7 run scoreboard objectives setdisplay sidebar slime_score
 
 # 调用其他模块
 execute if score $mini_type mem matches 1 run function mini:parkour/game_start

+ 1 - 1
data/mini/functions/slime/game/damage_taken.mcfunction

@@ -1,3 +1,3 @@
 execute as @a[tag=mini_running] store result score @s UUID run data get entity @s UUID[0]
 scoreboard players reset @s UUID
-execute as @a[tag=mini_running] if score @s UUID = $slime_last_hit mem run scoreboard players add @s slime_score 1
+execute as @a[tag=mini_running] if score @s UUID = $slime_last_hit mem at @s run function mini:slime/game/get_score

+ 7 - 0
data/mini/functions/slime/game/get_score.mcfunction

@@ -0,0 +1,7 @@
+scoreboard players add @s slime_score 1
+
+execute as @a[tag=!watcher] run scoreboard players operation @s temp = @s slime_score
+execute as @a[tag=!watcher] run scoreboard players operation @s temp %= #const_5 mem
+execute as @a[tag=!watcher,scores={temp=1..}] run function lib:sounds/hit
+execute as @a[tag=!watcher,scores={temp=0}] run function lib:sounds/levelup
+execute as @a[tag=!watcher,scores={temp=0}] run tellraw @a ["",{"text": ">> ","color":"gold","bold": true},{"selector": "@s","color":"gold"}," 已获得 ",{"score": { "name": "@s","objective": "kill_phantom"},"color":"gold"},{"text":" 分","color":"gold"}]

+ 1 - 1
data/mini/functions/slime/game/set_attack.mcfunction

@@ -1 +1 @@
-execute as @e[type=slime] run attribute @s minecraft:generic.attack_damage base set 2
+execute as @e[type=slime] run attribute @s minecraft:generic.attack_damage base set 2.2

+ 1 - 1
data/mini/functions/slime/player_intro.mcfunction

@@ -1,7 +1,7 @@
 # 向单个玩家展示小游戏介绍
 tp @s[tag=!debug] 1004.13 7.86 7003.00 -2922.38 12.84
 tellraw @s ["",{"text":"\n >> 夺命足球 >>\n\n","color":"gold","bold":true}," 将史莱姆踢到其他人的脸上, 其他人就是你的球门!\n"]
-tellraw @s ["",{"text": " <积分制> ","color":"red","bold": true}, {"text":"击退史莱姆, 每撞到一个人获得一封。","color":"gray"}]
+tellraw @s ["",{"text": " <积分制> ","color":"red","bold": true}, {"text":"击退史莱姆, 每撞到一个人获得一分。","color":"gray"}]
 tellraw @s ["",{"text": " <间接 PVP> ","color":"light_purple","bold": true}, {"text":"无法直接攻击他人, 但可以击退史莱姆撞击他人。","color":"gray"}]
 tellraw @s ["",{"text": " <提供补给> ","color":"aqua","bold": true}, {"text":"快捷栏的最后一格将提供击退 I 木棍。","color":"gray"}]
 tellraw @s ["",{"text": " <原型> ","color":"gold","bold": true}, {"text":"此游戏目前仅用于玩法测试, 尚未进行修缮。","color":"gray"}]