# PERMANENT #

execute if predicate simply_oneblock:ib_checkair run scoreboard players add fake_player ib_minedcount 1
execute as @e[type=item,distance=..2] at @s run tp @s 0 65 0

execute as @a at @s if predicate simply_oneblock:dimension_adventure run gamerule mobGriefing false
execute as @a at @s if predicate simply_oneblock:dimension_survival run gamerule mobGriefing true

execute as @a at @s if predicate simply_oneblock:dimension_adventure run gamemode adventure
execute as @a at @s if predicate simply_oneblock:dimension_survival run gamemode survival

execute as @a at @s if predicate simply_oneblock:dimension_no_weapons run clear @s minecraft:iron_sword[lore=[[{text: "Dungeon Weapons", italic: 0b, color:"blue"}]]]
execute as @a at @s if predicate simply_oneblock:dimension_no_weapons run clear @s minecraft:bow[lore=[[{text: "Dungeon Weapons", italic: 0b, color:"blue"}]]]
execute as @a at @s if predicate simply_oneblock:dimension_no_weapons run clear @s minecraft:shield[lore=[[{text: "Dungeon Weapons", italic: 0b, color:"blue"}]]]
execute as @a at @s if predicate simply_oneblock:dimension_no_weapons run clear @s minecraft:diamond_sword[lore=[[{text: "Dungeon Weapons", italic: 0b, color:"blue"}]]]
execute as @a at @s if predicate simply_oneblock:dimension_no_weapons run clear @s minecraft:golden_hoe[lore=[[{text: "Dungeon Tools", italic: 0b, color:"blue"}]]]
execute as @a at @s if predicate simply_oneblock:dimension_no_weapons run clear @s minecraft:leather_leggings[lore=[[{text: "Dungeon Wear", italic: 0b, color:"blue"}]]]
execute as @a at @s if predicate simply_oneblock:dimension_no_weapons run clear @s minecraft:brush[lore=[[{text: "Archaeology Tool", italic: 0b, color:"blue"}]]]
execute as @a at @s if predicate simply_oneblock:dimension_no_weapons run clear @s minecraft:crossbow[lore=[[{text: "Dungeon Weapons", italic: 0b, color:"blue"}]]]
execute as @a at @s if predicate simply_oneblock:dimension_no_weapons run clear @s minecraft:iron_axe[lore=[[{text: "Dungeon Weapons", italic: 0b, color:"blue"}]]]
execute as @a at @s if predicate simply_oneblock:dimension_no_weapons run clear @s minecraft:trident[lore=[[{text: "Dungeon Weapons", italic: 0b, color:"blue"}]]]



# PHASE 1 #

execute if score fake_player ib_minedcount matches 1..54 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_1
execute if score fake_player ib_minedcount matches 55 run function simply_oneblock:ib_phase_final/phase_final_1

execute as @a at @s in simply_oneblock:phase_1 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 2 #

execute if score fake_player ib_minedcount matches 56..259 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_2
execute if score fake_player ib_minedcount matches 260 run function simply_oneblock:ib_phase_final/phase_final_2

execute as @a at @s in simply_oneblock:phase_2 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 3 #

execute if score fake_player ib_minedcount matches 261..549 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_3
execute if score fake_player ib_minedcount matches 550 run function simply_oneblock:ib_phase_final/phase_final_3

execute as @a at @s in simply_oneblock:phase_3 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 4 #

execute if score fake_player ib_minedcount matches 551..999 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_4
execute if score fake_player ib_minedcount matches 1000 run function simply_oneblock:ib_phase_final/phase_final_4

execute as @a at @s in simply_oneblock:phase_4 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 5 #

execute if score fake_player ib_minedcount matches 1001..1499 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_5
execute if score fake_player ib_minedcount matches 1500 run function simply_oneblock:ib_phase_final/phase_final_5

execute as @a at @s in simply_oneblock:phase_5 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 6 #

execute if score fake_player ib_minedcount matches 1501..1999 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_6
execute if score fake_player ib_minedcount matches 2000 run function simply_oneblock:ib_phase_final/phase_final_6

execute as @a at @s in simply_oneblock:phase_6 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 7 #

execute if score fake_player ib_minedcount matches 2001..2499 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_7
execute if score fake_player ib_minedcount matches 2500 run function simply_oneblock:ib_phase_final/phase_final_7

execute as @a at @s in simply_oneblock:phase_7 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 8 #

