Weapons: Difference between revisions

From Multi Theft Auto: Wiki
Jump to navigation Jump to search
m (test)
No edit summary
(23 intermediate revisions by 14 users not shown)
Line 1: Line 1:
'''Scripting functions that ask for a weapon ID need an integer that refers to the GTASA weapon ID list. They are listed below.'''
Scripting functions that ask for a weapon ID need an integer that refers to the GTASA weapon ID list. They are listed below.
<br>
{{Note|
*''NOTE: GTASA [[Weapon_skill_levels|weapon stats]] will affect movement, accuracy, damage, and dual wield capability. See [[SetPedStat]] to change these stats. The MTA server comes with a resource called "defaultStats" that sets GTASA weapon stats to 999. See the weapon stats link for more info.''
*Clip size () denotes clip size when the weapon is dual wielded. Weapons without this specification are not dual wield weapons.
{|border="1" cellpadding="5" cellspacing="0" align="left"
*GTASA [[Weapon_skill_levels|weapon stats]] will affect movement, accuracy, damage, and dual wield capability. See [[setPedStat]] to change these stats. The default MTA server package comes with a resource called "defaultStats" that sets GTASA weapon stats to 999. See the weapon stats link for more info.
*For death reasons, especially in event handlers for onPlayerWasted or similar, also have a look at the [[Damage Types]].
*'''Name''' is compatible with functions [[getWeaponNameFromID]], [[getWeaponIDFromName]].
}}
{|class="wikitable sortable" style="text-align:center; margin: 1em auto 1em auto; border:1px solid black"
|-
|-
|
! Slot || class="unsortable" | Type || class="unsortable" | Image || Name || ID || class="unsortable" | Model ID || class="unsortable" | Clip || class="unsortable" | Sharing slot ammo
! scope="col" style="background:#efefef;" | Weapon
! scope="col" style="background:#efefef;" | ID
! scope="col" style="background:#efefef;" | Clip Size
! scope="col" style="background:#efefef;" | Dual?
! scope="col" style="background:#efefef;" | Model ID
|-
|-
! scope="row" style="background:#efefef;" | Slot 0: No Weapon
! rowspan="2" | 0
|Fist
! rowspan="2" | Hand
|0
| [[Image:Fist.png]] || align="left" | Fist || 0 || - || -
|N/A
| rowspan="2" | -
|No
|N/A
|-
|-
! scope="row" style="background:#efefef;" |
| [[Image:Knuckle.png]] || align="left" | Brassknuckle || 1 || 331 || -
|Brass Knuckles
|1
|N/A
|No
|331
|-
|-
! scope="row" style="background:#efefef;" | Slot 1: Melee
! rowspan="8" | 1
|Golf Club
! rowspan="8" | Melee
|2
| [[Image:Golfclub.png]] || align="left" | Golfclub || 2 || 333 || -
|N/A
| rowspan="8" | -
|No
|333
|-
|-
! scope="row" style="background:#efefef;" |
| [[Image:Nitestik.png]] || align="left" | Nightstick || 3 || 334 || -
|Nightstick
|3
|N/A
|No
|334
|-
|-
! scope="row" style="background:#efefef;" |
| [[Image:Knife.png]] || align="left" | Knife || 4 || 335 || -
|Knife 
|4
|N/A
|No
|335
|-
|-
! scope="row" style="background:#efefef;" |
| [[Image:Bat.png]] || align="left" | Bat || 5 || 336 || -
|Baseball Bat
|5
|N/A
|No
|336
|-
|-
! scope="row" style="background:#efefef;" |
| [[Image:Shovel.png]] || align="left" | Shovel || 6 || 337 || -
|Shovel
|6
|N/A
|No
|337
|-
|-
! scope="row" style="background:#efefef;" |
| [[Image:Poolcue.png]] || align="left" | Poolstick || 7 || 338 || -
|Pool Cue
|7
|N/A
|No
|338
|-
|-
! scope="row" style="background:#efefef;" |
| [[Image:Katana.png]] || align="left" | Katana || 8 || 339 || -
|Katana
|8
|N/A
|No
|339
|-
|-
! scope="row" style="background:#efefef;" |
| [[Image:Saw.png]] || align="left" | Chainsaw || 9 || 341 || -
|Chainsaw
|9
|N/A
|No
|341
|-
|-
! scope="row" style="background:#efefef;" | Slot 2: Handguns
! rowspan="3" | 2
|
! rowspan="3" | Handguns
|
| [[Image:Colt45.png]] || align="left" | Colt 45 || 22 || 346 || 17 (34)
|
| rowspan="3" | '''No'''<br/>''Replacing handgun resets slot 2 ammo''
|
|
|-
|-
! scope="row" style="background:#efefef;" | Slot 3: Shotguns
| [[Image:Silenced.png]] || align="left" | Silenced || 23 || 347 || 17
|
|
|
|
|
|-
|-
! scope="row" style="background:#efefef;" | Slot 4: Sub-Machine Guns
| [[Image:Deagle.png]] || align="left" | Deagle || 24 || 348 || 7
|
|
|
|
|
|-
|-
! scope="row" style="background:#efefef;" | Slot 5: Assault Rifles
! rowspan="3" | 3
|
! rowspan="3" | Shotguns
|
| [[Image:Shotgun.png]] || align="left" | Shotgun || 25 || 349 || 1
|
| rowspan="3" | Yes
|
|
|-
|-
! scope="row" style="background:#efefef;" | Slot 6: Rifles
| [[Image:Sawnoff.png]] || align="left" | Sawed-off || 26 || 350 || 2 (4)
|
|
|
|
|
|-
|-
! scope="row" style="background:#efefef;" | Slot 7: Heavy Weapons
| [[Image:Spas12.png]] || align="left" | Combat Shotgun || 27 || 351 || 7
|
|
|
|
|
|-
|-
! scope="row" style="background:#efefef;" | Slot 8: Projectiles
! rowspan="3" | 4
|
! rowspan="3" | Sub-Machine Guns
|
| [[Image:Mac10.png]] || align="left" | Uzi || 28 || 352 || 50 (100)
|
| rowspan="3" | Yes
|
|
|-
|-
! scope="row" style="background:#efefef;" | Slot 9: Special 1
| [[Image:Mp5.png]] || align="left" | MP5 || 29 || 353 || 30
|
|
|
|
|
|-
|-
! scope="row" style="background:#efefef;" | Slot 10: Gifts/Other
| [[Image:Tec9.png]] || align="left" | Tec-9 || 32 || 372 || 50 (100)
|
|
|
|
|
|-
|-
! scope="row" style="background:#efefef;" | Slot 11: Special 2
! rowspan="2" | 5
|
! rowspan="2" | Assault Rifles
|
| [[Image:Ak47.png]] || align="left" | AK-47 || 30 || 355 || 30
|
| rowspan="2" | Yes
|
|
|-
|-
! scope="row" style="background:#efefef;" | Slot 12: Satchel Detonator
| [[Image:M4.png]] || align="left" | M4 || 31 || 356 || 50
|
|-
|
! rowspan="2" | 6
|
! rowspan="2" | Rifles
|
| [[Image:Rifle.png]] || align="left" | Rifle || 33 || 357 || 1
|
| rowspan="2" | '''No'''<br/>''Replacing rifle resets slot 6 ammo''
|-
| [[Image:Sniper.png]] || align="left" | Sniper || 34 || 358 || 1
|-
! rowspan="4" | 7
! rowspan="4" | Heavy Weapons
| [[Image:Rocketla.png]] || align="left" | Rocket Launcher || 35 || 359 || 1
| rowspan="4" | '''No'''<br/>''Replacing heavy weapon resets slot 7 ammo''
|-
| [[Image:Heatseek.png]] || align="left" | Rocket Launcher HS || 36 || 360 || 1
|-
| [[Image:Flame.png]] || align="left" | Flamethrower || 37 || 361 || 50
|-
| [[Image:Minigun.png]] || align="left" | Minigun || 38 || 362 || 500
|-
! rowspan="4" | 8
! rowspan="4" | Projectiles
| [[Image:Grenade.png]] || align="left" | Grenade || 16 || 342 || 1
| rowspan="4" | '''No'''<br/>''Replacing projectile resets slot 8 ammo''
|-
| [[Image:Teargas.png]] || align="left" | Teargas || 17 || 343 || 1
|-
| [[Image:Molotov.png]] || align="left" | Molotov || 18 || 344 || 1
|-
| [[Image:Satchel.png]] || align="left" | Satchel || 39 || 363 || 1
|-
! rowspan="3" | 9
! rowspan="3" | Special 1
| [[Image:Spraycan.png]] || align="left" | Spraycan || 41 || 365 || 500
| rowspan="3" | '''No'''<br/>''Replacing slot 9 weapon resets slot 9 ammo''
|-
| [[Image:Fire_ex.png]] || align="left" | Fire Extinguisher || 42 || 366 || 500
|-
| [[Image:Camera.png]] || align="left" | Camera || 43 || 367 || 36
|-
! rowspan="5" | 10
! rowspan="5" | Gifts
| [[Image:Dildo1.png]] || align="left" | Dildo || 10 || 321 || -
| rowspan="5" | -
|-
| [[Image:Dildo2.png]] || align="left" | Dildo || 11 || 322 || -
|-
| [[Image:Vibe1.png]] || align="left" | Vibrator || 12 || 323 || -
|-
| [[Image:Flowers.png]] || align="left" | Flower || 14 || 325 || -
|-
| [[Image:Cane.png]] || align="left" | Cane || 15 || 326 || -
|-
! rowspan="3" | 11
! rowspan="3" | Special 2
| [[Image:Irgoggle.png]] || align="left" | Nightvision || 44 || 368 || -
| rowspan="3" | -
|-
| [[Image:Irgoggle.png]] || align="left" | Infrared || 45 || 369 || -
|-
| [[Image:Paracute.png]] || align="left" | Parachute || 46 || 371 || -
|-
! rowspan="1" | 12
! rowspan="1" | Satchel Detonator
| [[Image:Bomb.png]] || align="left" | Bomb || 40 || 364 || -
| rowspan="1" | -
|}
|}
==Client Functions==
{{Client_weapon_functions}}
==Server Function==
{{Weapon functions}}
[[Category:ID Lists]]
[[hu:Weapons]]
[[it:Armi]]
[[ru:Weapons]]
[[de:Waffen]]
[[pl:Weapons]]

