#the ABstar - a big no-no if ($mass == 399) { $error_str .= $st[364]; } elseif ($mass < 300) { $error_str .= $st[365]; } elseif ($user['cash'] < $ship_stats['cost']) { $error_str .= $st[366]; } elseif ($user['tech'] < $ship_stats['tcost']) { $error_str .= $st[367]; } else { #do the processing. $cost_text = sprintf($st[368], $ship_stats[cost], $ship_stats[tcost]); if (!isset($ship_name)) { $ship_name = ""; } bulk_buy_1($num, $ship_name, $ship_stats['cost'], 0, $ship_stats, "mass", $cost_text); } } # #Beginning of Blackmarket ship single purchase # if (isset($ship_type)) { $ship_stats = load_ship_types((int) $ship_type); $take_flag = 1; if (!isset($ship_stats) && $user['game_login_count'] != '0') { print_page($cw['error'], $st[369], "?research=1"); } if (!isset($ship_stats['config'])) { $ship_stats['config'] = ""; } //begin ship checks
if (!empty($changed_factor['cargo_bays'])) { //xtra cargo cap $temp_a = $basic_cost * ceil($changed_factor['cargo_bays'] / $cargo_inc); $xtra_cost += $temp_a; $up_txt .= $changed_factor['cargo_bays'] . " " . $cw['extra_cargo_cap'] . ": <b>{$temp_a}</b><br />"; } $total_cost = $blueprints['cost'] + $xtra_cost; //total cost of each new ship if ($user['cash'] < $total_cost) { //check user has sufficient money $error_str .= sprintf($st[921], $blueprints[name], $blueprints[cost], $up_txt, $total_cost); } else { if (!isset($ship_name)) { $ship_name = ""; } bulk_buy_1($num, $ship_name, $total_cost, 1, $blueprints, $cw['duplicate'], sprintf($st[722], $blueprints[name], $blueprints[cost], $up_txt, $notes_str, $total_cost)); } } } } print_page($cw['ship_duplicator'], $error_str); //single ship build } else { if ($num_ships['war_reached'] && config_check("bs", $ship_stats)) { $error_str = sprintf($st[326], $num_ships[warships], $GAME_VARS[max_warships]); } elseif ($num_ships['other_reached'] && !config_check("bs", $ship_stats)) { $error_str = sprintf($st[327], $num_ships[other_ships], $GAME_VARS[max_other_ships]); } elseif ($got_a_brob == 1 && config_check("oo", $ship_stats)) { $error_str .= $st[725]; } elseif ($ship_type == 1 || $ship_type == 0) { $error_str = $st[726];