scoreboard players add @s KyuDummy2 1
###Note: Flowers replaced have to be command blocks that also place soulsand underneath it, otherwise the wither rose will die 

#random movement, and replace blocks. 50% chance to replace plants with blackstone_slabs
execute if predicate suhc:25percent run execute at @s run tp @s ~-1 ~ ~-1
execute if predicate suhc:25percent run execute at @s run tp @s ~1 ~ ~-1
execute at @s run fill ~ ~-8 ~ ~ ~22 ~ minecraft:command_block{auto:1b,Command:"function zzzzdonotuse:biomecorruption/blackcorruption/fillinrose",TrackOutput:0} replace #suhc:flowersandshrooms
execute if predicate suhc:50percent run execute at @s run fill ~ ~-8 ~ ~ ~22 ~ minecraft:blackstone_slab replace #minecraft:replaceable_plants
execute at @s run fill ~ ~-8 ~ ~ ~22 ~ minecraft:black_concrete replace #suhc:solidblocks

#repeat the above once
execute if predicate suhc:25percent run execute at @s run tp @s ~-1 ~ ~1
execute if predicate suhc:25percent run execute at @s run tp @s ~1 ~ ~1
execute at @s run fill ~ ~-8 ~ ~ ~22 ~ minecraft:command_block{auto:1b,Command:"function zzzzdonotuse:biomecorruption/blackcorruption/fillinrose",TrackOutput:0} replace #suhc:flowersandshrooms
execute if predicate suhc:50percent run execute at @s run fill ~ ~-8 ~ ~ ~22 ~ minecraft:blackstone_slab replace #minecraft:replaceable_plants
execute at @s run fill ~ ~-8 ~ ~ ~22 ~ minecraft:black_concrete replace #suhc:solidblocks



#make the marker face the center of the corruption, move the marker backwards, replace blocks again
execute at @s run tp @s ~ ~ ~ facing entity @e[type=armor_stand,limit=1,sort=nearest,tag=Test2]
execute at @s run tp @s ^ ^ ^-.75 ~ 0
execute at @s run fill ~ ~-8 ~ ~ ~22 ~ minecraft:command_block{auto:1b,Command:"function zzzzdonotuse:biomecorruption/blackcorruption/fillinrose",TrackOutput:0} replace #suhc:flowersandshrooms
execute at @s run fill ~ ~-8 ~ ~ ~22 ~ minecraft:black_concrete replace #minecraft:replaceable_plants

#bunch of random chances to fill in certain blocks around the marker
execute if predicate suhc:25percent run execute at @s run fill ~1 ~-8 ~1 ~ ~22 ~ minecraft:blackstone replace #suhc:solidblocks
execute if predicate suhc:25percent run execute at @s run fill ~-1 ~-8 ~-1 ~ ~22 ~ minecraft:blackstone replace #suhc:solidblocks
execute if predicate suhc:25percent run execute at @s run fill ~1 ~-8 ~ ~-1 ~22 ~ minecraft:blackstone replace #suhc:solidblocks
execute if predicate suhc:25percent run execute at @s run fill ~ ~-8 ~1 ~ ~22 ~-1 minecraft:blackstone replace #suhc:solidblocks
execute if predicate suhc:10percent run execute at @s run fill ~2 ~-8 ~ ~-2 ~22 ~ minecraft:blackstone replace #suhc:solidblocks
execute if predicate suhc:10percent run execute at @s run fill ~ ~-8 ~2 ~ ~22 ~-2 minecraft:blackstone replace #suhc:solidblocks

execute if predicate suhc:25percent run execute at @s run fill ~1 ~-8 ~1 ~ ~22 ~ minecraft:black_concrete replace #suhc:solidblocks
execute if predicate suhc:25percent run execute at @s run fill ~-1 ~-8 ~-1 ~ ~22 ~ minecraft:black_concrete replace #suhc:solidblocks
execute if predicate suhc:25percent run execute at @s run fill ~1 ~-8 ~ ~-1 ~22 ~ minecraft:black_concrete replace #suhc:solidblocks
execute if predicate suhc:25percent run execute at @s run fill ~ ~-8 ~1 ~ ~22 ~-1 minecraft:black_concrete replace #suhc:solidblocks
execute if predicate suhc:10percent run execute at @s run fill ~2 ~-8 ~ ~-2 ~22 ~ minecraft:black_concrete replace #suhc:solidblocks
execute if predicate suhc:10percent run execute at @s run fill ~ ~-8 ~2 ~ ~22 ~-2 minecraft:black_concrete replace #suhc:solidblocks

#recurse this function about half a dozen times the first time, run it a few more times the 2nd time it runs, then die
kill @s[scores={KyuDummy2=13..}]
execute as @s[scores={KyuDummy2=..3}] run function zzzzdonotuse:biomecorruption/blackcorruption/endtendrils
execute as @s[scores={KyuDummy2=5..8}] run function zzzzdonotuse:biomecorruption/blackcorruption/endtendrils
execute as @s[scores={KyuDummy2=10..13}] run function zzzzdonotuse:biomecorruption/blackcorruption/endtendrils





