Further runtime fixes by AnturK.
This commit is contained in:
@@ -15,6 +15,7 @@
|
||||
/datum/quirk/New(mob/living/quirk_mob, spawn_effects)
|
||||
if(!quirk_mob || (human_only && !ishuman(quirk_mob)) || quirk_mob.has_quirk(type))
|
||||
qdel(src)
|
||||
return
|
||||
quirk_holder = quirk_mob
|
||||
SSquirks.quirk_objects += src
|
||||
to_chat(quirk_holder, gain_text)
|
||||
|
||||
@@ -527,7 +527,7 @@ GLOBAL_LIST_EMPTY(possible_items)
|
||||
else if(targetinfo.check_special_completion(I))//Returns 1 by default. Items with special checks will return 1 if the conditions are fulfilled.
|
||||
return TRUE
|
||||
|
||||
if(targetinfo && I.type in targetinfo.altitems) //Ok, so you don't have the item. Do you have an alternative, at least?
|
||||
if(targetinfo && (I.type in targetinfo.altitems)) //Ok, so you don't have the item. Do you have an alternative, at least?
|
||||
if(targetinfo.check_special_completion(I))//Yeah, we do! Don't return 0 if we don't though - then you could fail if you had 1 item that didn't pass and got checked first!
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
@@ -319,7 +319,8 @@
|
||||
if(status)
|
||||
change_msg = "reactivates"
|
||||
triggerCameraAlarm()
|
||||
addtimer(CALLBACK(src, .proc/cancelCameraAlarm), 100)
|
||||
if(!QDELETED(src)) //We'll be doing it anyway in destroy
|
||||
addtimer(CALLBACK(src, .proc/cancelCameraAlarm), 100)
|
||||
if(displaymessage)
|
||||
if(user)
|
||||
visible_message("<span class='danger'>[user] [change_msg] [src]!</span>")
|
||||
|
||||
@@ -119,6 +119,9 @@
|
||||
|
||||
if(istype(P, /obj/item/circuitboard/machine))
|
||||
var/obj/item/circuitboard/machine/B = P
|
||||
if(!B.build_path)
|
||||
to_chat(user, "<span class'warning'>This circuitboard seems to be broken.</span>")
|
||||
return
|
||||
if(!anchored && B.needs_anchored)
|
||||
to_chat(user, "<span class='warning'>The frame needs to be secured first!</span>")
|
||||
return
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
var/last_use = 0
|
||||
var/next_use = 0
|
||||
var/obj/effect/abstract/sync_holder/sync_holder
|
||||
var/resync_timer
|
||||
|
||||
/obj/item/desynchronizer/attack_self(mob/living/user)
|
||||
if(world.time < next_use)
|
||||
@@ -56,16 +57,20 @@
|
||||
SEND_SIGNAL(AM, COMSIG_MOVABLE_SECLUDED_LOCATION)
|
||||
last_use = world.time
|
||||
icon_state = "desynchronizer-on"
|
||||
addtimer(CALLBACK(src, .proc/resync), duration)
|
||||
resync_timer = addtimer(CALLBACK(src, .proc/resync), duration , TIMER_STOPPABLE)
|
||||
|
||||
/obj/item/desynchronizer/proc/resync()
|
||||
new /obj/effect/temp_visual/desynchronizer(sync_holder.drop_location())
|
||||
QDEL_NULL(sync_holder)
|
||||
if(resync_timer)
|
||||
deltimer(resync_timer)
|
||||
resync_timer = null
|
||||
icon_state = initial(icon_state)
|
||||
next_use = world.time + (world.time - last_use) // Could be 2*world.time-last_use but that would just be confusing
|
||||
|
||||
/obj/item/desynchronizer/Destroy()
|
||||
resync()
|
||||
if(sync_holder)
|
||||
resync()
|
||||
return ..()
|
||||
|
||||
/obj/effect/abstract/sync_holder
|
||||
|
||||
@@ -42,8 +42,9 @@
|
||||
if(.)
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You take down [src].</span>")
|
||||
victim.forceMove(drop_location())
|
||||
victim = null
|
||||
if(victim)
|
||||
victim.forceMove(drop_location())
|
||||
victim = null
|
||||
spear.forceMove(drop_location())
|
||||
spear = null
|
||||
qdel(src)
|
||||
@@ -29,6 +29,11 @@
|
||||
var/stealth_armor = list("melee" = 15, "bullet" = 15, "laser" = 15, "energy" = 15, "bomb" = 15, "bio" = 15, "rad" = 15, "fire" = 70, "acid" = 70)
|
||||
var/combat_armor = list("melee" = 50, "bullet" = 50, "laser" = 50, "energy" = 50, "bomb" = 50, "bio" = 50, "rad" = 50, "fire" = 90, "acid" = 90)
|
||||
|
||||
/obj/item/clothing/suit/armor/abductor/vest/Initialize()
|
||||
. = ..()
|
||||
stealth_armor = getArmor(arglist(stealth_armor))
|
||||
combat_armor = getArmor(arglist(combat_armor))
|
||||
|
||||
/obj/item/clothing/suit/armor/abductor/vest/proc/toggle_nodrop()
|
||||
if(HAS_TRAIT_FROM(src, TRAIT_NODROP, ABDUCTOR_VEST_TRAIT))
|
||||
REMOVE_TRAIT(src, TRAIT_NODROP, ABDUCTOR_VEST_TRAIT)
|
||||
|
||||
@@ -274,7 +274,8 @@
|
||||
|
||||
/obj/machinery/camera/swarmer_act(mob/living/simple_animal/hostile/swarmer/S)
|
||||
S.DisIntegrate(src)
|
||||
toggle_cam(S, 0)
|
||||
if(!QDELETED(S)) //If it got blown up no need to turn it off.
|
||||
toggle_cam(S, 0)
|
||||
return TRUE
|
||||
|
||||
/obj/machinery/particle_accelerator/control_box/swarmer_act(mob/living/simple_animal/hostile/swarmer/S)
|
||||
|
||||
@@ -18,8 +18,9 @@
|
||||
R.freqlock = TRUE
|
||||
|
||||
var/obj/item/card/id/W = H.wear_id
|
||||
W.registered_name = H.real_name
|
||||
W.update_label(W.registered_name, W.assignment)
|
||||
if(W)
|
||||
W.registered_name = H.real_name
|
||||
W.update_label(W.registered_name, W.assignment)
|
||||
|
||||
/datum/outfit/ert/commander
|
||||
name = "ERT Commander"
|
||||
|
||||
@@ -44,7 +44,8 @@
|
||||
if(M.occupant == src)
|
||||
M.go_out()
|
||||
|
||||
dna.species.spec_death(gibbed, src)
|
||||
if(!QDELETED(dna)) //The gibbed param is bit redundant here since dna won't exist at this point if they got deleted.
|
||||
dna.species.spec_death(gibbed, src)
|
||||
|
||||
if(SSticker.HasRoundStarted())
|
||||
SSblackbox.ReportDeath(src)
|
||||
|
||||
@@ -849,6 +849,8 @@
|
||||
linked_mobs.Add(M)
|
||||
if(!selflink)
|
||||
to_chat(M, "<span class='notice'>You are now connected to [slimelink_owner.real_name]'s Slime Link.</span>")
|
||||
RegisterSignal(M, COMSIG_MOB_DEATH , .proc/unlink_mob)
|
||||
RegisterSignal(M, COMSIG_PARENT_QDELETING, .proc/unlink_mob)
|
||||
var/datum/action/innate/linked_speech/action = new(src)
|
||||
linked_actions.Add(action)
|
||||
action.Grant(M)
|
||||
@@ -858,6 +860,7 @@
|
||||
var/link_id = linked_mobs.Find(M)
|
||||
if(!(link_id))
|
||||
return
|
||||
UnregisterSignal(M, list(COMSIG_MOB_DEATH, COMSIG_PARENT_QDELETING))
|
||||
var/datum/action/innate/linked_speech/action = linked_actions[link_id]
|
||||
action.Remove(M)
|
||||
to_chat(M, "<span class='notice'>You are no longer connected to [slimelink_owner.real_name]'s Slime Link.</span>")
|
||||
@@ -890,18 +893,11 @@
|
||||
Remove(H)
|
||||
return
|
||||
|
||||
if(QDELETED(H) || H.stat == DEAD)
|
||||
species.unlink_mob(H)
|
||||
return
|
||||
|
||||
if(message)
|
||||
var/msg = "<i><font color=#008CA2>\[[species.slimelink_owner.real_name]'s Slime Link\] <b>[H]:</b> [message]</font></i>"
|
||||
log_directed_talk(H, species.slimelink_owner, msg, LOG_SAY, "slime link")
|
||||
for(var/X in species.linked_mobs)
|
||||
var/mob/living/M = X
|
||||
if(QDELETED(M) || M.stat == DEAD)
|
||||
species.unlink_mob(M)
|
||||
continue
|
||||
to_chat(M, msg)
|
||||
|
||||
for(var/X in GLOB.dead_mob_list)
|
||||
|
||||
@@ -34,7 +34,9 @@
|
||||
|
||||
/obj/item/paperplane/handle_atom_del(atom/A)
|
||||
if(A == internalPaper)
|
||||
var/obj/item/paper/P = internalPaper
|
||||
internalPaper = null
|
||||
P.moveToNullspace() //So we're not deleting it twice when deleting our contents.
|
||||
if(!QDELETED(src))
|
||||
qdel(src)
|
||||
return ..()
|
||||
|
||||
Reference in New Issue
Block a user