Feature #817 ยป 0026-Rename-action_._unit_units-as-action_._unit_stack.patch
doc/README.actions | ||
---|---|---|
signal.connect("action_started_unit_city", "action_started_callback")
|
||
signal.connect("action_started_unit_unit", "action_started_callback")
|
||
signal.connect("action_started_unit_units", "action_started_callback")
|
||
signal.connect("action_started_unit_stack", "action_started_callback")
|
||
signal.connect("action_started_unit_tile", "action_started_callback")
|
||
signal.connect("action_started_unit_extras", "action_started_callback")
|
||
signal.connect("action_started_unit_self", "action_started_callback")
|
server/scripting/script_server.c | ||
---|---|---|
API_TYPE_ACTION, API_TYPE_BOOL,
|
||
API_TYPE_UNIT, API_TYPE_UNIT);
|
||
luascript_signal_create(fcl_main, "action_started_unit_stack", 3,
|
||
API_TYPE_ACTION,
|
||
API_TYPE_UNIT, API_TYPE_TILE);
|
||
luascript_signal_create(fcl_main, "action_finished_unit_stack", 4,
|
||
API_TYPE_ACTION, API_TYPE_BOOL,
|
||
API_TYPE_UNIT, API_TYPE_TILE);
|
||
luascript_signal_create(fcl_main, "action_started_unit_units", 3,
|
||
API_TYPE_ACTION,
|
||
API_TYPE_UNIT, API_TYPE_TILE);
|
||
deprecate_signal(depr, "action_started_unit_units",
|
||
"action_started_unit_stack", "3.3", NULL);
|
||
luascript_signal_create(fcl_main, "action_finished_unit_units", 4,
|
||
API_TYPE_ACTION, API_TYPE_BOOL,
|
||
API_TYPE_UNIT, API_TYPE_TILE);
|
||
deprecate_signal(depr, "action_finished_unit_units",
|
||
"action_finished_unit_stack", "3.3", NULL);
|
||
luascript_signal_create(fcl_main, "action_started_unit_city", 3,
|
||
API_TYPE_ACTION,
|
server/unithand.c | ||
---|---|---|
&& is_action_enabled_unit_on_stack(nmap, action_type, \
|
||
actor_unit, target_tile)) { \
|
||
bool success; \
|
||
script_server_signal_emit("action_started_unit_stack", \
|
||
action_by_number(action), actor, target); \
|
||
script_server_signal_emit("action_started_unit_units", \
|
||
action_by_number(action), actor, target); \
|
||
if (!actor || !unit_is_alive(actor_id)) { \
|
||
... | ... | |
if (success) { \
|
||
action_success_actor_price(paction, actor_id, actor); \
|
||
} \
|
||
script_server_signal_emit("action_finished_unit_stack", \
|
||
action_by_number(action), success, \
|
||
unit_is_alive(actor_id) ? actor : NULL, \
|
||
target); \
|
||
script_server_signal_emit("action_finished_unit_units", \
|
||
action_by_number(action), success, \
|
||
unit_is_alive(actor_id) ? actor : NULL, \
|