LTCatt 6 лет назад
Родитель
Сommit
0be4761085

+ 4 - 1
data/ltw/functions/state/0/shop/buy_arrow1.mcfunction → data/ltw/functions/shop/buy_arrow1.mcfunction

@@ -11,4 +11,7 @@ scoreboard players add @s[tag=canbuy] shop_arrow 1
 scoreboard players remove @s[tag=canbuy] gold 9
 
 execute as @s[tag=!canbuy] at @s run function lib:sounds/error
-execute as @s[tag=canbuy] at @s run function lib:sounds/levelup
+execute as @s[tag=canbuy] at @s run function lib:sounds/levelup
+
+function ltw:shop/refresh_gold
+function ltw:shop/refresh_equip

+ 4 - 0
data/ltw/functions/shop/refresh_equip.mcfunction

@@ -0,0 +1,4 @@
+# 刷新单个玩家购买的物品
+
+clear @s arrow
+give @s[scores={shop_arrow=1}] arrow 2

+ 0 - 0
data/ltw/functions/state/0/shop/refresh_gold.mcfunction → data/ltw/functions/shop/refresh_gold.mcfunction


+ 2 - 1
data/ltw/functions/state/0/player_enter.mcfunction

@@ -25,4 +25,5 @@ tp @s[tag=!debug] 10 16 10
 
 # 刷新物品
 clear @s[tag=!debug]
-function ltw:state/0/shop/refresh_gold
+function ltw:shop/refresh_gold
+function ltw:shop/refresh_equip

+ 3 - 0
data/ltw/functions/state/0/start_gameparty.mcfunction

@@ -14,7 +14,10 @@ scoreboard players set $round mem 1
 scoreboard players set $game_type mem 1
 scoreboard players add $ game_id 1
 scoreboard players operation @a game_id = $ game_id
+
+# 重置物品
 clear @a[tag=!watcher,tag=!debug]
+function ltw:shop/refresh_equip
 
 # 开始小游戏
 function lib:sounds/music/stop