execute if score fake_player ib_minedcount matches 2501..2999 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_8
execute if score fake_player ib_minedcount matches 3000 run function simply_oneblock:ib_phase_final/phase_final_8

execute as @a at @s in simply_oneblock:phase_8 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 9 #

execute if score fake_player ib_minedcount matches 3001..3499 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_9
execute if score fake_player ib_minedcount matches 3500 run function simply_oneblock:ib_phase_final/phase_final_9

execute as @a at @s in simply_oneblock:phase_9 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 10 #

execute if score fake_player ib_minedcount matches 3501..3999 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_10
execute if score fake_player ib_minedcount matches 4000 run function simply_oneblock:ib_phase_final/phase_final_10

execute as @a at @s in simply_oneblock:phase_10 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 11 #

execute if score fake_player ib_minedcount matches 4001..4499 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_11
execute if score fake_player ib_minedcount matches 4500 run function simply_oneblock:ib_phase_final/phase_final_11

execute as @a at @s in simply_oneblock:phase_11 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 12 #

execute if score fake_player ib_minedcount matches 4501..4999 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_12
execute if score fake_player ib_minedcount matches 5000 run function simply_oneblock:ib_phase_final/phase_final_12

execute as @a at @s in simply_oneblock:phase_12 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 13 #

execute if score fake_player ib_minedcount matches 5001..5499 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_13
execute if score fake_player ib_minedcount matches 5500 run function simply_oneblock:ib_phase_final/phase_final_13

execute as @a at @s in simply_oneblock:phase_13 if predicate simply_oneblock:portal run time set day
execute as @a at @s in simply_oneblock:phase_13 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 14 #

execute if score fake_player ib_minedcount matches 5501..5999 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_14
execute if score fake_player ib_minedcount matches 6000 run function simply_oneblock:ib_phase_final/phase_final_14

execute as @a at @s in simply_oneblock:phase_14 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 15 #

execute if score fake_player ib_minedcount matches 6001..6499 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_15
execute if score fake_player ib_minedcount matches 6500 run function simply_oneblock:ib_phase_final/phase_final_15

execute as @a at @s in simply_oneblock:phase_15 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 16 #

execute if score fake_player ib_minedcount matches 6501..6999 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_16
execute if score fake_player ib_minedcount matches 7000 run function simply_oneblock:ib_phase_final/phase_final_16

execute as @a at @s in simply_oneblock:phase_16 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 17 #

execute if score fake_player ib_minedcount matches 7001..7499 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_17
execute if score fake_player ib_minedcount matches 7500 run function simply_oneblock:ib_phase_final/phase_final_17

execute as @a at @s in simply_oneblock:phase_17 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 18 #

execute if score fake_player ib_minedcount matches 7501..7999 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_18
execute if score fake_player ib_minedcount matches 8000 run function simply_oneblock:ib_phase_final/phase_final_18

execute as @a at @s in simply_oneblock:phase_18 if predicate simply_oneblock:portal run execute in minecraft:overworld run tp @s 0 65 0



# PHASE 19 #

execute if score fake_player ib_minedcount matches 8001..8499 if block 0 64 0 air run function simply_oneblock:ib_randomizer/phase_19
execute if score fake_player ib_minedcount matches 8500 run function simply_oneblock:ib_phase_final/phase_final_19



# PHASE 20 #

# First set #

execute if score fake_player ib_minedcount matches 8501 if block 0 64 0 minecraft:air run setblock 0 64 0 minecraft:bedrock keep
execute if score fake_player ib_minedcount matches 8501 if block 0 64 0 minecraft:bedrock run function simply_oneblock:ib_phase_final/phase_final_20



# Reset #

execute if score fake_player ib_minedcount matches 10001 run scoreboard players set fake_player ib_minedcount 8501



# Permanent TP mechanic #

execute as @a at @s if score fake_player ib_minedcount matches 8501..10000 in minecraft:overworld if predicate simply_oneblock:portal run execute in simply_oneblock:phase_20 run tp @s 2 74 0

execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_home run execute in minecraft:overworld run tp @s 0 65 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_1 run execute in simply_oneblock:phase_1 run tp @s 0 78 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_2 run execute in simply_oneblock:phase_2 run tp @s 0 78 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_3 run execute in simply_oneblock:phase_3 run tp @s 5 73 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_4 run execute in simply_oneblock:phase_4 run tp @s 0 78 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_5 run execute in simply_oneblock:phase_5 run tp @s 0 78 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_6 run execute in simply_oneblock:phase_6 run tp @s 5 76 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_7 run execute in simply_oneblock:phase_7 run tp @s 5 76 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_8 run execute in simply_oneblock:phase_8 run tp @s 5 80 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_9 run execute in simply_oneblock:phase_9 run tp @s 0 78 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_10 run execute in simply_oneblock:phase_10 run tp @s 0 78 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_11 run execute in simply_oneblock:phase_11 run tp @s 0 80 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_12 run execute in simply_oneblock:phase_12 run tp @s 0 80 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_13 run execute in simply_oneblock:phase_13 run tp @s 0 80 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_14 run execute in simply_oneblock:phase_14 run tp @s 0 78 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_15 run execute in simply_oneblock:phase_15 run tp @s 0 80 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_16 run execute in simply_oneblock:phase_16 run tp @s 0 78 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_17 run execute in simply_oneblock:phase_17 run tp @s 0 85 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_18 run execute in simply_oneblock:phase_18 run tp @s 0 79 0
execute as @a at @s in simply_oneblock:phase_20 if predicate simply_oneblock:portal_phase_19 run execute in simply_oneblock:phase_19 run tp @s 2 71 8



# Permanent phase selector mechanic #

execute in simply_oneblock:phase_20 if block 18 76 0 minecraft:bamboo_button[powered=true] store result score fake_player ib_phase_randomizer run random value 1..23
execute in simply_oneblock:phase_20 if block 18 76 0 minecraft:bamboo_button[powered=true] run setblock 19 77 0 air

execute in simply_oneblock:phase_20 if block 19 77 0 air run playsound minecraft:block.stone_button.click_on block @a 19 77 0 1 2

execute if score fake_player ib_phase_randomizer matches 1 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:oak_log
execute if score fake_player ib_phase_randomizer matches 2 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:grass_block
execute if score fake_player ib_phase_randomizer matches 3 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:stone
execute if score fake_player ib_phase_randomizer matches 4 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:spruce_log
execute if score fake_player ib_phase_randomizer matches 5 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:snow_block
execute if score fake_player ib_phase_randomizer matches 6 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:moss_block
execute if score fake_player ib_phase_randomizer matches 7 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:warped_nylium
execute if score fake_player ib_phase_randomizer matches 8 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:crimson_nylium
execute if score fake_player ib_phase_randomizer matches 9 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:netherrack
execute if score fake_player ib_phase_randomizer matches 10 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:basalt
execute if score fake_player ib_phase_randomizer matches 11 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:soul_soil
execute if score fake_player ib_phase_randomizer matches 12 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:prismarine
execute if score fake_player ib_phase_randomizer matches 13 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:jungle_log
execute if score fake_player ib_phase_randomizer matches 14 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:mud
execute if score fake_player ib_phase_randomizer matches 15 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:dark_oak_log
execute if score fake_player ib_phase_randomizer matches 16 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:mushroom_stem
execute if score fake_player ib_phase_randomizer matches 17 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:pale_oak_log
execute if score fake_player ib_phase_randomizer matches 18 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:cherry_log
execute if score fake_player ib_phase_randomizer matches 19 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:sculk
execute if score fake_player ib_phase_randomizer matches 20 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:acacia_log
execute if score fake_player ib_phase_randomizer matches 21 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:terracotta
execute if score fake_player ib_phase_randomizer matches 22 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:sandstone
execute if score fake_player ib_phase_randomizer matches 23 if block 19 77 0 air run execute in simply_oneblock:phase_20 run setblock 19 77 0 minecraft:end_stone

execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 1 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:oak_log
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 2 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:grass_block
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 3 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:stone
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 4 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:spruce_log
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 5 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:snow_block
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 6 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:moss_block
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 7 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:warped_nylium
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 8 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:crimson_nylium
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 9 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:netherrack
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 10 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:basalt
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 11 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:soul_soil
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 12 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:prismarine
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 13 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:jungle_log
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 14 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:mud
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 15 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:dark_oak_log
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 16 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:mushroom_stem
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 17 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:pale_oak_log
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 18 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:cherry_log
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 19 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:sculk
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 20 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:acacia_log
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 21 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:terracotta
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 22 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:sandstone
execute in minecraft:overworld if score fake_player ib_phase_randomizer matches 23 if block 0 64 0 bedrock run execute in minecraft:overworld run setblock 0 64 0 minecraft:end_stone



