[MIRROR] Add missing SIGNAL_HANDLERs [MDB IGNORE] (#8834)

* Add missing SIGNAL_HANDLERs (#62115)

Add missing SIGNAL_HANDLERs

* Add missing SIGNAL_HANDLERs

Co-authored-by: Mothblocks <35135081+Mothblocks@users.noreply.github.com>
This commit is contained in:
SkyratBot
2021-10-15 18:32:41 +02:00
committed by GitHub
parent 177d0d5987
commit 0d5eb8a0c4
13 changed files with 24 additions and 3 deletions

View File

@@ -44,6 +44,7 @@
return ..() //Run parent at end
/datum/ai_controller/hostile_friend/proc/on_prebuckle(mob/source, mob/living/buckler, force, buckle_mob_flags)
SIGNAL_HANDLER
if(force || ai_status == AI_STATUS_OFF)
return
if(WEAKREF(buckler) != blackboard[BB_HOSTILE_FRIEND])

View File

@@ -122,6 +122,8 @@
///Adds an alarm to our alarms list, you shouldn't be calling this manually
///It should all be handled by the signal listening we do, unless you want to only send an alarm to one listener
/datum/alarm_listener/proc/add_alarm(datum/source, datum/alarm_handler/handler, alarm_type, area/source_area, source_z, optional_camera)
SIGNAL_HANDLER
if (!accepting_alarm_changes)
return
@@ -156,6 +158,8 @@
///Removes an alarm to our alarms list, you probably shouldn't be calling this manually
///It should all be handled by the signal listening we do, unless you want to only remove an alarm to one listener
/datum/alarm_listener/proc/clear_alarm(datum/source, datum/alarm_handler/handler, alarm_type, area/source_area)
SIGNAL_HANDLER
if(!accepting_alarm_changes)
return

View File

@@ -95,6 +95,7 @@
start_up(REAGENT_BLOCKER)
/datum/component/rot/proc/check_for_temperature(datum/source, old_temp, new_temp)
SIGNAL_HANDLER
if(new_temp <= T0C-10)
rest(TEMPERATURE_BLOCKER)
return

View File

@@ -74,6 +74,7 @@
///called by linking remotes to tie an assembly to the trapdoor
/datum/component/trapdoor/proc/on_link_requested(datum/source, obj/item/assembly/trapdoor/assembly)
SIGNAL_HANDLER
if(get_dist(parent, assembly) > TRAPDOOR_LINKING_SEARCH_RANGE)
return
. = LINKED_UP

View File

@@ -36,6 +36,8 @@
/datum/element/basic_body_temp_sensitive/proc/on_life(datum/target, delta_time, times_fired)
SIGNAL_HANDLER
var/mob/living/basic/basic_mob = target
var/gave_alert = FALSE

View File

@@ -69,6 +69,7 @@
RegisterSignal(human_holder, COMSIG_SPECIES_GAIN, .proc/on_species_gain)
/datum/quirk/vegetarian/proc/on_species_gain(datum/source, datum/species/new_species, datum/species/old_species)
SIGNAL_HANDLER
new_species.liked_food &= ~MEAT
new_species.disliked_food |= MEAT
@@ -108,6 +109,7 @@
RegisterSignal(human_holder, COMSIG_SPECIES_GAIN, .proc/on_species_gain)
/datum/quirk/pineapple_liker/proc/on_species_gain(datum/source, datum/species/new_species, datum/species/old_species)
SIGNAL_HANDLER
new_species.liked_food |= PINEAPPLE
/datum/quirk/pineapple_liker/remove()
@@ -132,6 +134,7 @@
RegisterSignal(human_holder, COMSIG_SPECIES_GAIN, .proc/on_species_gain)
/datum/quirk/pineapple_hater/proc/on_species_gain(datum/source, datum/species/new_species, datum/species/old_species)
SIGNAL_HANDLER
new_species.disliked_food |= PINEAPPLE
/datum/quirk/pineapple_hater/remove()
@@ -158,6 +161,7 @@
RegisterSignal(human_holder, COMSIG_SPECIES_GAIN, .proc/on_species_gain)
/datum/quirk/deviant_tastes/proc/on_species_gain(datum/source, datum/species/new_species, datum/species/old_species)
SIGNAL_HANDLER
var/liked = new_species.liked_food
new_species.liked_food = new_species.disliked_food
new_species.disliked_food = liked

View File

@@ -9,10 +9,11 @@
RegisterSignal(src, COMSIG_PROJECTILE_ON_HIT, .proc/on_projectile_hit)
/obj/effect/proc_holder/spell/aimed/sdql/proc/on_projectile_hit(source, firer, target)
SIGNAL_HANDLER
var/datum/component/sdql_executor/executor = GetComponent(/datum/component/sdql_executor)
if(!executor)
CRASH("[src]'s SDQL executor component went missing!")
executor.execute(list(target), owner.resolve())
INVOKE_ASYNC(executor, /datum/component/sdql_executor/proc/execute, list(target), owner.resolve())
/obj/effect/proc_holder/spell/aoe_turf/sdql
name = "AoE SDQL Spell"
@@ -140,7 +141,8 @@
user.update_inv_hands()
/obj/effect/proc_holder/spell/targeted/touch/sdql/proc/on_touch_attack(source, target, user)
SIGNAL_HANDLER
var/datum/component/sdql_executor/executor = GetComponent(/datum/component/sdql_executor)
if(!executor)
CRASH("[src]'s SDQL executor component went missing!")
executor.execute(list(target), user)
INVOKE_ASYNC(executor, /datum/component/sdql_executor/proc/execute, list(target), user)

View File

@@ -124,6 +124,7 @@ It's like a regular ol' straight pipe, but you can turn it on and off.
return ..()
/obj/item/circuit_component/digital_valve/proc/handle_valve_toggled(datum/source, on)
SIGNAL_HANDLER
is_open.set_output(on)
if(on)
opened.set_output(COMPONENT_SIGNAL)

View File

@@ -247,7 +247,8 @@
* * user - The user to show the experiment configuration panel to
*/
/datum/component/experiment_handler/proc/configure_experiment_click(datum/source, mob/user)
ui_interact(user)
SIGNAL_HANDLER
INVOKE_ASYNC(src, /datum/proc/ui_interact, user)
/**
* Attempts to link this experiment_handler to a provided techweb

View File

@@ -545,6 +545,7 @@
role_flags |= ROLE_VULNERABLE
/datum/mafia_role/hos/proc/internal_affairs(datum/mafia_controller/game)
SIGNAL_HANDLER
to_chat(body,span_userdanger("You have been killed by Nanotrasen Internal Affairs!"))
reveal_role(game, verbose = TRUE)
kill(game,src,FALSE) //you technically kill yourself but that shouldn't matter

View File

@@ -133,6 +133,7 @@
disconnect(output)
/datum/port/input/proc/disconnect(datum/port/output/output)
SIGNAL_HANDLER
connected_ports -= output
UnregisterSignal(output, COMSIG_PORT_SET_VALUE)
UnregisterSignal(output, COMSIG_PORT_SET_TYPE)

View File

@@ -149,4 +149,5 @@
* * new_value - A boolean that determines if the circuit is locked or not.
**/
/obj/item/circuit_component/money_bot/proc/on_set_locked(datum/source, new_value)
SIGNAL_HANDLER
attached_bot.locked = new_value

View File

@@ -76,4 +76,5 @@
* * new_value - A boolean that determines if the circuit is locked or not.
**/
/obj/item/circuit_component/scanner_gate/proc/on_set_locked(datum/source, new_value)
SIGNAL_HANDLER
attached_gate.locked = new_value