
# -> Check for block collision
execute unless block ~ ~ ~ #overly_realistic:spear_can_passthrough run \
    return run \
        execute if block ~ ~ ~ #spruce_logs run \
            loot spawn ~ ~ ~ loot overly_realistic:items/resin_from_spruce_stripping

# -> Increment raycast
scoreboard players add #or.Raycast.RayRange OverlyRealistic.General.ArbitraryData 1

# -> Loop
execute unless score #or.Raycast.RayRange OverlyRealistic.General.ArbitraryData >= #or.Raycast.RayRangeMax OverlyRealistic.General.ArbitraryData \
    positioned ^ ^ ^0.1 run \
        function overly_realistic:players/items/axe_use_on_logs/log_raycast_travel
