<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://wiki.multitheftauto.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Aermyne</id>
	<title>Multi Theft Auto: Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://wiki.multitheftauto.com/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Aermyne"/>
	<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/wiki/Special:Contributions/Aermyne"/>
	<updated>2026-05-26T17:35:14Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.39.3</generator>
	<entry>
		<id>https://wiki.multitheftauto.com/index.php?title=SetJetpackWeaponEnabled&amp;diff=62579</id>
		<title>SetJetpackWeaponEnabled</title>
		<link rel="alternate" type="text/html" href="https://wiki.multitheftauto.com/index.php?title=SetJetpackWeaponEnabled&amp;diff=62579"/>
		<updated>2019-05-05T12:36:08Z</updated>

		<summary type="html">&lt;p&gt;Aermyne: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;__NOTOC__ &lt;br /&gt;
{{Server function}}&lt;br /&gt;
This function sets a weapon usable while using the Jetpack.&lt;br /&gt;
{{Note|colt 45, sawed-off, tec-9 and uzi are always enabled for the Jetpack and are not affected by this function}}&lt;br /&gt;
==Syntax== &lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;bool setJetpackWeaponEnabled(string weapon, bool enabled)&amp;lt;/syntaxhighlight&amp;gt; &lt;br /&gt;
&lt;br /&gt;
===Required Arguments=== &lt;br /&gt;
*'''weapon''' The weapon that's being set usable on a Jetpack. Names can be: (Case is ignored)&lt;br /&gt;
{{All Weapon Types}}&lt;br /&gt;
*'''enabled''' A bool representing whether the weapon is enabled or disabled.&lt;br /&gt;
&lt;br /&gt;
===Returns===&lt;br /&gt;
Returns true, else false if invalid arguments are passed.&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;addEventHandler(&amp;quot;onResourceStart&amp;quot;,resourceRoot,function()&lt;br /&gt;
     if setJetpackWeaponEnabled(&amp;quot;31&amp;quot;,true) then&lt;br /&gt;
          outputChatBox(getWeaponNameFromID(31)..&amp;quot; is now enabled for jetpacks!&amp;quot;)&lt;br /&gt;
     end&lt;br /&gt;
end)&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
==Example==&lt;br /&gt;
&amp;lt;syntaxhighlight lang=&amp;quot;lua&amp;quot;&amp;gt;&lt;br /&gt;
local weapons = {&lt;br /&gt;
    31,&lt;br /&gt;
    34,&lt;br /&gt;
    33,&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
addEventHandler(&amp;quot;onResourceStart&amp;quot;,resourceRoot,function()&lt;br /&gt;
    for i,v in ipairs(weapons) do&lt;br /&gt;
        if setJetpackWeaponEnabled(v,true) then&lt;br /&gt;
            outputChatBox(getWeaponNameFromID(v)..&amp;quot; is now enabled for jetpacks!&amp;quot;)&lt;br /&gt;
        end&lt;br /&gt;
    end&lt;br /&gt;
end&lt;br /&gt;
)&amp;lt;/syntaxhighlight&amp;gt;&lt;br /&gt;
&lt;br /&gt;
== Issues ==&lt;br /&gt;
{{Issues|&lt;br /&gt;
{{Issue|8827|If you use setJetpackWeaponEnabled to make weapons usable on jetpack and then wield them on jetpack, the weapon can become invisible.}}&lt;br /&gt;
}}&lt;br /&gt;
&lt;br /&gt;
==Requirements==&lt;br /&gt;
{{Requirements|1.3.1|n/a|}}&lt;br /&gt;
==See Also==&lt;br /&gt;
{{World_functions}}&lt;/div&gt;</summary>
		<author><name>Aermyne</name></author>
	</entry>
</feed>