Universal Minimum Arming Distance

If you liked this item, please rate it up on Steam Workshop page.

Author: PhantomBravo

Last revision: 26 Oct, 2025 at 01:38 UTC

File size: 407.94 KB

On Steam Workshop

Description:

A simple mod that universally adds a minimum arming distance to weapons classified as a grenade launcher, rocket launcher, autocannon, or missile launcher (through the generateWeaponRoleFromStats() method as part of the Weapon type).

This mod has now been updated to make use of the onExplosionInfo event, which means that it no longer needs to make use of a clunky projectile table to keep track of each and every projectile fired, greatly improving asymptotic performance.

See Update: Oct 25 in the Change Notes for more details.

What is a minimum arming distance?

Minimum arming distance is a safety feature included in many explosives, particularly those that explode on impact. This mechanism requires the grenade/projectile/rocket/missile/wrhead/bomb/shell/etc. to travel for a certain distance or amount of time before it becomes armed. Only when armed can it then grenade/projectile/rocket/missile/warhead/bomb/shell/etc. properly explode on impact. Otherwise, it will most likely impact the ground in an inert (but still explodeable) state, or default to a timed detonation in the case of certain grenades. The exact implementation of this mechanism is beyond the scope of this description.

Configuration

In this mod, there are two settings to be configured.

First is the distance for the minimum arming distance, measured in meters.
If the grenade/projectile/rocket/missile/warhead/bomb/shell/etc. impacts a surface within this distance to its source, then it will still produce an explosion VFX, but it will have no actual effective radius, preventing you from blowing up yourself and surrounding individuals, though a direct hit can still deal damage. This effect can only apply to infantry weapons, used by both the player and bots. Vehicle weapons are not affected.
Note that the distance to the source is now recorded at the time of the explosive impact instead of being tracked from the time of firing, which means the distance between the explosion and shooter is not necessarily the distance the projectile has traveled, as the shooter could have moved farther or closer to the impact point beforehand. This is less realistic but offers greater consistency.

Second is a blacklist. Simply input the names of weapons you wish to have ignore the minimum arming distance, separating each different weapon name with a semicolon ; character. Do not include leading/trailing spaces before or after the delimiting character unless the weapon name for some reason has them (which would be stupid). Capitalization does not need to be matched.

IMPORTANT NOTE ABOUT BLACKLISTING WEAPONS

Ravenscript, the language used to script this mutator, will throw an error if the role generated from the weapon is something undefined. If this error gets thrown, it may interfere with the functionality of this mod. The only way to prevent this is to include that weapon’s name in the blacklist.
The updated version of this mod no longer has this issue as, logically speaking, any weapon with an undefined role wouldn’t be firing explosive projectiles anyways, and as such will not trigger the aforementioned error by causing an explosion.

Pro tip: Anti-material rifles (such as the ones in V+) are classified as rocket launchers by RS.

Possibly incompatible with that one rocket jumping mod (or maybe not).