GetJetpackWeaponEnabled

From Multi Theft Auto: Wiki

This function checks if a weapon is usable while on a Jetpack.

Syntax

bool getJetpackWeaponEnabled(string weapon)

Required Arguments

  • weapon: The weapon that's being checked if it's usable on a Jetpack.

Returns

Returns true if the weapon is enabled, else false if the weapon isn't or invalid arguments are passed.

Example

addCommandHandler("isJPEnabled",function(ped,_,wep)
	if ped then
		outputChatBox(tostring(getJetpackWeaponEnabled(wep)),ped)
	end
end)

Requirements

Minimum supported server 1.3.1
Minimum supported client n/a

Note: Using this function requires the resource to have the above minimum version declared in the meta.xml <min_mta_version> section. e.g. <min_mta_version server="1.3.1" />

See Also