scoreboard players add @s emk-sound 1 execute if score @s emk-sound matches 1 positioned ~.5 ~ ~.5 run function emk:kart/sound_drive execute if score @s emk-sound matches 1 run scoreboard players set @s emk-sound 2 execute if score @s emk-sound matches 9 positioned ~-.5 ~ ~.5 run function emk:kart/sound_drive execute if score @s emk-sound matches 9 run scoreboard players set @s emk-sound 10 execute if score @s emk-sound matches 17 positioned ~.5 ~ ~-.5 run function emk:kart/sound_drive execute if score @s emk-sound matches 17 run scoreboard players set @s emk-sound 18 execute if score @s emk-sound matches 25 positioned ~-.5 ~ ~-.5 run function emk:kart/sound_drive execute if score @s emk-sound matches 25 run scoreboard players set @s emk-sound 26 execute if score @s emk-sound matches 33.. run scoreboard players set @s emk-sound 0 function emk:kart/checks execute if score @s emk-chkpnt matches 0..99 if block ~ 0 ~ minecraft:white_wool run function emk:kart/lap execute if score @s emk-chkpnt matches 100..199 if block ~ 0 ~ minecraft:orange_wool run function emk:kart/cpnt1 execute if score @s emk-chkpnt matches 200..299 if block ~ 0 ~ minecraft:magenta_wool run function emk:kart/cpnt2 execute if score @s emk-chkpnt matches 300..399 if block ~ 0 ~ minecraft:light_blue_wool run function emk:kart/cpnt3 execute if score @s emk-chkpnt matches 400..499 if block ~ 0 ~ minecraft:yellow_wool run function emk:kart/cpnt4 execute if score @s emk-chkpnt matches 500..599 if block ~ 0 ~ minecraft:lime_wool run function emk:kart/cpnt5 execute if score @s emk-chkpnt matches 600..699 if block ~ 0 ~ minecraft:pink_wool run function emk:kart/cpnt6 execute if score @s emk-chkpnt matches 700..799 if block ~ 0 ~ minecraft:gray_wool run function emk:kart/cpnt7 execute if score @s emk-chkpnt matches 800..899 if block ~ 0 ~ minecraft:light_gray_wool run function emk:kart/cpnt8 execute if score @s emk-chkpnt matches 900..999 if block ~ 0 ~ minecraft:cyan_wool run function emk:kart/cpnt9 execute if score @s emk-chkpnt matches 1000..1099 if block ~ 0 ~ minecraft:purple_wool run function emk:kart/cpnt10 execute if score @s emk-chkpnt matches 1100..1199 if block ~ 0 ~ minecraft:blue_wool run function emk:kart/cpnt11 execute if score @s emk-chkpnt matches 1200..1299 if block ~ 0 ~ minecraft:brown_wool run function emk:kart/cpnt12 execute if score @s emk-chkpnt matches 1300..1399 if block ~ 0 ~ minecraft:green_wool run function emk:kart/cpnt13 execute if score @s emk-chkpnt matches 1400..1499 if block ~ 0 ~ minecraft:red_wool run function emk:kart/cpnt14 execute if score @s emk-chkpnt matches 1500..1599 if block ~ 0 ~ minecraft:black_wool run function emk:kart/cpnt15 execute if score @s emk-distance matches 1000.. run scoreboard players remove @s emk-distance 1000 execute unless score @s emk-distance matches 1000.. run tp @s ~ ~ ~ execute if score @s emk-distance matches 1000.. if score #tmp emk-item matches 1 positioned ^ ^1 ^.1 run function emk:kart/move execute if score @s emk-distance matches 1000.. if score #tmp emk-item matches 0 positioned ^ ^ ^.1 run function emk:kart/move