Browse Source

最后一轮修改随机游戏

LTCatt 5 years ago
parent
commit
b3a6c91635
1 changed files with 4 additions and 3 deletions
  1. 4 3
      data/ltw/functions/state/3/state_enter.mcfunction

+ 4 - 3
data/ltw/functions/state/3/state_enter.mcfunction

@@ -24,13 +24,14 @@ team modify playing color reset
 # 小游戏编号:生成一个 1~[最大游戏编号] 的 randomarray,每次从其中取下一个数。
 execute unless data storage ltw:mini types[0] run function ltw:state/3/newarray
 execute store result score $mini_type mem run data get storage ltw:mini types[0]
-data remove storage ltw:mini types[0]
+execute if score $round mem matches ..4 run data remove storage ltw:mini types[0]
 
-# 小游戏编号覆盖:如果为第 5 轮,则有一半概率选用钻石风暴
+# 小游戏编号覆盖:如果为第 5 轮,则有一半概率选用钻石,一半概率选用贸易
 scoreboard players set $random_max mem 1
 scoreboard players set $random_min mem 0
 function lib:random
-execute if score $round mem matches 5 if score $random mem matches 1 run scoreboard players set $mini_type mem 6
+execute if score $round mem matches 5 if score $random mem matches 0 run scoreboard players set $mini_type mem 6
+execute if score $round mem matches 5 if score $random mem matches 1 run scoreboard players set $mini_type mem 8
 
 # 初始化小游戏
 function mini:main/game_init