Преглед изворни кода

Merge branch 'master' of github.com:LTCatt/LTW3

HerobrineXia пре 5 година
родитељ
комит
8d938299dd

+ 1 - 0
data/mini/functions/diamond/game_init.mcfunction

@@ -11,6 +11,7 @@ time set 9800t
 # 生成地图
 setblock 1000 255 5000 minecraft:structure_block[mode=load]{metadata:"",mirror:"NONE",ignoreEntities:1b,powered:0b,seed:0L,author:"LTCat",rotation:"NONE",posX:0,mode:"LOAD",posY:-24,sizeX:32,posZ:0,integrity:1.0f,showair:0b,name:"mini:diamond_base",sizeY:25,sizeZ:32,showboundingbox:1b}
 setblock 1000 255 5001 redstone_block
+schedule function mini:diamond/game_init2 1t append
 
 # 清理残余实体
 tp @e[type=!player,x=950,y=-200,z=4950,dx=100,dy=600,dz=100] ~ -100 ~

+ 21 - 0
data/mini/functions/diamond/game_init2.mcfunction

@@ -0,0 +1,21 @@
+
+# 矿物生成
+fill 1028 252 5030 1028 252 5027 minecraft:redstone_block
+
+# 地牢 1 生成
+scoreboard players set $random_max mem 4
+scoreboard players set $random_min mem 1
+function lib:random
+execute if score $random mem matches 1 run setblock 1028 254 5030 redstone_block
+execute if score $random mem matches 2 run setblock 1028 254 5029 redstone_block
+execute if score $random mem matches 3 run setblock 1028 254 5028 redstone_block
+execute if score $random mem matches 4 run setblock 1028 254 5027 redstone_block
+
+# 地牢 2 生成
+scoreboard players set $random_max mem 4
+scoreboard players set $random_min mem 1
+function lib:random
+execute if score $random mem matches 1 run setblock 1027 254 5030 redstone_block
+execute if score $random mem matches 2 run setblock 1027 254 5029 redstone_block
+execute if score $random mem matches 3 run setblock 1027 254 5028 redstone_block
+execute if score $random mem matches 4 run setblock 1027 254 5027 redstone_block