# Respawn safety handler (run as the player)
# Teleport the player to the active Bordercraft start, and ensure their spawn is inside the border.

execute at @e[tag=bc_anchor,limit=1] run spawnpoint @s ~ 257 ~
execute at @e[tag=bc_anchor,limit=1] run tp @s ~ 257 ~

# Safety effect until landing (loop clears resistance on ground)
effect give @s resistance infinite 255 true
