Move "Releasing RV's" message into detonate()

This commit is contained in:
Markus Armbruster 2009-10-05 07:25:45 -04:00
parent a269cdd7e9
commit 42cc4f14e0
3 changed files with 7 additions and 11 deletions

View file

@ -781,14 +781,10 @@ strat_bomb(struct emp_qelem *list, struct sctstr *target)
for (qp = list->q_forw; qp != list; qp = qp->q_forw) { for (qp = list->q_forw; qp != list; qp = qp->q_forw) {
plp = (struct plist *)qp; plp = (struct plist *)qp;
if (getnuke(nuk_on_plane(&plp->plane), &nuke)) { if (getnuke(nuk_on_plane(&plp->plane), &nuke))
mpr(plp->plane.pln_own,
"Releasing RV's for %s detonation...\n",
plp->plane.pln_flags & PLN_AIRBURST
? "airburst" : "groundburst");
detonate(&nuke, target->sct_x, target->sct_y, detonate(&nuke, target->sct_x, target->sct_y,
plp->plane.pln_flags & PLN_AIRBURST); plp->plane.pln_flags & PLN_AIRBURST);
} else else
dam += pln_damage(&plp->plane, 's', 1); dam += pln_damage(&plp->plane, 's', 1);
} }
if (dam <= 0) /* dam == 0 if only nukes were delivered */ if (dam <= 0) /* dam == 0 if only nukes were delivered */

View file

@ -260,12 +260,9 @@ launch_missile(struct plnstr *pp, int sublaunch)
#endif #endif
return RET_OK; return RET_OK;
} }
if (getnuke(nuk_on_plane(pp), &nuke)) { if (getnuke(nuk_on_plane(pp), &nuke))
mpr(pp->pln_own,
"Releasing RV's for %s detonation...\n",
pp->pln_flags & PLN_AIRBURST ? "airburst" : "groundburst");
detonate(&nuke, sx, sy, pp->pln_flags & PLN_AIRBURST); detonate(&nuke, sx, sy, pp->pln_flags & PLN_AIRBURST);
} else { else {
dam = pln_damage(pp, 's', 1); dam = pln_damage(pp, 's', 1);
pr("did %d damage in %s\n", PERCENT_DAMAGE(dam), pr("did %d damage in %s\n", PERCENT_DAMAGE(dam),
xyas(sx, sy, player->cnum)); xyas(sx, sy, player->cnum));

View file

@ -74,6 +74,9 @@ detonate(struct nukstr *np, coord x, coord y, int airburst)
struct nstr_item ni; struct nstr_item ni;
int issea; int issea;
mpr(bombown, "Releasing RV's for %s detonation...\n",
airburst ? "airburst" : "groundburst");
getsect(x, y, &sect); getsect(x, y, &sect);
issea = sect.sct_type == SCT_WATER; issea = sect.sct_type == SCT_WATER;
ncp = &nchr[nuketype]; ncp = &nchr[nuketype];