]> git.pond.sub.org Git - empserver/commitdiff
Fix news for torpedo attack's return torpedo
authorMarkus Armbruster <armbru@pond.sub.org>
Fri, 12 Mar 2010 19:39:39 +0000 (20:39 +0100)
committerMarkus Armbruster <armbru@pond.sub.org>
Tue, 16 Mar 2010 20:27:41 +0000 (21:27 +0100)
When a torpedo attack triggered a return torpedo, the news reported it
to be fired by the attacker instead of the defender.

src/lib/commands/torp.c

index 22b24d079d214f13c4bc982a7a370034836a46c0..3ba4fd3bea23fb80b7a26972e0010ec422120e5c 100644 (file)
@@ -319,7 +319,7 @@ fire_torp(struct shpstr *sp, struct shpstr *targ, int ntargets)
        if (mchr[(int)sp->shp_type].m_flags & M_SUB)
            nreport(targ->shp_own, N_TORP_SHIP, 0, 1);
        else
        if (mchr[(int)sp->shp_type].m_flags & M_SUB)
            nreport(targ->shp_own, N_TORP_SHIP, 0, 1);
        else
-           nreport(targ->shp_own, N_SHIP_TORP, player->cnum, 1);
+           nreport(targ->shp_own, N_SHIP_TORP, sp->shp_own, 1);
     } else {
        pr("Missed!\n");
        if (sp->shp_own != 0)
     } else {
        pr("Missed!\n");
        if (sp->shp_own != 0)