# Permanent ib_randomizer_selector #

execute if score fake_player ib_phase_randomizer matches 1 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_1
execute if score fake_player ib_phase_randomizer matches 2 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_2
execute if score fake_player ib_phase_randomizer matches 3 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_3
execute if score fake_player ib_phase_randomizer matches 4 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_4
execute if score fake_player ib_phase_randomizer matches 5 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_5
execute if score fake_player ib_phase_randomizer matches 6 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_6
execute if score fake_player ib_phase_randomizer matches 7 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_7
execute if score fake_player ib_phase_randomizer matches 8 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_8
execute if score fake_player ib_phase_randomizer matches 9 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_9
execute if score fake_player ib_phase_randomizer matches 10 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_10
execute if score fake_player ib_phase_randomizer matches 11 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_11
execute if score fake_player ib_phase_randomizer matches 12 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_12
execute if score fake_player ib_phase_randomizer matches 13 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_13
execute if score fake_player ib_phase_randomizer matches 14 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_14
execute if score fake_player ib_phase_randomizer matches 15 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_15
execute if score fake_player ib_phase_randomizer matches 16 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_16
execute if score fake_player ib_phase_randomizer matches 17 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_17
execute if score fake_player ib_phase_randomizer matches 18 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_18
execute if score fake_player ib_phase_randomizer matches 19 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_19
execute if score fake_player ib_phase_randomizer matches 20 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_20
execute if score fake_player ib_phase_randomizer matches 21 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_21
execute if score fake_player ib_phase_randomizer matches 22 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_22
execute if score fake_player ib_phase_randomizer matches 23 if block 0 64 0 air run function simply_oneblock:ib_after_phase/phase_23



# Wither Arena Set #

execute in simply_oneblock:phase_7 run execute if block 28 79 0 minecraft:vault[facing=west,ominous=true]{server_data:{total_ejections_needed: 3}} run place template simply_oneblock:phase_7_wither_arena_bl 29 70 -22
execute in simply_oneblock:phase_7 run execute if block 28 79 0 minecraft:vault[facing=west,ominous=true]{server_data:{total_ejections_needed: 3}} run place template simply_oneblock:phase_7_wither_arena_bm 29 70 -7
execute in simply_oneblock:phase_7 run execute if block 28 79 0 minecraft:vault[facing=west,ominous=true]{server_data:{total_ejections_needed: 3}} run place template simply_oneblock:phase_7_wither_arena_br 29 70 8
execute in simply_oneblock:phase_7 run execute if block 28 79 0 minecraft:vault[facing=west,ominous=true]{server_data:{total_ejections_needed: 3}} run place template simply_oneblock:phase_7_wither_arena_ml 44 70 -22
execute in simply_oneblock:phase_7 run execute if block 28 79 0 minecraft:vault[facing=west,ominous=true]{server_data:{total_ejections_needed: 3}} run place template simply_oneblock:phase_7_wither_arena_mm 44 70 -7
execute in simply_oneblock:phase_7 run execute if block 28 79 0 minecraft:vault[facing=west,ominous=true]{server_data:{total_ejections_needed: 3}} run place template simply_oneblock:phase_7_wither_arena_mr 44 70 8
execute in simply_oneblock:phase_7 run execute if block 28 79 0 minecraft:vault[facing=west,ominous=true]{server_data:{total_ejections_needed: 3}} run place template simply_oneblock:phase_7_wither_arena_tl 59 70 -22
execute in simply_oneblock:phase_7 run execute if block 28 79 0 minecraft:vault[facing=west,ominous=true]{server_data:{total_ejections_needed: 3}} run place template simply_oneblock:phase_7_wither_arena_tm 59 70 -7
execute in simply_oneblock:phase_7 run execute if block 28 79 0 minecraft:vault[facing=west,ominous=true]{server_data:{total_ejections_needed: 3}} run place template simply_oneblock:phase_7_wither_arena_tr 59 70 8

execute in simply_oneblock:phase_7 run execute if block 28 79 0 minecraft:vault[facing=west,ominous=true]{server_data:{total_ejections_needed: 3}} run playsound minecraft:entity.lightning_bolt.thunder block @a 28 79 0

execute in simply_oneblock:phase_7 run execute if block 28 79 0 minecraft:vault[facing=west,ominous=true]{server_data:{total_ejections_needed: 3}} run fill 28 78 -2 29 81 2 air