Revision as of 22:04, 5 December 2018

Scripting functions that ask for a weapon ID need an integer that refers to the GTASA weapon ID list. They are listed below.

[[{{{image}}}|link=|]] Note:
  • Clip size () denotes clip size when the weapon is dual wielded. Weapons without this specification are not dual wield weapons.
  • GTASA weapon stats will affect movement, accuracy, damage, and dual wield capability. See setPedStat to change these stats. The default MTA server package comes with a resource called "defaultStats" that sets GTASA weapon stats to 999. See the weapon stats link for more info.
  • For death reasons, especially in event handlers for onPlayerWasted or similar, also have a look at the Damage Types.
  • Name is compatible with functions getWeaponNameFromID, getWeaponIDFromName.
Slot Type Image Name ID Model ID Clip Sharing slot ammo
0 Hand Fist.png Fist 0 - - -
Knuckle.png Brassknuckle 1 331 -
1 Melee Golfclub.png Golfclub 2 333 - -
Nitestik.png Nightstick 3 334 -
Knife.png Knife 4 335 -
Bat.png Bat 5 336 -
Shovel.png Shovel 6 337 -
Poolcue.png Poolstick 7 338 -
Katana.png Katana 8 339 -
Saw.png Chainsaw 9 341 -
2 Handguns Colt45.png Colt 45 22 346 17 (34) No
Replacing handgun resets slot 2 ammo
Silenced.png Silenced 23 347 17
Deagle.png Deagle 24 348 7
3 Shotguns Shotgun.png Shotgun 25 349 1 Yes
Sawnoff.png Sawed-off 26 350 2 (4)
Spas12.png Combat Shotgun 27 351 7
4 Sub-Machine Guns Mac10.png Uzi 28 352 50 (100) Yes
Mp5.png MP5 29 353 30
Tec9.png Tec-9 32 372 50 (100)
5 Assault Rifles Ak47.png AK-47 30 355 30 Yes
M4.png M4 31 356 50
6 Rifles Rifle.png Rifle 33 357 1 No
Replacing rifle resets slot 6 ammo
Sniper.png Sniper 34 358 1
7 Heavy Weapons Rocketla.png Rocket Launcher 35 359 1 No
Replacing heavy weapon resets slot 7 ammo
Heatseek.png Rocket Launcher HS 36 360 1
Flame.png Flamethrower 37 361 50
Minigun.png Minigun 38 362 500
8 Projectiles Grenade.png Grenade 16 342 1 No
Replacing projectile resets slot 8 ammo
Teargas.png Teargas 17 343 1
Molotov.png Molotov 18 344 1
Satchel.png Satchel 39 363 1
9 Special 1 Spraycan.png Spraycan 41 365 500 No
Replacing slot 9 weapon resets slot 9 ammo
Fire ex.png Fire Extinguisher 42 366 500
Camera.png Camera 43 367 36
10 Gifts Dildo1.png Dildo 10 321 - -
Dildo2.png Dildo 11 322 -
Vibe1.png Vibrator 12 323 -
Flowers.png Flower 14 325 -
Cane.png Cane 15 326 -
11 Special 2 Irgoggle.png Nightvision 44 368 - -
Irgoggle.png Infrared 45 369 -
Paracute.png Parachute 46 371 -
12 Satchel Detonator Bomb.png Bomb 40 364 - -

Client Functions


Server Function