weapon.dat
File Formats
Fil_weapondat.html

Name

weapon.dat - contains weapon stats (Fire type, rate, reload...)

Location

data\weapon.dat

Description

Weapon.dat contains information pertaining to how the weapons in the game work, such as how powerfull they are amount of rounds in a clip ect. Each weapon has 23 parameters.

Parameters

A B C D E F G H I J K L M N O P Q R S T U V W

First I'll list the parameter descriptions how they appear in weapon.dat, then I'll go over each parameter more thoroughly.

#   A: Weapon name
#   B: Fire type
#       C: Range
#   D: Firing Rate
#   E: Reload
#   F: Amount of Ammunition
#   G: Damage
#   H: Speed
#   I: Radius
#   J: Life span
#   K: Spread
#   L,M,N: Fire offset vector
#   P: animation to play
#   Q: animation to play
#   R: animation loop start
#   S: animation loop end
#   T: point in animation where weapon is fired
#   U: point in animation 2 where weapon is fired
#   V: model id
#   W: Flags -> 1:USE_GRAVITY  2:SLOWS_DOWN  4:DISSIPATES  8:RAND_SPEED  16:EXPANDS  
#   32:EXPLODES  64:CANAIM 128:CANAIM_WITHARM  256:1ST_PERSON  512:HEAVY  1024:THROW

A - Weapon name:


Unarmed
BaseballBat
Colt45
Uzi
Shotgun
Grenade
Molotov
RocketLauncher
FlameThrower
AK47
M16
SniperRifle
Detonator

B - Fire type:


MELEE used for unarmed and the baseball bat
INSTANT_HIT simply means a bullet based gun
PROJECTILE anything that is thrown, the grenade and molotov, the rocketlauncher and detonator also use this fire type
AREA_EFFECT only used for the flame thrower it's used to create a spread affect

C - Range, it seemes to be a percentage of distance as the sniperrifle has a range of 100 and a basebalbat a range of 1.5.

D - Firing Rate, the delay between shots. The smaller the number the shorter the delay.

E - Reload, the time in ms it takes to reload.

F - Amount of Ammunition, how many rounds are in each clip.

G - Damage, how powerfull each round is.

H - Speed, how fast a round gets to its target.

I - Radius, melee weapons and the flamethrower use this all other weapons use -1.0.

J - Life span, used with projectiles as a fuse such as the delay before a grenade goes off.

K - Spread, the size of the area that an explosion or fire affects.

L,M,N - Fire offset vector, how unacurate a weapon can be give or take from your aiming:


L or x which is horizontally
M or y which is verticaly
N or z which is the the round not going as far or going further than its range

P,Q - animations to play:


BaseballBat
WEAPON_bat_h - the normal bat animation used by the player and other peds
WEAPON_bat_v - animation used by the player when hiting someone on the ground
Colt45
WEAPON_hgun_body - the normal handgun animation used by the player and other peds
RBLOCK_Cshoot - the animation used by cop peds when at a road block neeling and shooting
Uzi
WEAPON_hgun_body - the normal handgun animation used by the player and other peds
null - no second animation is used with the uzi
Shotgun
WEAPON_pump - the normal shotgun animation used by the player and other peds
null - no second animation is used with the shotgun
Grenade
WEAPON_start_throw - the animation used when the player is bending back preparing to throw
WEAPON_throw - the animation used when the player throwing
Molotov
WEAPON_start_throw - the animation used when the player is bending back preparing to throw
WEAPON_throw - the animation used when the player throwing
RocketLauncher
WEAPON_sniper - no animation is shown when in first person mode
null - no second animation is used with the rocketlauncher
FlameThrower
WEAPON_pump - the flame thrower uses the shoot gun animation
null - no second animation is used with the flamethrower
AK47
WEAPON_AK_body - the normal rifle animation used by the player and other peds
null - no second animation is used with the ak47
M16
WEAPON_AK_body - the normal rifle animation used by the player and other peds
null - no second animation is used with the m16
SniperRifle
WEAPON_sniper - no animation is shown when in first person mode
null - no second animation is used with the sniperrifle
Detonator
bomber - the animation used when the player is triggering a car bomb with the remote
null - no second animation is used with the detonator

R - animation loop start, were to start the animation loop when firing an automatic weapon.

S - animation loop end, were to end the animation lood when firing an automatic weapon.

T - point in animation where weapon is fired.

U - point in animation 2 where weapon is fired.

V - model id, the weapons model ID in default.ide

W - Flags:


1:USE_GRAVITY
2:SLOWS_DOWN
4:DISSIPATES
8:RAND_SPEED
16:EXPANDS
32:EXPLODES
64:CANAIM
128:CANAIM_WITHARM
256:1ST_PERSON
512:HEAVY
1024:THROW

Examples

Uzi INSTANT_HIT 30.0 250 500 25 20 -1.0 -1.0 -1.0 -1.0 0.30 -0.05 0.11 WEAPON_hgun_body null 8 11 9 9 178 192

M16 INSTANT_HIT 75.0 1 1000 60 52 -1.0 -1.0 -1.0 -1.0 0.83 -0.06 0.14 WEAPON_AK_body null 12 13 12 0 180 64

SniperRifle INSTANT_HIT 100.0 500 1401 1 125 -1.0 -1.0 -1.0 -1.0 0.0 0.66 0.05 WEAPON_sniper null 0 10 3 0 177 256

To Do

More reseach and testing has to be done in general.

Author

dElAvA

See Also

-

Programs

WSE

File Formats

Last change: 25 July 2002

unofficial GTA III Reference