IsSonic
Sends a visible wave rolling from the muzzle to the target, damaging everything it crosses on the way.
- Applies to
- WeaponType
- File
rules.ini- Section
[<ObjectType ID>]- Value
- boolean
- When omitted
no
IsSonic=yes makes the weapon fire a wave that rolls from the muzzle to the target and damages the objects under it. All of the weapon’s damage comes from the wave’s AmbientDamage. The weapon still fires its projectile, but the projectile carries no damage, so Damage= adds nothing to the shot.
[MySonicGun] ; example WeaponTypeIsSonic=yesProjectile=MyBolt ; a BulletType, registered by a weapon naming it as its ProjectileAmbientDamage=3Damage=1 ; never deliveredRange=6ROF=120How long the wave lasts
Section titled “How long the wave lasts”The wave grows from the muzzle by a twentieth of the distance each frame, and reaches the target after 20 frames. It holds at full length for about 60 more frames, then fades from its trailing edge over the last 20. The whole wave lasts about 100 frames.
The wave damages the objects in every cell it covers on every frame it lasts, so an object that stays under it is hit many times. Even a small AmbientDamage adds up. If the firer is destroyed, the wave deals no more damage and fades. AmbientDamage covers the damage each hit deals, and its effect on walls and chain reactive overlay. On every frame, a destroyable cliff under the wave may also collapse, at the chance [CombatDamage] CollapseChance sets.
Firing rate
Section titled “Firing rate”While a wave is alive, neither of the object’s weapons can fire. The reload delay after a sonic shot is exactly ROF, with no house rate-of-fire bias, burst delay, random extra frames or veteran bonus. The next shot waits until both ROF has passed and the wave is gone. A structure with more than one round of Ammo left waits only for the wave. The reload delay gives the full rules.