execute if block ~ ~ ~ minecraft:yellow_glazed_terracotta[facing=north] run scoreboard players set @s bw_block 787
execute if block ~ ~ ~ minecraft:yellow_glazed_terracotta[facing=east] run scoreboard players set @s bw_block 788
execute if block ~ ~ ~ minecraft:yellow_glazed_terracotta[facing=south] run scoreboard players set @s bw_block 789
execute if block ~ ~ ~ minecraft:yellow_glazed_terracotta[facing=west] run scoreboard players set @s bw_block 790