Page tree
Skip to end of metadata
Go to start of metadata

Weapons are one of the key parts of the engine. Without weapons you can't shoot things. Weapons here aren't just limited to infantry carried weapons, vehicles also use these too.

Style---The weapon's holding style in third person. More details can be found below.
The weapon's third person model. Usually this is in the form of w_<weap>.w3d
The model used for when the weapon is on the third person model's back. Usually this is in the form of w_<weap>_b.w3d
SwitchTime1.000How long it takes to swap to and from this weapon, in seconds.

How long it takes to reload the weapon, in seconds.

PerBulletReload note: if this option is enabled,then this is how long it takes to do one reload cycle)

KeyNumber0.000What number key is used to select the weapon.
CanSnipefalseDoes this weapon have a sniper scope?
EjectVelocity2.000The velocity of the ejected bullet casing
EjectRandomness0.000How random the ejected casing velocity is, plus or minus this number.
EjectTime0.000How long after firing is a casing ejected
Opens a window that allows you to define the casing model and such. More details are found below.
EjectIsShotgunShellfalseWhen the casing is ejected, will it make shotgun shell sounds (defined in SurfaceEffects.ini under <surface>_Shell Shotgun) when it hits the ground?
Allows you to define a model for the muzzle flash.
The model used for the first person view. NOTE: This must be named in the format F_GM_<WEAP>, and there are further dependencies. See <tbd> for more information on view models.
FirstPersonOffset0.000,0.000,0.000The 3d offset of the first person view model.
RecoilImpulse0.000How much force will this weapon impart on the user when it fires.

What sound is played when the weapon is reloaded

PerBulletReload note: if this is enabled, the reload sound will be played every reload cycle

