/*
* Empire - A multi-player, client/server Internet based war game.
- * Copyright (C) 1986-2009, Dave Pare, Jeff Bailey, Thomas Ruschak,
+ * Copyright (C) 1986-2010, Dave Pare, Jeff Bailey, Thomas Ruschak,
* Ken Stevens, Steve McClure
*
* This program is free software; you can redistribute it and/or modify
/*
* select planes within range
*/
- pln_sel(&ni_bomb, &bomb_list, &ap_sect, ap_to_target,
- 1, wantflags, P_M | P_O);
- if (QEMPTY(&bomb_list)) {
- pr("No planes could be equipped for the mission.\n");
- return RET_FAIL;
- }
- wantflags |= P_F;
- wantflags |= P_ESC;
- pln_sel(&ni_esc, &esc_list, &ap_sect, ap_to_target,
- 1, wantflags, P_M | P_O);
+ pln_sel(&ni_bomb, &bomb_list, &ap_sect, ap_to_target, 1,
+ wantflags, P_M | P_O);
+ pln_sel(&ni_esc, &esc_list, &ap_sect, ap_to_target, 1,
+ wantflags | P_ESC | P_F, P_M | P_O);
if (cno >= 0 && !pln_oneway_to_carrier_ok(&bomb_list, &esc_list, cno)) {
pr("Not enough room on ship #%d!\n", cno);
return RET_FAIL;
/*
* now arm and equip the bombers, transports, whatever.
*/
- pln_arm(&bomb_list, ap_to_target, 't', ip, 0);
+ pln_arm(&bomb_list, ap_to_target, 't', ip);
if (QEMPTY(&bomb_list)) {
pr("No planes could be equipped for the mission.\n");
return RET_FAIL;
}
- pln_arm(&esc_list, ap_to_target, 't', ip, P_ESC | P_F);
+ pln_arm(&esc_list, ap_to_target, 'e', NULL);
ac_encounter(&bomb_list, &esc_list, ax, ay, flightpath, 0);
if (QEMPTY(&bomb_list)) {
pr("No planes got through fighter defenses\n");