execute as @e[type=minecraft:ender_pearl] on origin run tag @s add has_pearl
execute if entity @s[tag=has_pearl] run return run tag @s remove has_pearl
execute if items entity @s hotbar.* minecraft:ender_pearl run return 0
function pctf:logic/player/out_of_bounds