Weapon
A weapon is anything that can damage other objects, including vehicles and pedestrians. It is one of the core gameplay features of Grand Theft Auto.
Contents
Mission script
Opcodes
0113 | adds ammo to the player's weapon | |
0114 | adds ammo to the character's weapon | |
017A | sets the player's weapon ammo | |
017B | sets the character's weapon ammo | |
01B1 | gives the weapon to the player | |
01B2 | gives the weapon to the character | |
01B8 | sets the current weapon of the player | |
01B9 | sets the current weapon of the character | |
0213 | creates a pickup with predefined ammo | |
0237 | sets the gang's weapons | |
02D7 | checks the current weapon of the player | |
02D8 | checks the current weapon of the character | |
02E2 | sets the character's weapon accuracy | |
031D | checks if the character is damaged by the weapon | |
031E | checks if the vehicle is damaged by the weapon | |
032B | creates a pickup with ammo | |
0419 | gets the ammo of the player's weapon | |
041A | gets the ammo of the character's weapon | |
0467 | clears the character's last weapon damage | |
0468 | clears the vehicle's last weapon damage | |
046F | gets the player's current weapon | |
0470 | gets the character's current weapon | |
048F | removes all of the character's weapons | |
0490 | checks if the player has the weapon | |
0491 | checks if the character has the weapon | |
04B8 | gets the character's weapon data | |
0501 | sets player can do drive by | |
0555 | removes the weapon from the character | |
0563 | ensures player has a drive-by weapon | |
06AB | hides all weapons | |
0713 | makes the character do drive bys | |
081A | sets the character's weapon skill | |
087E | sets the character to drop weapons after a death | |
0881 | sets the character be able to shoot | |
0946 | sets the character oblivious to weapon fire | |
0992 | sets the player's ability to scroll through weapons |
Native functions
- GET_AMMO_IN_CHAR_WEAPON
- GET_CHAR_WEAPON_IN_SLOT
- GET_CURRENT_CHAR_WEAPON
- GET_WEAPONTYPE_MODEL
- GET_WEAPONTYPE_SLOT
- GIVE_WEAPON_TO_CHAR
This section is incomplete. You can help by fixing and expanding it.
Lists of Weapons
GTA III
Unlike in Vice City and San Andreas, where each weapon has a separate mesh and texture, GTA3's weapons are stored in a single DFF and TXD file, namely weapons.dff
and generic.txd
; only the selected object from the model hierarchy, e.g. pistol or Uzi is visible when the player chooses a weapon. Most of the information on the weapons are located in the weapon.dat
file.
Vice City
Vice City is the first GTA that lets you replace a weapon of the same type. Most of the information on the weapons are located in the weapon.dat
file. Information on melee combat is located in the melee.dat
file. The textures and models of the weapons are located in the gta3.img
file. The HUD icon of the first is located in the hud.txd
file.
Type | Enum | Name | Model index |
Model name |
Icon | Slot |
---|---|---|---|---|---|---|
0 | WEAPONTYPE_ |
Unarmed | 0 | |||
1 | WEAPONTYPE_ |
Brass Knuckle | 259 | brassknuckle | 0 | |
2 | WEAPONTYPE_ |
Screw Driver | 260 | screwdriver | 1 | |
3 | WEAPONTYPE_ |
Golf Club | 261 | golfclub | 1 | |
4 | WEAPONTYPE_ |
Night Stick | 262 | nitestick | 1 | |
5 | WEAPONTYPE_ |
Knife | 263 | knifecur | 1 | |
6 | WEAPONTYPE_ |
Baseball Bat | 264 | bat | 1 | |
7 | WEAPONTYPE_ |
Hammer | 265 | hammer | 1 | |
8 | WEAPONTYPE_ |
Cleaver | 266 | cleaver | 1 | |
9 | WEAPONTYPE_ |
Machete | 267 | machete | 1 | |
10 | WEAPONTYPE_ |
Katana | 268 | katana | 1 | |
11 | WEAPONTYPE_ |
Chainsaw | 269 | chnsaw | 1 | |
12 | WEAPONTYPE_ |
Grenade | 270 | grenade | 2 | |
13 | WEAPONTYPE_ |
Remote Detonator | 291 | bomb | 2 | |
14 | WEAPONTYPE_ |
Tear Gas | 271 | teargas | 2 | |
15 | WEAPONTYPE_ |
Molotov | 272 | molotov | 2 | |
16 | WEAPONTYPE_ |
Missile | 273 | missile | - | 2 |
17 | WEAPONTYPE_ |
Colt .45 (Pistol) | 274 | colt45 | 3 | |
18 | WEAPONTYPE_ |
Python (.357) | 275 | python | 3 | |
19 | WEAPONTYPE_ |
Chrome Shotgun | 277 | chromegun | 4 | |
20 | WEAPONTYPE_ |
Spaz Shotgun (S.P.A.S. 12) | 278 | shotgspa | 4 | |
21 | WEAPONTYPE_ |
Stubby Shotgun | 279 | buddyshot | 4 | |
22 | WEAPONTYPE_ |
Tec-9 | 281 | tec9 | 5 | |
23 | WEAPONTYPE_ |
Uzi 9mm (Uz-I) | 282 | uzi | 5 | |
24 | WEAPONTYPE_ |
Ingram Mac 10 | 283 | ingramsl | 5 | |
25 | WEAPONTYPE_ |
MP5 (MP) | 284 | mp5lng | 5 | |
26 | WEAPONTYPE_ |
M4 | 280 | m4 | 6 | |
27 | WEAPONTYPE_ |
Ruger (Kruger) | 276 | ruger | 6 | |
28 | WEAPONTYPE_ |
Sniper Rifle | 285 | sniper | 8 | |
29 | WEAPONTYPE_ |
PSG-1 (.308 Sniper) | 286 | laser | 8 | |
30 | WEAPONTYPE_ |
Rocket Launcher | 287 | rocketla | 7 | |
31 | WEAPONTYPE_ |
Flame Thrower | 288 | flame | 7 | |
32 | WEAPONTYPE_ |
M60 | 289 | m60 | 7 | |
33 | WEAPONTYPE_ |
Minigun | 290 | minigun | 7 | |
34 | WEAPONTYPE_ |
Detonator | 9 | |||
35 | WEAPONTYPE_ |
HeliCanon | - | 7 | ||
36 | WEAPONTYPE_ |
Camera | 292 | camera | 9 |
San Andreas
San Andreas is the first GTA that lets you dual wield weapons. Information on weapons, melee combat, textures, and models are located in the same files as in Vice City.
GTA IV
Main article: List of Weapons (GTA4)
External links
- http://www.gtavice.com/weapons/
- http://www.gtasanandreas.net/weapons/
- GTAForums: Generic SA SCM Documentation
Grand Theft Auto IV | |
---|---|
File Formats | .dat • .gxt • .ide • .img • .ipl • .nod • .sco • .rpf • .rrr • .wad • .wbd/.wbn • .wdd • .wdr • .wft • .whm • .wpl • .wtd |
Documentation | Audio • Bink Video • Cryptography • Cutscenes • GXT Text • Image listing • Keycodes • Map Listing • Native functions • Paths • Radar Blips • Radio Stations • Saves • Scenarios • VTable • Weapons |
Tools | ASI Loader • ENBSeries • G-Texture • GIMS IV • Ingame WPL Editor • IV Needle • OpenIV • SparkIV • XLiveLess • WPL Manager • X Mod Installer Alice • C++ Script Hook • .NET Script Hook • Scocl |
Tutorials | Importing Textures with OpenIV • Importing Textures with SparkIV |
Modifications | GTA Connected • Gostown IV • Four Multiplayer • IV Multiplayer • CitizenMP:IV Reloaded |
Useful links | Community portal • Discussion forums • Modding forums • Mods on GTAGarage.com |