Let i be the loop counter such that i = 1 in the first iteration, i = 2 in the second iteration, and so on. The loop is the meat of the bullet spread physics. The effect of these is that the damage will usually be accumulated and then actually inflicted, rather than inflicted for each bullet. Once it exits the loop, it does an apply operation. It then enters a loop that spreads and adds or accumulates the damage that will be inflicted due to each of the n B bullets. At a higher level, the function begins by doing a clear on the currently accumulated damage and sets the accumulated damage type to DMG_BULLET | DMG_NEVERGIB. This function uses the multidamage mechanism described in Damage system. Of concern to us are the spread vector Ω ∈ R 3, the source of line trace a, the aiming direction d, the range ℓ of the weapon, the bullet type, and the shared RNG “seed” σ. This function also accepts several other obvious arguments. In all other weapons that have bullet spreads, 1 is always passed in, because those weapons fire one bullet at a given time. For example, the shotgun (see Shotgun) in primary mode would pass 6 for this argument. One of the arguments to this function is the number of bullets n B. The spread of the bullets when fired by the player is computed in CBaseEntity::FireBulletsPlayer. In particular, if in a TAS the player loads from a savestate and fires a weapon with bullet spread in some fixed n-th frame, then the spread of the bullets will not change if the savestate is loaded again and the same actions are repeated. However, bullets fired by the player rely only on the shared RNG, which we have concluded in Shared RNG that it is wholly predictable and non-random. The deviation appears to be random and unpredictable to a casual player. The amount of deviation depends on the weapon.
The heat shield obtained when acquiring the Double Shot upgrade appears to resemble the SPAS-12 from Half Life 2.The bullets of some weapons in Half-Life have a spread that cause them to deviate from the target slightly.The weapon's hologram inside the Combine Fabricator appears to have the Double Shot upgrade by default, even if the player has not installed it.When fired, the grenade shoots off in an arc and does not consume ammo, detonating on impact. Adds a muzzle attachment that fits a Combine grenade. Holds up to six extra rounds, in addition to the rounds held within the magazine, allowing for an effective maximum of 12+1 available rounds. Adds a mechanical reservoir to the side of the weapon for rapidly loading shells. Enables the ability to fire two rounds in rapid succession. Adds a heat shield to the top of the weapon, and a set of indicator lights to the back. Adds an orange circular laser projection to the top of the barrel that encompasses the bullet spread of the fired weapon. The logo for "RATEL" is printed on one side of the gun's slider. It features a foldable wire stock however this cannot be used by the player. It deals heavy damage and is semi automatic. Due to its compact size, it can be easily wielded and fired from one hand. It is operated in a unique fashion, instead of sliding shells into the magazine tube from underneath and racking a pump slide like most shotguns, it incorporates a break action and charging handle to load and charge the weapon. Alyx first acquires it from the corpse of a zombified Combine Worker. The shotgun appears to be a modified Heavy Shotgun turned into a compact weapon.