]> git.pond.sub.org Git - empserver/commitdiff
Penalize fighter combat value for any load, not just bombs
authorMarkus Armbruster <armbru@pond.sub.org>
Sat, 3 Oct 2009 20:02:17 +0000 (16:02 -0400)
committerMarkus Armbruster <armbru@pond.sub.org>
Sat, 12 Dec 2009 15:28:52 +0000 (16:28 +0100)
This can affect only planes with capabilities intercept and either
cargo or mine.  No such planes exist in the stock game.

src/lib/subs/aircombat.c

index bf6022df297e6eeb1b6207bfc9da1ed97abed099..434546842a7d9f327f715321ae9f88802c2841cc 100644 (file)
@@ -492,9 +492,9 @@ ac_dog(struct plist *ap, struct plist *dp)
     def = pln_def(&dp->plane) * dp->plane.pln_effic / 100;
     def = MAX(def, dp->pcp->pl_def / 2);
 
-    if ((ap->pcp->pl_flags & P_F) && ap->bombs != 0)
+    if ((ap->pcp->pl_flags & P_F) && ap->bombs + ap->misc != 0)
        att -= 2;
-    if ((dp->pcp->pl_flags & P_F) && dp->bombs != 0)
+    if ((dp->pcp->pl_flags & P_F) && dp->bombs + ap->misc != 0)
        def -= 2;
     att += ap->pcp->pl_stealth / 25.0;
     def += dp->pcp->pl_stealth / 25.0;