Jazz2::WeaponFireOptions struct

How a custom weapon fires.

Public functions

auto operator==(const WeaponFireOptions& other) const -> bool
auto operator!=(const WeaponFireOptions& other) const -> bool

Public variables

String Sound
Name of the sound of firing, from the metadata of the shot, or of the player.
std::int32_t SoundIndex
Index of an embedded sound of firing (see WeaponsDescription::Sounds) in place of Sound, -1 for none.
float Cooldown
Frames between shots.
float FastFireStep
Frames each fast fire takes from the cooldown.
float SpreadAngle
Angle between the shots fired at once, in radians.
float RandomSpread
Random angle added to each shot, in radians.
float Recoil
How hard firing pushes the player back.
std::uint16_t AmmoPerShot
Ammo a shot takes, 256 is one round.
std::uint8_t ShotsPerFire
Shots fired at once.
bool AllowedInWater
Whether it fires under water.
bool StandStill
Whether it fires only while the player stands, not while walking, running or on a pole, as the thunderbolt.
bool LoopSound
Whether the sound plays in a loop while it fires.
bool Flare
Whether the muzzle flashes.