Merge pull request #1135 from liz-lavenza/fix/upstream-merge-fix

Fix harddel issues with 515 upgrade PR
This commit is contained in:
BongaTheProto
2024-04-07 03:16:55 -05:00
committed by GitHub
31 changed files with 64 additions and 31 deletions
+1
View File
@@ -6,6 +6,7 @@ on:
pull_request:
branches:
- master
- upstream-merge
jobs:
run_linters:
if: "!contains(github.event.head_commit.message, '[ci skip]')"
+5
View File
@@ -132,6 +132,11 @@
src.simulated_only = simulated_only
src.avoid = avoid
/datum/pathfind/Destroy(force, ...)
caller = null
id = null
return ..()
/**
* search() is the proc you call to kick off and handle the actual pathfinding, and kills the pathfind datum instance when it's done.
*
+7 -1
View File
@@ -13,7 +13,13 @@ GLOBAL_REAL(GLOB, /datum/controller/global_vars)
GLOB = src
var/datum/controller/exclude_these = new
gvars_datum_in_built_vars = exclude_these.vars + list(NAMEOF(src, gvars_datum_protected_varlist), NAMEOF(src, gvars_datum_in_built_vars), NAMEOF(src, gvars_datum_init_order))
// I know this is dumb but the nested vars list hangs a ref to the datum. This fixes that
// I have an issue report open, lummox has not responded. It might be a FeaTuRE
// Sooo we gotta be dumb
var/list/controller_vars = exclude_these.vars.Copy()
controller_vars["vars"] = null
gvars_datum_in_built_vars = controller_vars + list(NAMEOF(src, gvars_datum_protected_varlist), NAMEOF(src, gvars_datum_in_built_vars), NAMEOF(src, gvars_datum_init_order))
QDEL_IN(exclude_these, 0) //signal logging isn't ready
log_world("[vars.len - gvars_datum_in_built_vars.len] global variables")
+1 -1
View File
@@ -34,7 +34,7 @@
* ### global proc
* GLOBAL_PROC_REF(procname)
*
* `CALLBACK(src, GLOBAL_PROC_REF(some_proc_here))`
* `CALLBACK(GLOBAL_PROC, GLOBAL_PROC_REF(some_proc_here))`
*
*
* ### proc defined on some type
+1 -1
View File
@@ -436,7 +436,7 @@
if(over_object == M)
user_show_to_mob(M, trigger_on_found = TRUE)
if(isrevenant(M))
INVOKE_ASYNC(GLOBAL_PROC, PROC_REF(RevenantThrow), over_object, M, source)
INVOKE_ASYNC(GLOBAL_PROC, GLOBAL_PROC_REF(RevenantThrow), over_object, M, source)
return
if(check_locked(null, M) || !M.CanReach(A))
return
+1 -1
View File
@@ -37,7 +37,7 @@
if(!(new_z in fitting_z_levels))
return
var/datum/component/our_comp = source.AddComponent(/datum/component/area_sound_manager, playlist, list(), COMSIG_MOB_CLIENT_LOGOUT, fitting_z_levels)
our_comp.RegisterSignal(SSdcs, sound_change_signals, /datum/component/area_sound_manager/proc/handle_change)
our_comp.RegisterSignal(SSdcs, sound_change_signals, TYPE_PROC_REF(/datum/component/area_sound_manager, handle_change))
/datum/element/weather_listener/proc/handle_logout(datum/source, client/this_is_a_null_ref)
SIGNAL_HANDLER
+1 -1
View File
@@ -176,7 +176,7 @@
SEND_SIGNAL(src, COMSIG_MIND_TRANSFER, new_character, old_character)
SEND_SIGNAL(new_character, COMSIG_MOB_ON_NEW_MIND)
//splurt change
INVOKE_ASYNC(GLOBAL_PROC, PROC_REF(_paci_check), new_character, old_character)
INVOKE_ASYNC(GLOBAL_PROC, GLOBAL_PROC_REF(_paci_check), new_character, old_character)
//end change
/datum/mind/proc/store_memory(new_text)
+1 -1
View File
@@ -113,7 +113,7 @@
set_frequency(frequency)
if(closeOtherId != null)
addtimer(CALLBACK(PROC_REF(update_other_id)), 5)
addtimer(CALLBACK(src, PROC_REF(update_other_id)), 5)
if(glass)
airlock_material = "glass"
if(security_level > AIRLOCK_SECURITY_METAL)
@@ -76,10 +76,10 @@
ready_implants--
if(!replenishing && auto_replenish)
replenishing = TRUE
addtimer(CALLBACK(src,"replenish"),replenish_cooldown)
addtimer(CALLBACK(src, PROC_REF(replenish)),replenish_cooldown)
if(injection_cooldown > 0)
ready = FALSE
addtimer(CALLBACK(src,"set_ready"),injection_cooldown)
addtimer(CALLBACK(src, PROC_REF(set_ready)),injection_cooldown)
else
playsound(get_turf(src), 'sound/machines/buzz-sigh.ogg', 25, 1)
update_icon()
@@ -113,7 +113,7 @@
if(ready_implants < max_implants)
ready_implants++
if(ready_implants < max_implants)
addtimer(CALLBACK(src,"replenish"),replenish_cooldown)
addtimer(CALLBACK(src, PROC_REF(replenish)), replenish_cooldown)
else
replenishing = FALSE
+1 -1
View File
@@ -387,7 +387,7 @@ GLOBAL_LIST(topic_status_cache)
if(UNIX) lib = "libprof.so"
else CRASH("unsupported platform")
var/init = call(lib, "init")()
var/init = LIBCALL(lib, "init")()
if("0" != init) CRASH("[lib] init error: [init]")
/world/New()
+1 -1
View File
@@ -215,7 +215,7 @@ GLOBAL_PROTECT(admin_verbs_debug)
/client/proc/discordnulls,
/client/proc/generate_wikichem_list //DO NOT PRESS UNLESS YOU WANT SUPERLAG
)
GLOBAL_LIST_INIT(admin_verbs_possess, list(/proc/possess, GLOBAL_PROC_REF(release)))
GLOBAL_LIST_INIT(admin_verbs_possess, list(/proc/possess, /proc/release))
GLOBAL_PROTECT(admin_verbs_possess)
GLOBAL_LIST_INIT(admin_verbs_permissions, list(/client/proc/edit_admin_permissions))
GLOBAL_PROTECT(admin_verbs_permissions)
+3 -3
View File
@@ -1518,7 +1518,7 @@ Traitors and the like can also be revived with the previous role mostly intact.
if (limb.body_part == HEAD || limb.body_part == CHEST)
continue
addtimer(CALLBACK(limb, TYPE_PROC_REF(/obj/item/bodypart, dismember)), timer)
addtimer(CALLBACK(GLOBAL_PROC, PROC_REF(playsound), carbon_target, 'modular_splurt/sound/effects/cartoon_pop.ogg', 70), timer)
addtimer(CALLBACK(GLOBAL_PROC, GLOBAL_PROC_REF(playsound), carbon_target, 'modular_splurt/sound/effects/cartoon_pop.ogg', 70), timer)
addtimer(CALLBACK(carbon_target, TYPE_PROC_REF(/mob/living, spin), 4, 1), timer - 0.4 SECONDS)
timer += 2 SECONDS
if(ADMIN_PUNISHMENT_BREADIFY)
@@ -1526,14 +1526,14 @@ Traitors and the like can also be revived with the previous role mostly intact.
var/mutable_appearance/bread_appearance = mutable_appearance('icons/obj/food/burgerbread.dmi', "bread")
var/mutable_appearance/transform_scanline = mutable_appearance('modular_splurt/icons/effects/effects.dmi', "transform_effect")
target.transformation_animation(bread_appearance, time = BREADIFY_TIME, transform_overlay=transform_scanline, reset_after=TRUE)
addtimer(CALLBACK(GLOBAL_PROC, PROC_REF(breadify), target), BREADIFY_TIME)
addtimer(CALLBACK(src, PROC_REF(breadify), target), BREADIFY_TIME)
#undef BREADIFY_TIME
if(ADMIN_PUNISHMENT_BOOKIFY)
#define BOOKIFY_TIME (2 SECONDS)
var/mutable_appearance/book_appearance = mutable_appearance('icons/obj/library.dmi', "book")
var/mutable_appearance/transform_scanline = mutable_appearance('modular_splurt/icons/effects/effects.dmi', "transform_effect")
target.transformation_animation(book_appearance, time = BOOKIFY_TIME, transform_overlay=transform_scanline, reset_after=TRUE)
addtimer(CALLBACK(GLOBAL_PROC, PROC_REF(bookify), target), BOOKIFY_TIME)
addtimer(CALLBACK(src, PROC_REF(bookify), target), BOOKIFY_TIME)
playsound(target, 'modular_splurt/sound/misc/bookify.ogg', 60, 1)
#undef BOOKIFY_TIME
if(ADMIN_PUNISHMENT_BONK)
@@ -505,7 +505,7 @@
/obj/machinery/nuclearbomb/proc/really_actually_explode(off_station)
Cinematic(get_cinematic_type(off_station),world,CALLBACK(SSticker, TYPE_PROC_REF(/datum/controller/subsystem/ticker, station_explosion_detonation),src))
INVOKE_ASYNC(GLOBAL_PROC,PROC_REF(KillEveryoneOnZLevel), z)
INVOKE_ASYNC(GLOBAL_PROC, GLOBAL_PROC_REF(KillEveryoneOnZLevel), z)
/obj/machinery/nuclearbomb/proc/get_cinematic_type(off_station)
if(off_station < 2)
@@ -463,7 +463,7 @@ GLOBAL_LIST_INIT(blacklisted_malf_machines, typecacheof(list(
minor_announce("Hostile runtime detected in door controllers. Isolation lockdown protocols are now in effect. Please remain calm.","Network Alert:", TRUE)
to_chat(owner, "<span class='danger'>Lockdown initiated. Network reset in 90 seconds.</span>")
addtimer(CALLBACK(GLOBAL_PROC, PROC_REF(minor_announce),
addtimer(CALLBACK(GLOBAL_PROC, GLOBAL_PROC_REF(minor_announce),
"Automatic system reboot complete. Have a secure day.",
"Network reset:"), 900)
+1 -1
View File
@@ -28,5 +28,5 @@
if(prob(25))//1/4 odds to get a spooky message instead of coughing out loud
addtimer(CALLBACK(GLOBAL_PROC, GLOBAL_PROC_REF(to_chat), onecoughman, "<span class='warning'>[pick("Your head hurts.", "Your head pounds.")]</span>"), rand(30,150))
else
addtimer(CALLBACK(onecoughman, .mob/proc/emote, pick("cough", "sniff", "sneeze")), rand(30,150))//deliver the message with a slightly randomized time interval so there arent multiple people coughing at the exact same time
addtimer(CALLBACK(onecoughman, TYPE_PROC_REF(/mob, emote), pick("cough", "sniff", "sneeze")), rand(30,150))//deliver the message with a slightly randomized time interval so there arent multiple people coughing at the exact same time
fake_virus_victims -= onecoughman
+1
View File
@@ -62,6 +62,7 @@
/mob/living/simple_animal/hostile/mining_drone/Destroy()
for (var/datum/action/innate/minedrone/action in actions)
qdel(action)
QDEL_NULL(stored_gun)
return ..()
/mob/living/simple_animal/hostile/mining_drone/sentience_act()
@@ -365,7 +365,7 @@
var/mob/living/simple_animal/bot/honkbot/S = new(drop_location())
S.name = created_name
S.spam_flag = TRUE // only long enough to hear the first ping.
addtimer(CALLBACK (S, .mob/living/simple_animal/bot/honkbot/proc/react_ping), 5)
addtimer(CALLBACK(S, TYPE_PROC_REF(/mob/living/simple_animal/bot/honkbot, react_ping)), 5)
S.bikehorn = I.type
qdel(I)
qdel(src)
@@ -117,7 +117,7 @@ Difficulty: Normal
..()
/mob/living/simple_animal/hostile/megafauna/hierophant/Destroy()
qdel(spawned_beacon)
QDEL_NULL(spawned_beacon)
. = ..()
/mob/living/simple_animal/hostile/megafauna/hierophant/devour(mob/living/L)
@@ -29,6 +29,11 @@
. = ..()
setup_visuals()
/mob/living/simple_animal/hostile/zombie/Destroy()
if(!QDELETED(corpse))
QDEL_NULL(corpse)
. = ..()
/mob/living/simple_animal/hostile/zombie/proc/setup_visuals()
set waitfor = FALSE
var/datum/preferences/dummy_prefs = new
@@ -58,6 +63,7 @@
. = ..()
corpse.forceMove(drop_location())
corpse.create()
corpse = null
/mob/living/simple_animal/hostile/unemployedclone
name = "Failed clone"
@@ -128,6 +128,11 @@
/mob/living/simple_animal/parrot/proc/toggle_mode,
/mob/living/simple_animal/parrot/proc/perch_mob_player))
/mob/living/simple_animal/parrot/Destroy()
if(ears)
QDEL_NULL(ears)
return ..()
/mob/living/simple_animal/parrot/ComponentInitialize()
. = ..()
AddElement(/datum/element/strippable, GLOB.strippable_parrot_items)
+4 -2
View File
@@ -18,7 +18,9 @@
update_movespeed(TRUE)
initialize_actionspeed()
init_rendering()
hook_vr("mob_new",list(src))
var/list/hook_args = list(src)
hook_vr("mob_new", hook_args)
hook_args.Cut()
/mob/Destroy()//This makes sure that mobs with clients/keys are not just deleted from the game.
// if(client)
@@ -540,7 +542,7 @@
if(send_signal)
SEND_SIGNAL(src, COMSIG_MOB_KEY_CHANGE, new_mob, src)
//splurt changeh
INVOKE_ASYNC(GLOBAL_PROC, PROC_REF(_paci_check), new_mob, src)
INVOKE_ASYNC(GLOBAL_PROC, GLOBAL_PROC_REF(_paci_check), new_mob, src)
//
return TRUE
@@ -38,7 +38,7 @@
integrity_failure = machinery_computer.integrity_failure
base_active_power_usage = machinery_computer.base_active_power_usage
base_idle_power_usage = machinery_computer.base_idle_power_usage
machinery_computer.RegisterSignal(src, COMSIG_ATOM_UPDATED_ICON, /obj/machinery/modular_computer/proc/relay_icon_update) //when we update_icon, also update the computer
machinery_computer.RegisterSignal(src, COMSIG_ATOM_UPDATED_ICON, TYPE_PROC_REF(/obj/machinery/modular_computer, relay_icon_update)) //when we update_icon, also update the computer
/obj/item/modular_computer/processor/relay_qdel()
qdel(machinery_computer)
+1 -1
View File
@@ -242,7 +242,7 @@
H.fakefire()
fulfillContract(H, 1)//Revival contracts are always signed in blood
addtimer(CALLBACK(H, TYPE_PROC_REF(/mob/living/carbon/human, fakefireextinguish)), 5, TIMER_UNIQUE)
addtimer(CALLBACK(src, "resetcooldown"), 300, TIMER_UNIQUE)
addtimer(CALLBACK(src, PROC_REF(resetcooldown)), 30 SECONDS, TIMER_UNIQUE)
else
..()
+1 -1
View File
@@ -161,7 +161,7 @@ GLOBAL_LIST_EMPTY(gravity_generators) // We will keep track of this by adding ne
part.main_part = src
parts += part
part.update_appearance()
part.RegisterSignal(src, COMSIG_ATOM_UPDATED_ICON, /obj/machinery/gravity_generator/part/proc/on_update_icon)
part.RegisterSignal(src, COMSIG_ATOM_UPDATED_ICON, TYPE_PROC_REF(/obj/machinery/gravity_generator/part, on_update_icon))
/obj/machinery/gravity_generator/main/proc/connected_parts()
return parts.len == 8
+1 -1
View File
@@ -214,7 +214,7 @@
/obj/machinery/bsa/full/proc/reload()
ready = FALSE
use_power(power_used_per_shot)
addtimer(CALLBACK(src,"ready_cannon"),600)
addtimer(CALLBACK(src, PROC_REF(ready_cannon)),600)
/obj/machinery/bsa/full/proc/ready_cannon()
ready = TRUE
@@ -43,12 +43,16 @@ GLOBAL_VAR_INIT(running_create_and_destroy, FALSE)
/obj/effect/buildmode_line,
//Spawns it in the wall and shuttle controller runtimes (actually not caught in unit test)
/obj/effect/landmark/latejoin,
// This spawns a map during this test. BAD.
/obj/effect/landmark/mapGenerator,
//Those DAMN SWARMERS ARE EATING EVERYTHING WHILE TEST IS RUNNING
/mob/living/simple_animal/hostile/megafauna/swarmer_swarm_beacon,
// Randomly causes test to fail because of random movement
/obj/item/grenade/clusterbuster/segment,
// With 10% Spawns `while() ... sleep()` proc that causes her hat to harddel // TODO rewrite helmet code attack_self() and port modern /tg/ helmet code
/mob/living/carbon/monkey/angry,
// Literally ends the world.
/obj/singularity/narsie/large/cult,
)
//Say it with me now, type template
ignore += typesof(/obj/effect/mapping_helpers)
@@ -487,7 +487,7 @@
user.last_lewd_datum = src
if(user.cleartimer)
deltimer(user.cleartimer)
user.cleartimer = addtimer(CALLBACK(user, /mob/living/proc/clear_lewd_datum), 300, TIMER_STOPPABLE)
user.cleartimer = addtimer(CALLBACK(user, TYPE_PROC_REF(/mob/living, clear_lewd_datum)), 300, TIMER_STOPPABLE)
return ..()
/mob/living/list_interaction_attributes(mob/living/LM)
@@ -294,10 +294,10 @@
return
if(patient && path.len == 0 && (get_dist(src,patient) > 1))
path = get_path_to(src, get_turf(patient), /turf/proc/Distance_cardinal, 0, 30,id=access_card)
path = get_path_to(src, get_turf(patient), 0, 30,id=access_card)
mode = BOT_MOVING
if(!path.len) //try to get closer if you can't reach the patient directly
path = get_path_to(src, get_turf(patient), /turf/proc/Distance_cardinal, 0, 30,1,id=access_card)
path = get_path_to(src, get_turf(patient), 0, 30,1,id=access_card)
if(!path.len) //Do not chase a patient we cannot reach.
soft_reset()
@@ -22,4 +22,7 @@
. = new /datum/tgs_message_content("Restarting.")
to_chat(world, span_boldwarning("Server restart - Initialized by [sender.friendly_name] on Discord."))
send2adminchat("Server", "[sender.friendly_name] forced a restart.")
addtimer(CALLBACK(src, world.TgsEndProcess()), 1 SECONDS)
addtimer(CALLBACK(src, PROC_REF(DoEndProcess)), 1 SECONDS)
/datum/tgs_chat_command/proc/DoEndProcess()
world.TgsEndProcess()
@@ -27,7 +27,7 @@
if(L.client && !L.client.played)
SEND_SOUND(L, sound(sound, repeat = 0, wait = 0, volume = 35, channel = CHANNEL_AMBIENCE))
L.client.played = TRUE
addtimer(CALLBACK(L.client, /client/proc/ResetAmbiencePlayed), 600)
addtimer(CALLBACK(L.client, TYPE_PROC_REF(/client, ResetAmbiencePlayed)), 600)
if(65 to 70) //Lights flicker.
var/obj/machinery/light/L = locate(/obj/machinery/light) in view(4, C)
if(L)
@@ -365,7 +365,7 @@
if(iszombie(H))
metabolization_rate = 0 //We are born from it.
return
addtimer(CALLBACK(H, /mob/living/carbon/human/proc/undeath, "undeath"), 60 SECONDS)
addtimer(CALLBACK(H, TYPE_PROC_REF(/mob/living/carbon/human, undeath), "undeath"), 60 SECONDS)
if(!istype(H))
return
var/datum/disease/D = new /datum/disease/heart_failure/livingdeath