execute at @a[tag=K] run fill ~-30 -64 ~-30 ~30 -64 ~30 orange_concrete replace bedrock

scoreboard players add @e[name=DayQ,type=armor_stand] TextT 1
execute as @e[name=DayQ,type=armor_stand,scores={TextT=1}] run scoreboard players set #DayQ ProgBookDay 1
execute as @e[name=DayQ,type=armor_stand,scores={TextT=1}] run scoreboard players set @a ProgBookDay 0
execute as @e[name=DayQ,type=armor_stand,scores={TextT=1}] run scoreboard players set @s DayQ 1
execute as @e[name=DayQ,type=armor_stand,scores={TextT=1}] run data modify storage kyuprogressionbookcalendar HardModeBuff set value ""
execute as @e[name=DayQ,type=armor_stand,scores={TextT=1}] run function zzzzdonotuse:misc/progressionbook/onetimestorageset with storage minecraft:kyuprogressionbookcalendar
execute as @e[name=DayQ,type=armor_stand,scores={TextT=1}] run execute store result storage minecraft:kyuprogressionbookcalendar DayValue int 1 run scoreboard players get #DayQ ProgBookDay
execute as @e[name=DayQ,type=armor_stand,scores={TextT=1}] run function zzzzdonotuse:daytimer/appendprogressiontomainbook with storage minecraft:kyuprogressionbookcalendar
execute as @e[name=DayQ,type=armor_stand,scores={TextT=1}] run execute as @a run execute at @s run function zzzzdonotuse:misc/progressionbook/giveplayerinitialbook

execute at @e[name=DayQ,type=armor_stand,scores={TextT=1}] run tellraw @a[team=P] ["",{"text":"Welcome to Super Ultra HardCore!","color":"red"}]
execute at @e[name=DayQ,type=armor_stand,scores={TextT=21}] run tellraw @a[team=P,tag=!StopText] ["",{"text":"To start you off:","color":"gold"}]
execute at @e[name=DayQ,type=armor_stand,scores={TextT=61}] run tellraw @a[team=P,tag=!StopText] ["",{"text":"- You have been teleported to a random location.","color":"yellow"}]
execute at @e[name=DayQ,type=armor_stand,scores={TextT=91}] run tellraw @a[team=P,tag=!StopText] ["",{"text":"- Your inventory has been cleared.","color":"yellow"}]
execute at @e[name=DayQ,type=armor_stand,scores={TextT=151}] run tellraw @a[team=P,tag=!StopText] ["",{"text":"- You have been given a couple of books and a carrot.","color":"yellow"}]
execute at @e[name=DayQ,type=armor_stand,scores={TextT=231}] run tellraw @a[team=P,tag=!StopText] ["",{"text":"- The book placed in the top corner of your inventory contains more info about SUHC and its mechanics, if you wish to know a bit more in-depth. It will also store mob progression info from current and past days. Aside from that - Best of luck to you. You'll need it.","color":"yellow"}]



#execute as @e[name=DayQ,type=armor_stand,scores={TextT=371}] run tellraw @a[team=P] ["",{"text":"You are on Day ","color":"green"},{"score":{"name":"@e[name=DayQ]","objective":"DayQ2"},"color":"green"},{"text":".","color":"green"}]
#execute as @e[name=DayQ,type=armor_stand,scores={TextT=371},tag=HardMode] run function zzzzdonotuse:daytimer/daytext
#execute as @e[name=DayQ,type=armor_stand,scores={TextT=371},tag=NormalMode] run function zzzzdonotuse:difficulty/normalmodeprogression
#execute as @e[name=DayQ,type=armor_stand,scores={TextT=371},tag=EasyMode] run function zzzzdonotuse:difficulty/easymodeprogression
#
#execute as @e[name=DayQ,type=armor_stand,scores={TextT=371},tag=HardMode] run execute at @s run function zzzzdonotuse:daytimer/hardmoderandombuff
#execute as @e[name=DayQ,type=armor_stand,scores={TextT=371},tag=HardMode] run execute at @s run function zzzzdonotuse:daytimer/hardmoderandombufftext
#execute as @e[name=DayQ,type=armor_stand,scores={TextT=371},tag=BuffSkeletonFireball] run execute in overworld run data merge block 999982 128 999971 {auto:1b}



#execute as @e[name=DayQ,type=armor_stand,scores={TextT=1}] run data modify storage kyuprogressionbookcalendar HardModeBuff set value ""
#execute as @e[name=DayQ,type=armor_stand,scores={TextT=1}] run function zzzzdonotuse:misc/progressionbook/onetimestorageset with storage minecraft:kyuprogressionbookcalendar
#execute as @e[name=DayQ,type=armor_stand,scores={TextT=1}] run execute as @a run execute at @s run function zzzzdonotuse:misc/progressionbook/giveplayerinitialbook
#
#execute as @e[name=DayQ,type=armor_stand,scores={TextT=371}] run execute store result storage minecraft:kyuprogressionbookcalendar DayValue int 1 run scoreboard players get @e[limit=1,name=DayQ] DayQ2
#execute as @e[name=DayQ,type=armor_stand,scores={TextT=371}] run function zzzzdonotuse:daytimer/appendprogressiontomainbook with storage minecraft:kyuprogressionbookcalendar
execute as @e[name=DayQ,type=armor_stand,scores={TextT=371}] run scoreboard players set @s DayQ 0
execute as @e[name=DayQ,type=armor_stand,scores={TextT=371}] run execute at @s run function zzzzdonotuse:daytimer/daytimermain
execute as @e[name=DayQ,type=armor_stand,scores={TextT=371..}] run data merge block ~ ~ ~ {auto:0b}