What sound is played when the player tries to fire, but the weapon has no bullets (and can't reload).
What sound is played when the player selects this weapon?
What sound is played when the player deselects this weapon?
What does the weapon fire on a left click. Links to an Ammo definition. Required.
What does the weapon fire on a right click. Links to an Ammo definition. This isn't required.
PrimaryFireMuzzleSetEditorAWhich set of barrels does the primary fire come out of? (E.g MuzzleA, MuzzleB, etc. Put the letter of the muzzle set in)
SecondaryFireMuzzleSetEditorBWhich set of barrels does the secondary fire come out of? (E.g MuzzleA, MuzzleB, etc. Put the letter of the muzzle set in)
BypassSameAmmoMuzzleSelectLogicfalseIf a weapon has the same ammo set for both primary and secondary, then by default the code will automatically default to ignoring the secondary muzzle set. Set this to make the code instead use both sets of muzzles based on primary/secondary fire, rather than just using the same muzzle.
ClipSize0How many bullets does the weapon hold in one clip? -1 means the weapon can shoot infinitely with no reloading.
MaxInventoryRounds100How many bullets can the weapon hold to reload with. -1 means infinite reloads.
RecoilTime0.1How long will the gun's visual recoil take? For this, the muzzle on vehicles will recoil, and the character's arms and such will recoil.
RecoilScale1.0How far will the gun recoil? For this, the muzzle on vehicles will recoil, and the character's arms and such will recoil.

Will this weapon be granted to the player if the function SoldierGameObj::Give_All_Weapons is called?

If the Allweapons console command is used and this is ticked, then this weapon will be given to the client the command points to.

What string is displayed in the hud in the weapon's information area?
What icon is the weapon using.
Where on the IconTextureName texture is the icon? X1 is left, X2 is right, Y1 is top, Y2 is bottom.
How far is the icon offset from it's default position?
What animation does the character use when they are firing this weapon?

If the weapon has a scope, what texture is used for the scope?

UniformScopefalseWill the scope texture be stretched to match the aspect ratio?
MaxZoom0How far in can the scope zoom?
MinZoom0What's the most zoomed out the scope can be?
This sound will be played across the map when the weapon is fired.
AreaEffectWeaponfalseDoes this weapon do AOE damage instead of firing a bullet?
AreaEffectWeaponAffectOwnerfalseDoes the AOE damage effect the owner?
AreaEffectWeaponAffectFriendlytrueDoes the AOE damage effect friendlies?
AreaEffectWeaponAffectEnemytrueDoes the AOE damage effect enemies?
AreaEffectWeaponAffectNeutraltrueDoes the AOE damage effect neutral objects?
SprayAddWalking0How much spray does jumping add to the weapon?
SprayAddWounded0How much spray does being wounded add to the weapon?
SprayAddWalking0How much spray does walking add to the weapon? (Note, this isn't running.)
SprayAddCrouching0How much spray does being crouched add to the weapon?
SprayAddSprinting0How much spray does sprinting add to the weapon?
Accuracy Recovery Rate (Movement) (deg/sec)0.573How much does the spray reduce each second?
Accuracy Recovery Rate (Weapon) (deg/sec)-57.296How much does the weapon's spray bloom get reduced by each second?

Always true.


Each reload adds a single bullet to the magazine.

If this is ticked, the weapon will reload to full, reloading one bullet (or more) at a time. Read the end of the document to find out how exactly this works, as there's a lot to it.

BulletsPerPBReload1How many bullets are added to the magazine per reload cycle, if PerBulletReload is enabled.
PBReloadStartTime0How much extra time is added to the reload if this is the start of the reload?
PBReloadEndTime0How much time does the end of the reload (after the magazine is filled with bullets) take?
PBReloadLoopFrame0What frame of the first person animation does the first person reload animation loop to?
What sound does the weapon play at the end of the reload, while it's finishing.

DoTiltWhileReloadingtrueDoes the third person model tilt down while reloading?
AllowEmptyShotsfalseCan this weapon fire when the ammo is empty?
HideWhenEmptytrueCan this weapon be selected if it's got no ammo?
IsCooldownAbilityfalseDghelneshi would be best to explain this.
IsQuickCastAbilityfalseDghelneshi would be best to explain this.
AutoSwitchOnFirefalseDghelneshi would be best to explain this.
AutoSwitchDelay0.2Dghelneshi would be best to explain this.
DelayedChargeFirefalseDghelneshi would be best to explain this.

What pattern does the recoil use?

Circle - Will go in a 360 direction around the aim point.

Arc - Will go in a slice, with the direction in the RecoilBias direction.

RecoilSize0How big is the recoil?
RecoilBias0,0.What direction is the recoil? This is an X,Y axis.
RecoilRandProb0How often will the recoil go in a truly random direction instead of the RecoilPhysBias direction?
RecoilArcSize0How wide the arc of the "Arc" recoil pattern is, in degrees.
RecoilResist0How well can the recoil be "resisted" by the weapon. This reduces the effect of recoil, but doesn't reset the weapon when done firing.
RecoilResistMulJumping1Modifies the recoil resistance. Values greater than one make it worse, less than 1 make it better.

RecoilRecovery0This controls how quickly the weapon will return to it's original aim point.
RecoilFirstShotMultiplier1How much is the recoil strength multiplied on the first shot?
RecoilAimpointStaticfalseIf this is enabled, then when the recoil hits the edge of the recoil range, then it will not travel any further. If disabled, this will continue to move the weapon up and shift the original aimpoint up as well.

If enabled, the weapon will spin up/down when firing, like a minigun. There are bones associated with this. (Check in Vehicle/Weapon rigging pages)

GattlingWarmUpTime1.0How long does the weapon take to spin up?
GattlingWarmDownMultiplier1.0This controls how long it takes the weapon to spin back down after stopping. If Warm up time is 1.0 and the Warm down multiplier is 0.5, then the weapon will take 2 seconds to spin down. If it is 2.0, then the weapon will take half a second to spin down.
GatlingMinimumContSoundPitch1.0What is the pitch of the ContinuousMotorSound when the gun is starting to spin?
GatlingMaximumContSoundPitch1.0What is the pitch of the ContinuousMotorSound when the gun is at full speed?
GatlingCannotFireWhileWarmingUpfalseCan the weapon fire while it's still spinning up to max RPM? (A Yuri's Revengesque Gatling weapon would be set to false, while a generic gatling from most other games would be set to true.)
GatlingSpinningStopsDuringReloadfalseDoes the weapon spin down during the reload process?

Controls what sound is playing when the gatling motor is spinning. This plays even if the weapon is not firing.

  • No labels