]> git.pond.sub.org Git - empserver/commitdiff
launch interception: Drop support for ABM, a-sat consuming shells
authorMarkus Armbruster <armbru@pond.sub.org>
Mon, 4 Jan 2021 09:58:31 +0000 (10:58 +0100)
committerMarkus Armbruster <armbru@pond.sub.org>
Sun, 17 Jan 2021 20:24:29 +0000 (21:24 +0100)
Their impact on the target does not depend on shell load (it sometimes
did for a-sats until commit cf960a573 "Make anti-sat launch consistent
with interception", v4.3.23).  The shell use is logistical busy-work,
and economically irrelevant.  Remove it.

Signed-off-by: Markus Armbruster <armbru@pond.sub.org>
src/lib/commands/laun.c
src/lib/subs/mission.c
src/lib/subs/mslsub.c
src/lib/subs/plnsub.c

index 2f4fc8054228fca34270986050cf72f238082ba8..7a78c4e5c6ee37667cd1fc9a56791461dbcab03c 100644 (file)
@@ -151,7 +151,7 @@ launch_as(struct plnstr *pp)
        pr("Range too great!\n");
        return RET_FAIL;
     }
-    if (msl_equip(pp, 'i') < 0)
+    if (msl_equip(pp, 0) < 0)
        return RET_FAIL;
     if (msl_launch(pp, EF_PLANE, prplane(&plane),
                   plane.pln_x, plane.pln_y, plane.pln_own, NULL) < 0)
index 2a1f47c7528665a97d7a85317916315e72726c1e..40b82c069d64836b66cde79b43e3844272e24adf 100644 (file)
@@ -29,7 +29,7 @@
  *  Known contributors to this file:
  *     Ken Stevens, 1995
  *     Steve McClure, 1996-2000
- *     Markus Armbruster, 2003-2015
+ *     Markus Armbruster, 2003-2021
  */
 
 #include <config.h>
@@ -917,12 +917,8 @@ mission_pln_equip(struct plist *plp, struct ichrstr *ip, char mission)
     case 'p':          /* pinpoint bomb */
        itype = I_SHELL;
        break;
-    case 'i':          /* missile interception */
-       if (load)
-           itype = I_SHELL;
-       break;
     case 'e':          /* escort */
-    case 0:            /* plane interception */
+    case 0:            /* interception */
        load = 0;
        break;
     default:
index 3808611da221478d06cea23579b2d9e3e990741f..8b35e6d2a35e4003b5363159ef05d125cdfcded5 100644 (file)
@@ -29,7 +29,7 @@
  *  Known contributors to this file:
  *     Ken Stevens, 1995
  *     Steve McClure, 1996-2000
- *     Markus Armbruster, 2004-2012
+ *     Markus Armbruster, 2004-2021
  */
 
 #include <config.h>
@@ -257,7 +257,7 @@ msl_intercept(struct plnstr *msl, struct sctstr *sp, int sublaunch,
        pp = &ip->plane;
        if (pp->pln_own != sp->sct_own)
            continue;
-       if (mission_pln_equip(ip, NULL, 'i') < 0) {
+       if (mission_pln_equip(ip, NULL, 0) < 0) {
            emp_remque(qp);
            free(qp);
            continue;
@@ -275,7 +275,7 @@ msl_intercept(struct plnstr *msl, struct sctstr *sp, int sublaunch,
        next = qp->q_forw;
        ip = (struct plist *)qp;
        pp = &ip->plane;
-       if (mission_pln_equip(ip, NULL, 'i') < 0) {
+       if (mission_pln_equip(ip, NULL, 0) < 0) {
            emp_remque(qp);
            free(qp);
            continue;
index c349a99ba2e918b1af7cebc1c8d5f39fcbc6290e..afec51f38288a6385c7cc5d7fbf7d0bb48a58f02 100644 (file)
@@ -30,7 +30,7 @@
  *     Dave Pare, 1986
  *     Ken Stevens, 1995
  *     Steve McClure, 1998-2000
- *     Markus Armbruster, 2004-2020
+ *     Markus Armbruster, 2004-2021
  */
 
 #include <config.h>
@@ -714,13 +714,6 @@ pln_equip(struct plist *plp, struct ichrstr *ip, char mission)
     case 'e':          /* escort */
        load = 0;
        break;
-    case 'i':          /* missile interception */
-       if (CANT_HAPPEN(!(pcp->pl_flags & P_M)
-                       || !(pcp->pl_flags & (P_N | P_O))))
-           break;
-       if (load)
-           itype = I_SHELL;
-       break;
     default:
        CANT_REACH();
        load = 0;