BeforeProjectileLaunched
Fires before a projectile is launched, allowing you to cancel the event.
-- Cancel all telepearl throws
Events.BeforeProjectileLaunched(function(event)
if (event.shooter == nil) then
return
end
if (event.projectileType == "telepearl") then
event.cancelled = true
end
end)Parameters
shooter: Entity | nil
projectileType: ProjectileType
position: Vector3
velocity: Vector3
sourceItemType: ItemType | nil
cancelled: bool [modifiable]
Last updated