So I tried this code:
But somehow every skullthat I click on it teleports me to the same player again and again...
code_language.skript:
on click with a clock:
name of tool is "&bTeleport":
open chest with 3 rows named "&cTeleport" to the player
wait a tick
set {_s} to 0
loop all players in player's world:
if loop-player is not player:
format slot {_s} of player with loop-player's skull named "&6%loop-player%" to close then run [make player execute command "/tp %loop-player%"]
add 1 to {_s}
But somehow every skullthat I click on it teleports me to the same player again and again...