Difference between revisions of "Weapon.dat"

From GTAMods Wiki
Jump to navigation Jump to search
(expanded iii/vc)
Line 30: Line 30:
 
| <center>F</center> || <center>Amount of Ammunition</center> || integer || The number of ammo per clip
 
| <center>F</center> || <center>Amount of Ammunition</center> || integer || The number of ammo per clip
 
|-
 
|-
| <center>G</center> || <center>Damage</center> || integer || Damage done to damageable objects, damage done to characters are within the range of the value while to others are accurate to the value
+
| <center>G</center> || <center>Damage</center> || integer || Damage done to damageable objects; damage done to characters are within the range of the value while to others are accurate to the value
 
|-
 
|-
 
| <center>H</center> || <center>Speed</center> || float ||  
 
| <center>H</center> || <center>Speed</center> || float ||  
Line 44: Line 44:
 
| <center>O</center> || <center>Animation to Play</center> || string ||  
 
| <center>O</center> || <center>Animation to Play</center> || string ||  
 
|-
 
|-
| <center>W</center> || <center>Model ID</center> || integer ||  
+
| <center>P</center> || <center>Animation Loop Start</center> || float || Start point of animation to be looped for shooting
 
|-
 
|-
| <center>X</center> || <center>Model2 ID</center> || integer ||  
+
| <center>Q</center> || <center>Animation Loop End</center> || float || End point of animation to be looped for shooting
 +
|-
 +
| <center>R</center> || <center>Animation Fire Point</center> || float || Point in animation to fire weapon, value has to be between values in columns P and Q
 +
|-
 +
| <center>S</center> || <center>Animation2 Loop Start</center> || float ||
 +
|-
 +
| <center>T</center> || <center>Animation2 Loop End</center> || float ||
 +
|-
 +
| <center>U</center> || <center>Animation2 Fire Point</center> || float ||
 +
|-
 +
| <center>V</center> || <center>Breakout Animation</center> || float ||
 +
|-
 +
| <center>W</center> || <center>Model ID</center> || integer || [[IDE]] model of the weapon
 +
|-
 +
| <center>X</center> || <center>Model2 ID</center> || integer || IDE model of the weapon attachment, only Minigun model shows an effect
 
|-
 
|-
 
| <center>Y</center> || <center>Flags</center> || hex ||  
 
| <center>Y</center> || <center>Flags</center> || hex ||  

Revision as of 22:25, 23 January 2011

The weapon.dat is a file located in the data/ directory of all GTA games. The file contains information about the weapons properties and settings. The weapons themselfes are defined inside the default.ide file located in the same folder.

File format

This section is incomplete. You can help by fixing and expanding it.

GTA III & Vice City

This section is incomplete. You can help by fixing and expanding it.

GTA III Vice City Identifier Type Description
A
Weapon Name
string
B
Fire Type
string Available types include: MELEE, INSTANT_HIT, PROJECTILE, AREA_EFFECT, and CAMERA
C
Range
float The range of the bullet in units
D
Firing Rate
integer
E
Reload
integer The time to reload in milliseconds, constrained by the animation being played
F
Amount of Ammunition
integer The number of ammo per clip
G
Damage
integer Damage done to damageable objects; damage done to characters are within the range of the value while to others are accurate to the value
H
Speed
float
I
Radius
float
J
Life span
float
K
Spread
float
L,M,N
Fire Offset Vector
float[3] The x,y,z offset of the gunflash
O
Animation to Play
string
P
Animation Loop Start
float Start point of animation to be looped for shooting
Q
Animation Loop End
float End point of animation to be looped for shooting
R
Animation Fire Point
float Point in animation to fire weapon, value has to be between values in columns P and Q
S
Animation2 Loop Start
float
T
Animation2 Loop End
float
U
Animation2 Fire Point
float
V
Breakout Animation
float
W
Model ID
integer IDE model of the weapon
X
Model2 ID
integer IDE model of the weapon attachment, only Minigun model shows an effect
Y
Flags
hex
Z
Weapon Slot
integer 0: Fist
1: Melee
2: Thrown
3: Pistol
4: Shotgun
5: Submachine gun
6: Assault rifle
7: Heavy
8: Sniper rifle
9: Special

San Andreas

This section is incomplete. You can help by fixing and expanding it.

San Andreas knows two different weapon types. Each weapon can be only one of those types. It gets defined by the first character of a line and defines the whole lines structure. The types are:

  • < – Melee weapons
  • $ – Guns
Identifier Description
A The weapon type identifier (as descriped above).
B Fire type enumeration. Can be: MELEE, PROJECTILE (for uzis and pistols), INSTANT_HIT (for rifles), USE, AFFECT_AREA and CAMERA.
C The range a target can be aimed.
D The range of the bullets to cause damage.
E Model identifier of the primary weapon (defined inside the default.ide file).
F Model identifier of the secondary weapon (apparently unused, always -1).
G The time the primary weapon requires to be reloaded.
I The slot the weapon requires in the game.

Melee weapon parameters

This section is incomplete. You can help by fixing and expanding it.

Gun parameters

This section is incomplete. You can help by fixing and expanding it.

Weapon aiming offsets

This section is incomplete. You can help by fixing and expanding it.

GTA IV

This section is incomplete. You can help by fixing and expanding it.

See also