ServersYour serverFor creatorsForumFAQDocumentationSecurity
Download the launcher
  1. Documentation
  2. Server events
  3. onObjectBreak

Event

onObjectBreak

ServerObjectsTrilogy Hub only

A script-created object was destroyed in the game (e.g. a smashed fence). An explosive barrel also explodes for everyone.

Handler

addEventHandler("onObjectBreak", root, function(attacker) ... end)

Parameters

attackerplayer
The player whose game reported it.

Source

source is the object.

Example

addEventHandler("onObjectBreak", root, function()
    setTimer(respawnObject, 30000, 1, source)
end)

See also