Telepearled

Fires when a Player uses a telepearl.

-- When a player uses a telepearl, give them the Decay status effect
Events.Telepearled(function(event)
    local entity = event.player:getEntity()
    if (entity == nil) then
        return
    end
    StatusEffectService.giveEffect(entity, StatusEffectType.DECAY)
end)

Parameters

player: Player

The player that threw the telepearl

startPos: Vector3

The position where the player threw the telepearl

endPos: Vector3

The position where the telepearl landed (where the player will teleport to)

Last updated