Page 1 of 1

How does atomic bomb - `upper_distance_threshold` work?

Posted: Wed Sep 02, 2026 3:00 pm
by freeafrica
I want to create explosive weapons, that work similarly as the atomic bomb, in a delayed "wavelike" manner, but with different parameters.

I've checked the `atomic-rocket` projectile-prototype and also checked the wiki. If I understand correctly, there is a basic area damage in the center instantly and 1000+1000 projectiles are created that "shoot-out" to given radius. So far so good.

Now, the outer explosions are created by the `atomic-bomb-wave` prototype named projectiles, they have a blast-`radius` of `3`. Now here comes the confusing part (at least for me) of the prototype. They have `upper_distance_threshold` set to `35` in their `target_effect` of the damage. But isn't the damage caused with `radius = 3`? What is the point of limiting it by `35` distance? I have the feeling that somehow connects to the original center of explosion, but aren't these esentially completley independent projectiles from the original rocket?

Below I've included the prototype definition for `atomic-bomb-wave`, but this can be seen in the center-ring explosion (`atomic-bomb-ground-zero-projectile`) prototype too.

Code: Select all

["atomic-bomb-wave"] = {
      acceleration = 0,
      action = {
        {
          action_delivery = {
            target_effects = {
              damage = { amount = 400, type = "explosion" },
              lower_damage_modifier = 1,
              lower_distance_threshold = 0,
              type = "damage",
              upper_damage_modifier = 0.1,
              upper_distance_threshold = 35,
              vaporize = false
            },
            type = "instant"
          },
          ignore_collision_condition = true,
          radius = 3,
          type = "area"
        }
      },
      ...