DetonateSatchels

From Multi Theft Auto: Wiki
Revision as of 19:56, 18 November 2022 by Nikoo. (talk | contribs) (→‎Example)
Jump to navigation Jump to search

This function can be used to detonate a players satchels.

Syntax

Click to collapse [-]
Client
bool detonateSatchels ( )
Click to collapse [-]
Server
bool detonateSatchels ( player Player )

Returns

Returns true if successful, false otherwise.

Example

The below example allows a player to detonate any of their placed satchels via the command /blowsatchels (Client-side)

Click to collapse [-]
Client
addCommandHandler("blowsatchels",
    function()
        detonateSatchels()
    end
)

The below example allows a player to detonate any of their placed satchels via the command /blowsatchels (Server-side)

Click to collapse [-]
Client
addCommandHandler("blowsatchels",
    function(sourcePlayer, commandName)
        detonateSatchels(sourcePlayer)
    end
)

See also