Bug #2198 ยป 0072-Qt-Support-Surgical-Strike-Production-at-the-choice-.patch
| client/gui-qt/dialogs.cpp | ||
|---|---|---|
|
extern void popdown_endgame_report();
|
||
|
static void spy_request_strike_bld_list(QVariant data1, QVariant data2);
|
||
|
static void spy_request_strike_production(QVariant data1, QVariant data2);
|
||
|
static void diplomat_incite(QVariant data1, QVariant data2);
|
||
|
static void diplomat_incite_escape(QVariant data1, QVariant data2);
|
||
|
static void spy_request_sabotage_list(QVariant data1, QVariant data2);
|
||
| ... | ... | |
|
action_function[ACTION_CONQUER_CITY_SHRINK3] = conquer_city_shrink3;
|
||
|
action_function[ACTION_CONQUER_CITY_SHRINK4] = conquer_city_shrink4;
|
||
|
action_function[ACTION_STRIKE_BUILDING] = spy_request_strike_bld_list;
|
||
|
action_function[ACTION_STRIKE_PRODUCTION] = spy_request_strike_production;
|
||
|
action_function[ACTION_NUKE_CITY] = nuke_city;
|
||
|
// Unit acting against a unit target.
|
||
| ... | ... | |
|
}
|
||
|
/***********************************************************************//**
|
||
|
Action request sabotage list for choice dialog
|
||
|
Action request "Surgical Strike Production" for choice dialog
|
||
|
***************************************************************************/
|
||
|
static void spy_request_strike_production(QVariant data1, QVariant data2)
|
||
|
{
|
||
|
int actor_id = data1.toInt();
|
||
|
int target_id = data2.toInt();
|
||
|
if (game_unit_by_number(actor_id) != nullptr
|
||
|
&& game_city_by_number(target_id) != nullptr) {
|
||
|
request_do_action(ACTION_STRIKE_PRODUCTION,
|
||
|
actor_id, target_id, 0, "");
|
||
|
}
|
||
|
}
|
||
|
/***********************************************************************//**
|
||
|
Action request sabotage list for choice dialog
|
||
|
***************************************************************************/
|
||
|
static void spy_request_sabotage_list(QVariant data1, QVariant data2)
|
||
|
{
|
||