Weapon.dat
From Liberty Unleashed Wiki
(Difference between revisions)
m |
|||
Line 1: | Line 1: | ||
− | {{ | + | {{GTADataFiles|weapon.dat}} |
'''''weapon.dat''''' is a GTA data file which controls the behaviour of the weapons in the game. This file is used in GTA III, GTA:VC and GTA:SA. Liberty Unleashed (as well as Vice Unleashed) allows you to load a customised ''weapon.dat'' which will be shared for all clients upon connecting. It is also possible to modify most of these values run-time using the built-in [[Squirrel/Server/Functions#Weapon_Functions|weapon scripting functions]]. | '''''weapon.dat''''' is a GTA data file which controls the behaviour of the weapons in the game. This file is used in GTA III, GTA:VC and GTA:SA. Liberty Unleashed (as well as Vice Unleashed) allows you to load a customised ''weapon.dat'' which will be shared for all clients upon connecting. It is also possible to modify most of these values run-time using the built-in [[Squirrel/Server/Functions#Weapon_Functions|weapon scripting functions]]. | ||
Revision as of 04:26, 28 September 2010
weapon.dat is a GTA data file which controls the behaviour of the weapons in the game. This file is used in GTA III, GTA:VC and GTA:SA. Liberty Unleashed (as well as Vice Unleashed) allows you to load a customised weapon.dat which will be shared for all clients upon connecting. It is also possible to modify most of these values run-time using the built-in weapon scripting functions.
This page explains the entries in weapon.dat briefly. For more info and suggested values, refer back to the original weapon.dat.
Column | Script Constant | Description | Notes |
---|---|---|---|
A | - | Weapon name | Cannot be set via scripts |
B | WEAPONINFO_FIRETYPE | Fire type of the weapon | - |
C | WEAPONINFO_RANGE | Fire range (aka how far does the weapon reach) (float) | - |
D | WEAPONINFO_FIRERATE | How fast does this weapon fire (int) | - |
E | WEAPONINFO_RELOAD | Reload time (int) | - |
F | WEAPONINFO_CLIPAMMO | Amount of ammunition one clip can carry (int) | - |
G | WEAPONINFO_DAMAGE | Damage caused by a hit from the weapon (int) | - |
H | WEAPONINFO_SPEED | Projectile speed (float) | -1.0 for infinite speed |
I | WEAPONINFO_RADIUS | The effect radius from the player (float) | -1.0 for normal weapons, different for melee |
J | WEAPONINFO_LIFESPAN | Life span of the projectiles (float) | -1.0 for bullets/non-projectile weapons |
K | WEAPONINFO_SPREAD | Projectile spread when exploded (float) | -1.0 for non-projectile weapons |
L, M, N | WEAPONINFO_FIREOFFSET | Offset vector for bullets (Vector) | - |
P | - | Animation 1 | Cannot be set via scripts |
Q | - | Animation 2 | Cannot be set via scripts |
R | - | Animation loop start | Cannot be set via scripts |
S | - | Animation loop end | Cannot be set via scripts |
T | - | Point in animation where weapon is fired | Cannot be set via scripts |
U | - | Point in animation 2 where weapon is fired | Cannot be set via scripts |
V | WEAPONINFO_MODELID | Weapon model ID (int) | - |
W | WEAPONINFO_FLAGS | Weapon model ID (hex int) | Refer back to weapon.dat for values |
X | - | 1st person version of animation | Not used in GTA III |
Y | - | 1st person version of animation 2 | Not used in GTA III |