Loop Help

Currently trying to make a loop but it doesn't work properly

Roll1.mcfunction:

title @a times 0 140 0
execute as @a store result score @s lasttime.rolling run random value 8..30

#red
execute as @a[scores={lasttime.rolling=8}] run title @s title [{"color":"red","score":{"name":"@s","objective":"lasttime.rolling"}},{"color":"gray","text":" hours"}]

#yellow
execute as @a[scores={lasttime.rolling=9..16}] run title @s title [{"color":"yellow","score":{"name":"@s","objective":"lasttime.rolling"}},{"color":"gray","text":" hours"}]

#green
execute as @a[scores={lasttime.rolling=16..24}] run title @s title [{"color":"green","score":{"name":"@s","objective":"lasttime.rolling"}},{"color":"gray","text":" hours"}]

#dark green
execute as @a[scores={lasttime.rolling=24..}] run title @s title [{"color":"dark_green","score":{"name":"@s","objective":"lasttime.rolling"}},{"color":"gray","text":" hours"}]

#scheduling
execute if score scroll lasttime.count1 <= 50 lasttime.count1 run function lasttime:rolling/roll2
execute if score scroll lasttime.count1 <= 66 lasttime.count1 run schedule function lasttime:rolling/roll2 15t
execute if score scroll lasttime.count1 <= 85 lasttime.count1 run schedule function lasttime:rolling/roll2 1.5s
execute if score scroll lasttime.count1 <= 95 lasttime.count1 run schedule function lasttime:rolling/result 5s

#misc
execute at @s run playsound ui.button.click master @s ~ ~ ~
scoreboard players add scroll lasttime.count1 1

roll2.mcfunction

title @a times 0 140 0
execute as @a store result score @s lasttime.rolling run random value 8..30

#red
execute as @a[scores={lasttime.rolling=8}] run title @s title [{"color":"red","score":{"name":"@s","objective":"lasttime.rolling"}},{"color":"gray","text":" hours"}]

#yellow
execute as @a[scores={lasttime.rolling=9..16}] run title @s title [{"color":"yellow","score":{"name":"@s","objective":"lasttime.rolling"}},{"color":"gray","text":" hours"}]

#green
execute as @a[scores={lasttime.rolling=16..24}] run title @s title [{"color":"green","score":{"name":"@s","objective":"lasttime.rolling"}},{"color":"gray","text":" hours"}]

#dark green
execute as @a[scores={lasttime.rolling=24..}] run title @s title [{"color":"dark_green","score":{"name":"@s","objective":"lasttime.rolling"}},{"color":"gray","text":" hours"}]

#scheduling
execute if score scroll lasttime.count1 <= 50 lasttime.count1 run function lasttime:rolling/roll2
execute if score scroll lasttime.count1 <= 66 lasttime.count1 run schedule function lasttime:rolling/roll2 15t
execute if score scroll lasttime.count1 <= 85 lasttime.count1 run schedule function lasttime:rolling/roll2 1.5s
execute if score scroll lasttime.count1 <= 95 lasttime.count1 run schedule function lasttime:rolling/result 5s

#misc
execute at @s run playsound ui.button.click master @s ~ ~ ~
scoreboard players add scroll lasttime.count1 1

Currently don't have anything in result but my problem is that it doesn't slow down and for some reason, the scoreboard is showing in game but the "player" scroll isn't gaining anything

Continue to help post