2 * Empire - A multi-player, client/server Internet based war game.
3 * Copyright (C) 1986-2000, Dave Pare, Jeff Bailey, Thomas Ruschak,
4 * Ken Stevens, Steve McClure
6 * This program is free software; you can redistribute it and/or modify
7 * it under the terms of the GNU General Public License as published by
8 * the Free Software Foundation; either version 2 of the License, or
9 * (at your option) any later version.
11 * This program is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
14 * GNU General Public License for more details.
16 * You should have received a copy of the GNU General Public License
17 * along with this program; if not, write to the Free Software
18 * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
22 * See the "LEGAL", "LICENSE", "CREDITS" and "README" files for all the
23 * related information and legal notices. It is expected that any future
24 * projects/authors will amend these files as needed.
28 * bomb.c: Fly bombing missions
30 * Known contributors to this file:
33 * Steve McClure, 1998-2000
57 static void pin_bomb(struct emp_qelem *list, struct sctstr *target);
58 static void strat_bomb(struct emp_qelem *list, struct sctstr *target);
59 static void comm_bomb(struct emp_qelem *list, struct sctstr *target);
60 static void eff_bomb(struct emp_qelem *list, struct sctstr *target);
62 static void plane_bomb(struct emp_qelem *list, struct sctstr *target);
63 static void land_bomb(struct emp_qelem *list, struct sctstr *target);
64 static void ship_bomb(struct emp_qelem *list, struct sctstr *target);
65 int pinflak_planedamage(struct plnstr *pp, struct plchrstr *pcp, natid from, int flak);
67 static int bombcomm[] = {
83 static int nbomb = sizeof(bombcomm) / sizeof(int);
95 s_char flightpath[MAX_PATH_LEN];
96 struct nstr_item ni_bomb;
97 struct nstr_item ni_esc;
100 struct emp_qelem bomb_list;
101 struct emp_qelem esc_list;
103 struct sctstr ap_sect;
110 if (!snxtitem(&ni_bomb, EF_PLANE, player->argp[1]))
112 if (!snxtitem(&ni_esc, EF_PLANE, getstarg(player->argp[2], "escort(s)? ", buf)))
113 pr("No escorts...\n");
114 if ((p = getstarg(player->argp[3], "pinpoint, or strategic? ", buf)) == 0)
117 if (index("ps", mission) == 0)
119 if ((p = getstarg(player->argp[4], "assembly point? ", buf)) == 0 || *p == 0)
121 if (!sarg_xy(p, &x, &y) || !getsect(x, y, &ap_sect))
123 if (ap_sect.sct_own && ap_sect.sct_own != player->cnum &&
124 getrel(getnatp(ap_sect.sct_own), player->cnum) != ALLIED) {
125 pr("Assembly point not owned by you or an ally!\n");
130 if (getpath(flightpath, player->argp[5], ax, ay, 0, 0,
131 0, P_FLYING) == 0 || *flightpath == 0)
135 (void) pathtoxy(flightpath, &tx, &ty, fcost);
136 pr("target sector is %s\n", xyas(tx, ty, player->cnum));
137 getsect(tx, ty, &target);
138 if (target.sct_type == SCT_SANCT) {
139 pr("You can't bomb that sector!\n");
143 ap_to_target = strlen(flightpath);
144 if (*(flightpath+strlen(flightpath)-1) == 'h')
146 pr("range to target is %d\n", ap_to_target);
148 * select planes within range
151 pln_sel(&ni_bomb, &bomb_list, &ap_sect, ap_to_target,
152 2, wantflags, P_M|P_O);
153 pln_sel(&ni_esc, &esc_list, &ap_sect, ap_to_target,
154 2, wantflags|P_F|P_ESC, P_M|P_O);
156 * now arm and equip the bombers, transports, whatever.
157 * tech is stored in high 16 bits of mission_flags.
161 mission_flags |= P_X; /* stealth (shhh) */
162 mission_flags |= P_H; /* gets turned off if not all choppers */
163 mission_flags = pln_arm(&bomb_list, 2*ap_to_target, mission, ip, 0, mission_flags, &tech);
164 if (QEMPTY(&bomb_list)) {
165 pr("No planes could be equipped for the mission.\n");
168 mission_flags = pln_arm(&esc_list, 2*ap_to_target, mission, ip,P_F|P_ESC,mission_flags,&tech);
169 ac_encounter(&bomb_list,&esc_list,ax,ay,flightpath,mission_flags,0,0,0);
170 if (QEMPTY(&bomb_list)) {
171 pr("No planes got through fighter defenses\n");
175 pin_bomb(&bomb_list, &target);
179 natp = getnatp(player->cnum);
181 rel = getrel(natp,target.sct_own);
182 if ((rel != AT_WAR) && (player->cnum != target.sct_own)
183 && (target.sct_own) &&
184 (target.sct_oldown != player->cnum)){
185 pr("You're not at war with them!\n");
192 nreport(player->cnum, N_SCT_BOMB, target.sct_own, 1);
193 strat_bomb(&bomb_list, &target);
196 pr("Bad mission %c\n", mission);
206 pin_bomb(struct emp_qelem *list, struct sctstr *target)
208 extern s_char *effadv();
217 struct emp_qelem *qp;
227 type = target->sct_type;
229 pr("Target sector is a %s constructed %s\n",
230 effadv((int)target->sct_effic), dcp->d_name);
232 plp = (struct plist *) list->q_forw;
233 if (plp->pcp->pl_flags & P_A){
235 for (qp = list->q_forw; qp != list; qp = qp->q_forw)
236 plp = (struct plist *) qp;
237 if (plp->plane.pln_acc < bestacc)
238 bestacc = plp->plane.pln_acc;
239 nships = num_shipsatxy(target->sct_x, target->sct_y, 0, 0);
241 shipsatxy(target->sct_x, target->sct_y, 0, M_SUB);
243 pr("Some subs are present in the sector.\n");
245 nships = shipsatxy(target->sct_x, target->sct_y, 0, M_SUB);
247 nplanes = planesatxy(target->sct_x, target->sct_y, 0, 0, list);
248 nunits = unitsatxy(target->sct_x, target->sct_y, 0, 0);
249 getvec(VT_ITEM, vec, (s_char *)target, EF_SECTOR);
251 p = getstring("Bomb what? (ship, plane, land unit, efficiency, commodities) ", buf);
252 if (p == 0 || *p == 0) {
263 natp = getnatp(player->cnum);
264 if (target->sct_own){
265 rel = getrel(natp,target->sct_own);
266 if ((rel != AT_WAR) && (player->cnum != target->sct_own)
267 && (target->sct_own) &&
268 (target->sct_oldown != player->cnum)){
269 pr("You're not at war with them!\n");
275 pr("no units there\n");
278 land_bomb(list, target);
282 natp = getnatp(player->cnum);
283 if (target->sct_own){
284 rel = getrel(natp,target->sct_own);
285 if ((rel != AT_WAR) && (player->cnum != target->sct_own)
286 && (target->sct_own) &&
287 (target->sct_oldown != player->cnum)){
288 pr("You're not at war with them!\n");
294 pr("no planes there\n");
297 plane_bomb(list, target);
301 if (((struct plist *)list->q_forw)->pcp->pl_flags & P_A){
303 pr("no ships there\n");
307 pr("no ships there\n");
311 ship_bomb(list, target);
315 natp = getnatp(player->cnum);
316 if (target->sct_own){
317 rel = getrel(natp,target->sct_own);
318 if ((rel != AT_WAR) && (player->cnum != target->sct_own)
319 && (target->sct_own) &&
320 (target->sct_oldown != player->cnum)){
321 pr("You're not at war with them!\n");
327 for (i = 0; i < nbomb; i++) {
328 if (!vec[bombcomm[i]])
333 pr("No bombable commodities in %s\n",
334 xyas(target->sct_x, target->sct_y, player->cnum));
337 comm_bomb(list, target);
341 natp = getnatp(player->cnum);
342 if (target->sct_own){
343 rel = getrel(natp,target->sct_own);
344 if ((rel != AT_WAR) && (player->cnum != target->sct_own)
345 && (target->sct_own) &&
346 (target->sct_oldown != player->cnum)){
347 pr("You're not at war with them!\n");
352 eff_bomb(list, target);
355 pr("Aborting mission.\n");
358 pr("Bad target type.\n");
364 eff_bomb(struct emp_qelem *list, struct sctstr *target)
366 register struct plist *plp;
367 struct emp_qelem *qp;
372 for (qp = list->q_forw; qp != list; qp = qp->q_forw) {
373 plp = (struct plist *) qp;
374 if ((plp->pcp->pl_flags & P_C) && (!(plp->pcp->pl_flags & P_T)))
376 if (plp->bombs || plp->plane.pln_nuketype != -1)
377 dam += pln_damage(&plp->plane, target->sct_x, target->sct_y, 'p', &nukedam, 1);
379 if (dam <= 0) /* dam == 0 if only nukes were delivered */
381 getsect(target->sct_x, target->sct_y, §);
383 oldeff = target->sct_effic;
384 target->sct_effic = effdamage(target->sct_effic, dam);
385 target->sct_road = effdamage(target->sct_road, dam);
386 target->sct_rail = effdamage(target->sct_rail, dam);
387 target->sct_defense = effdamage(target->sct_defense, dam);
388 if (!opt_DEFENSE_INFRA)
389 target->sct_defense = target->sct_effic;
390 pr("did %d%% damage to efficiency in %s\n",
391 oldeff - target->sct_effic,
392 xyas(target->sct_x, target->sct_y, player->cnum));
394 wu(0, target->sct_own,
395 "%s bombing raid did %d%% damage in %s\n",
396 cname(player->cnum), oldeff - target->sct_effic,
397 xyas(target->sct_x, target->sct_y, target->sct_own));
398 if (target->sct_effic < 20) {
399 if (target->sct_type == SCT_BSPAN)
400 knockdown(target, list);
401 else if (target->sct_type == SCT_BTOWER) {
402 knockdown(target, list);
403 bridgefall(target, list);
407 collateral_damage(target->sct_x, target->sct_y, dam, list);
411 comm_bomb(struct emp_qelem *list, struct sctstr *target)
413 register struct plist *plp;
419 struct emp_qelem *qp;
424 getvec(VT_ITEM, vec, (s_char *)target, EF_SECTOR);
425 for (i=0; i<nbomb; i++) {
426 if (vec[bombcomm[i]] == 0)
428 if (opt_SUPER_BARS && bombcomm[i] == I_BAR)
430 ip = &ichr[bombcomm[i]];
431 pr("some %s\n", ip->i_name);
434 ip = whatitem((s_char *) 0, "commodity to bomb? ");
440 for (i=0; i<nbomb; i++) {
441 if (opt_SUPER_BARS && bombcomm[i] == I_BAR)
443 if (&ichr[bombcomm[i]] == ip)
447 pr("You can't bomb %s!\n", ip->i_name);
448 for (i=0; i<nbomb; i++) {
449 if (opt_SUPER_BARS && bombcomm[i] == I_BAR)
451 pr(i == 0 ? "Bombable: " : ", ");
452 pr(ichr[bombcomm[i]].i_name);
458 for (qp = list->q_forw; qp != list; qp = qp->q_forw) {
459 plp = (struct plist *) qp;
460 if ((plp->pcp->pl_flags & P_C) && (!(plp->pcp->pl_flags & P_T)))
462 if (plp->bombs || plp->plane.pln_nuketype != -1)
463 dam += pln_damage(&plp->plane, target->sct_x, target->sct_y, 'p', &nukedam, 1);
465 if (dam <= 0) /* dam == 0 if only nukes were delivered */
467 getsect(target->sct_x, target->sct_y, §);
469 before = amt = getvar(ip->i_vtype, (s_char *)target, EF_SECTOR);
470 putvar(ip->i_vtype, commdamage(amt, dam, ip->i_vtype), (s_char *)target, EF_SECTOR);
471 amt = getvar(ip->i_vtype, (s_char *)target, EF_SECTOR);
473 b = 100.0*(1.0 - ((float)amt/(float)before));
476 pr("did %.2f%% damage to %s in %s\n",
478 xyas(target->sct_x, target->sct_y, player->cnum));
479 nreport(player->cnum, N_SCT_BOMB, target->sct_own, 1);
480 if(target->sct_own != 0)
481 wu(0, target->sct_own,
482 "%s precision bombing raid did %.2f%% damage to %s in %s\n",
483 cname(player->cnum), b, ip->i_name,
484 xyas(target->sct_x, target->sct_y, target->sct_own));
486 collateral_damage(target->sct_x, target->sct_y, dam, list);
490 ship_bomb(struct emp_qelem *list, struct sctstr *target)
498 struct emp_qelem *qp;
503 struct shiplook head, *s, *s2;
513 bzero((s_char *)&head,sizeof(struct shiplook));
515 onsea = (target->sct_type == SCT_WATER) ? 1 : 0;
516 for (qp = list->q_forw; qp != list && !player->aborted; qp = qp->q_forw) {
519 while (s != (struct shiplook *)0){
525 bzero((s_char *)&head,sizeof(struct shiplook));
527 plp = (struct plist *) qp;
528 if ((plp->pcp->pl_flags & P_C) && (!(plp->pcp->pl_flags & P_T)))
530 if (plp->pcp->pl_flags & P_A)
531 nships=asw_shipsatxy(target->sct_x, target->sct_y,0,0,
534 nships=shipsatxy(target->sct_x,target->sct_y,0,M_SUB);
536 pr("%s could not find any ships!\n",
537 prplane(&plp->plane));
540 (void) sprintf(prompt, "%s, %d bombs. Target ('~' to skip)? ",
541 prplane(&plp->plane),
545 while (shipno < 0 && !player->aborted && !ignore) {
546 if ((q = getstring(prompt, buf)) == 0 || *q == 0)
553 if (plp->pcp->pl_flags & P_A)
556 shipsatxy(target->sct_x, target->sct_y,
567 if (getship(n, &ship) && ship.shp_x == target->sct_x &&
568 ship.shp_y == target->sct_y)
575 gun = min(getvar(V_GUN, (s_char *)&ship, EF_SHIP), ship.shp_glim);
577 shell = getvar(V_SHELL, (s_char *)&ship, EF_SHIP);
579 shell = supply_commod(ship.shp_own, ship.shp_x,
580 ship.shp_y, I_SHELL, 1);
582 mcp = &mchr[(int)ship.shp_type];
583 if (gun > 0 && shell > 0 && !(mcp->m_flags & M_SUB)) {
584 flak = (int)(techfact(ship.shp_tech, (double)gun) * 2.0);
585 putvar(V_SHELL, shell, (s_char *)&ship, EF_SHIP);
586 putship(ship.shp_uid, &ship);
587 sprintf(msg, "Flak! Firing %d guns from ship %s\n",
588 flak, prship(&ship));
589 PR(ship.shp_own, msg);
590 if (pinflak_planedamage(&plp->plane, plp->pcp, ship.shp_own, flak))
595 if (plp->plane.pln_nuketype != -1)
598 hitchance = pln_hitchance(&plp->plane, shp_hardtarget(&ship), EF_SHIP);
599 pr("%d%% hitchance...", hitchance);
601 if (roll(100) <= hitchance) {
602 /* pinbombing is more accurate than normal bombing */
603 dam = 2 * pln_damage(&plp->plane, target->sct_x, target->sct_y, 'p', &nukedam, 1);
606 /* Bombs that miss have to land somewhere! */
607 dam = pln_damage(&plp->plane, target->sct_x, target->sct_y, 'p', &nukedam, 0);
608 collateral_damage(target->sct_x, target->sct_y, dam, list);
611 if (dam <= 0) /* dam == 0 if only nukes were delivered */
613 if (mcp->m_flags & M_SUB)
614 nreport(player->cnum, N_SUB_BOMB, ship.shp_own, 1);
616 nreport(player->cnum, N_SHP_BOMB, ship.shp_own, 1);
618 wu(0, ship.shp_own, "%s bombs did %d damage to %s at %s\n",
619 cname(player->cnum), dam,
621 xyas(target->sct_x, target->sct_y, ship.shp_own));
624 check_retreat_and_do_shipdamage(&ship, dam);
625 if (ship.shp_rflags & RET_BOMBED)
626 if (((ship.shp_rflags & RET_INJURED) == 0) || !dam)
627 retreat_ship(&ship,'b');
628 putship(ship.shp_uid, &ship);
631 pr("%s at %s sunk!\n",
633 xyas(target->sct_x, target->sct_y, player->cnum));
635 collateral_damage(target->sct_x, target->sct_y, dam/2, list);
640 while (s != (struct shiplook *)0){
648 plane_bomb(struct emp_qelem *list, struct sctstr *target)
655 struct emp_qelem *qp;
665 for (qp = list->q_forw; qp != list; qp = qp->q_forw) {
666 plp = (struct plist *) qp;
667 if ((plp->pcp->pl_flags & P_C) && (!(plp->pcp->pl_flags & P_T)))
669 nplanes = planesatxy(target->sct_x, target->sct_y, 0, 0, list);
671 pr("%s could not find any planes!\n",
672 prplane(&plp->plane));
675 (void) sprintf(prompt, "%s, %d bombs. Target ('~' to skip)? ",
676 prplane(&plp->plane),
680 while (planeno < 0 && !player->aborted && !ignore) {
681 if ((q = getstring(prompt, buf)) == 0 || *q == 0)
688 planesatxy(target->sct_x, target->sct_y, 0, 0, list);
696 if (getplane(n, &plane) &&
697 plane.pln_x == target->sct_x &&
698 plane.pln_y == target->sct_y &&
699 ((plane.pln_flags & PLN_LAUNCHED) == 0) &&
700 (!ac_isflying(&plane, list)))
703 pr("Plane #%d not spotted\n", n);
708 if (plp->plane.pln_nuketype != -1)
711 hitchance = pln_hitchance(&plp->plane, 0, EF_PLANE);
712 pr("%d%% hitchance...", hitchance);
714 if (roll(100) <= hitchance) {
715 /* pinbombing is more accurate than normal bombing */
716 dam = 2 * pln_damage(&plp->plane,target->sct_x,target->sct_y, 'p', &nukedam, 1);
719 /* Bombs that miss have to land somewhere! */
720 dam = pln_damage(&plp->plane,target->sct_x,target->sct_y, 'p', &nukedam, 0);
721 collateral_damage(target->sct_x, target->sct_y, dam, list);
724 if (dam <= 0) /* dam == 0 if only nukes were delivered */
729 if (dam > plane.pln_effic) {
731 makelost(EF_PLANE, plane.pln_own, plane.pln_uid, plane.pln_x, plane.pln_y);
734 plane.pln_effic -= dam;
735 plane.pln_mobil = (dam * plane.pln_mobil / 100.0);
736 if (own == player->cnum) {
737 pr("%s reports %d%% damage\n",
743 "%s pinpoint bombing raid did %d%% damage to %s\n",
744 cname(player->cnum), dam, prplane(&plane));
746 nreport(player->cnum, N_DOWN_PLANE, own, 1);
748 wu(0, own, "%s bombs did %d%% damage to %s at %s\n",
749 cname(player->cnum), dam, prplane(&plane),
750 xyas(target->sct_x, target->sct_y, own));
751 putplane(plane.pln_uid, &plane);
752 collateral_damage(plane.pln_x, plane.pln_y, dam, list);
759 land_bomb(struct emp_qelem *list, struct sctstr *target)
770 struct emp_qelem *qp;
772 int ignore, flak, hitchance;
777 for (qp = list->q_forw; qp != list; qp = qp->q_forw) {
778 plp = (struct plist *) qp;
779 if ((plp->pcp->pl_flags & P_C) && (!(plp->pcp->pl_flags & P_T)))
781 nunits = unitsatxy(target->sct_x, target->sct_y, 0, 0);
783 pr("%s could not find any units!\n",
784 prplane(&plp->plane));
787 (void) sprintf(prompt, "%s, %d bombs. Target ('~' to skip)? ",
788 prplane(&plp->plane),
792 while (unitno < 0 && !player->aborted && !ignore) {
793 if ((q = getstring(prompt, buf)) == 0 || *q == 0)
800 unitsatxy(target->sct_x, target->sct_y, 0, 0);
808 if (getland(n, &land) &&
809 land.lnd_x == target->sct_x &&
810 land.lnd_y == target->sct_y)
813 pr("Unit #%d not spotted\n", n);
818 lcp = &lchr[(int)land.lnd_type];
820 flak = (int)(techfact(land.lnd_tech, (double)land.lnd_aaf) * 3.0);
822 sprintf(msg, "Flak! Firing flak guns from unit %s (aa rating %d)\n",
823 prland(&land), land.lnd_aaf);
824 PR(land.lnd_own, msg);
825 if (pinflak_planedamage(&plp->plane, plp->pcp, land.lnd_own, flak))
830 if (plp->plane.pln_nuketype != -1)
833 hitchance = pln_hitchance(&plp->plane, lnd_hardtarget(&land), EF_LAND);
834 pr("%d%% hitchance...", hitchance);
836 if (roll(100) <= hitchance) {
837 dam = 2 * pln_damage(&plp->plane,target->sct_x,target->sct_y, 'p', &nukedam, 1);
840 /* Bombs that miss have to land somewhere! */
841 dam = pln_damage(&plp->plane,target->sct_x,target->sct_y, 'p', &nukedam, 0);
842 collateral_damage(target->sct_x, target->sct_y, dam, list);
845 if (dam <= 0) /* dam == 0 if only nukes were delivered */
852 "%s pinpoint bombing raid did %d damage to %s\n",
853 cname(player->cnum), dam, prland(&land));
854 check_retreat_and_do_landdamage(&land, dam);
856 if (land.lnd_rflags & RET_BOMBED)
857 if (((land.lnd_rflags & RET_INJURED) == 0) || !dam)
858 retreat_land(&land,'b');
859 nreport(player->cnum, N_UNIT_BOMB, own, 1);
860 putland(land.lnd_uid, &land);
861 collateral_damage(land.lnd_x, land.lnd_y, dam, list);
868 strat_bomb(struct emp_qelem *list, struct sctstr *target)
870 register struct plist *plp;
872 struct emp_qelem *qp;
876 for (qp = list->q_forw; qp != list; qp = qp->q_forw) {
877 plp = (struct plist *) qp;
878 if ((plp->pcp->pl_flags & P_C) && (!(plp->pcp->pl_flags & P_T)))
880 if (plp->bombs || plp->plane.pln_nuketype != -1)
881 dam += pln_damage(&plp->plane, target->sct_x, target->sct_y, 's', &nukedam, 1);
883 if (dam <= 0) /* dam == 0 if only nukes were delivered */
885 getsect(target->sct_x, target->sct_y, §);
888 wu(0, target->sct_own, "%s bombing raid did %d damage in %s\n",
889 cname(player->cnum), PERCENT_DAMAGE(dam),
890 xyas(target->sct_x, target->sct_y, target->sct_own));
892 sectdamage(target, dam, list);
894 pr("did %d damage in %s\n", PERCENT_DAMAGE(dam),
895 xyas(target->sct_x, target->sct_y, player->cnum));
900 float lflaktable[16] = { 0.20, 0.20, 0.25, 0.30, 0.35, 0.40, 0.45, 0.50,
901 0.50, 0.55, 0.60, 0.65, 0.70, 0.75, 0.80, 0.85, };
903 pinflak_planedamage(struct plnstr *pp, struct plchrstr *pcp, natid from, int flak)
905 extern double flakscale;
916 flak -= (pp->pln_def+1);
917 if (pcp->pl_flags & P_X)
919 if (pcp->pl_flags & P_H)
922 mult = lflaktable[FLAK_MAX] * 1.33;
924 mult = lflaktable[0] * 0.66;
927 mult = lflaktable[flak];
930 dam = (int) ((roll(8) + 2) * mult);
935 plane_owner = pp->pln_own;
943 if (eff < PLANE_MINEFF) {
944 sprintf(dmess," -- shot down");
946 } else if (chance((100-eff)/100.0)){
947 sprintf(dmess," -- aborted with %d%%%% damage", 100-eff);
950 sprintf(mesg, " Flak! %s %s takes %d%s.\n",
951 cname(pp->pln_own), prplane(pp),
953 PR(plane_owner, mesg);
958 nreport(from, N_DOWN_PLANE, pp->pln_own, 1);
959 if (pp->pln_ship >= 0) {
960 getship(pp->pln_ship,&ship);
961 take_plane_off_ship(pp,&ship);
963 if (pp->pln_land >= 0) {
964 getland(pp->pln_land,&land);
965 take_plane_off_land(pp,&land);
967 makelost(EF_PLANE, pp->pln_own, pp->pln_uid, pp->pln_x, pp->pln_y);
969 putplane(pp->pln_uid, pp);
971 putplane(pp->pln_uid, pp);