diff --git a/code/__DEFINES/misc.dm b/code/__DEFINES/misc.dm
index 199535a04e..30672189b4 100644
--- a/code/__DEFINES/misc.dm
+++ b/code/__DEFINES/misc.dm
@@ -425,6 +425,8 @@ GLOBAL_LIST_INIT(ghost_others_options, list(GHOST_OTHERS_SIMPLE, GHOST_OTHERS_DE
//text files
#define BRAIN_DAMAGE_FILE "traumas.json"
+#define ION_FILE "ion_laws.json"
+#define PIRATE_NAMES_FILE "pirates.json"
//Fullscreen overlay resolution in tiles.
#define FULLSCREEN_OVERLAY_RESOLUTION_X 15
diff --git a/code/controllers/subsystem/vote.dm b/code/controllers/subsystem/vote.dm
index acb873dd5b..1a0514b490 100644
--- a/code/controllers/subsystem/vote.dm
+++ b/code/controllers/subsystem/vote.dm
@@ -327,7 +327,7 @@ SUBSYSTEM_DEF(vote)
return 1
/datum/action/vote/proc/remove_from_client()
- if(owner.client)
+ if(owner && owner.client)
owner.client.player_details.player_actions -= src
else if(owner.ckey)
var/datum/player_details/P = GLOB.player_details[owner.ckey]
diff --git a/code/datums/brain_damage/mild.dm b/code/datums/brain_damage/mild.dm
index 9a523cb39f..2631f209cc 100644
--- a/code/datums/brain_damage/mild.dm
+++ b/code/datums/brain_damage/mild.dm
@@ -52,7 +52,7 @@
owner.derpspeech = min(owner.derpspeech + 5, 25)
if(prob(3))
owner.emote("drool")
- else if(owner.stat == CONSCIOUS && prob(3))
+ else if(owner && owner.stat == CONSCIOUS && prob(3))
owner.say(pick_list_replacements(BRAIN_DAMAGE_FILE, "brain_damage"))
..()
@@ -142,13 +142,13 @@
/datum/brain_trauma/mild/muscle_weakness/on_life()
var/fall_chance = 1
- if(owner.m_intent == MOVE_INTENT_RUN)
+ if(owner && owner.m_intent == MOVE_INTENT_RUN)
fall_chance += 2
if(prob(fall_chance) && !owner.lying && !owner.buckled)
to_chat(owner, "Your leg gives out!")
owner.Knockdown(35)
- else if(owner.get_active_held_item())
+ else if(owner && owner.get_active_held_item())
var/drop_chance = 1
var/obj/item/I = owner.get_active_held_item()
drop_chance += I.w_class
@@ -171,11 +171,11 @@
if(prob(7))
switch(rand(1,5))
if(1)
- if(owner.canmove && !isspaceturf(owner.loc))
+ if(owner && owner.canmove && !isspaceturf(owner.loc))
to_chat(owner, "Your leg spasms!")
step(owner, pick(GLOB.cardinals))
if(2)
- if(owner.incapacitated())
+ if(owner && owner.incapacitated())
return
var/obj/item/I = owner.get_active_held_item()
if(I)
@@ -207,7 +207,7 @@
owner.ClickOn(owner)
owner.a_intent = prev_intent
if(5)
- if(owner.incapacitated())
+ if(owner && owner.incapacitated())
return
var/obj/item/I = owner.get_active_held_item()
var/list/turf/targets = list()
diff --git a/code/datums/mood_events/generic_negative_events.dm b/code/datums/mood_events/generic_negative_events.dm
index 786131b7fc..4c39083c62 100644
--- a/code/datums/mood_events/generic_negative_events.dm
+++ b/code/datums/mood_events/generic_negative_events.dm
@@ -84,7 +84,7 @@
mood_change = -3
/datum/mood_event/brain_damage/add_effects()
- var/damage_message = pick_list_replacements("brain_damage_lines.json", "brain_damage")
+ var/damage_message = pick_list_replacements("BRAIN_DAMAGE_FILE", "brain_damage")
description = "Hurr durr... [damage_message]\n"
/datum/mood_event/hulk //Entire duration of having the hulk mutation
diff --git a/code/game/objects/items/devices/dogborg_sleeper.dm b/code/game/objects/items/devices/dogborg_sleeper.dm
index ccb9293cd3..8b51681f86 100644
--- a/code/game/objects/items/devices/dogborg_sleeper.dm
+++ b/code/game/objects/items/devices/dogborg_sleeper.dm
@@ -63,13 +63,12 @@
to_chat(user, "This person is incompatible with our equipment.")
return
if(target.buckled)
- to_chat(user, "The user is buckled and can not be put into your [src.name].")
+ to_chat(user, "The user is buckled and can not be put into your [src].")
return
if(patient)
- to_chat(user, "Your [src.name] is already occupied.")
+ to_chat(user, "Your [src] is already occupied.")
return
- testing("using sleeper/afterattack")
- user.visible_message("[hound.name] is carefully inserting [target.name] into their [src.name].", "You start placing [target] into your [src]...")
+ user.visible_message("[hound.name] is carefully inserting [target.name] into their [src].", "You start placing [target] into your [src]...")
if(!patient && iscarbon(target) && !target.buckled && do_after (user, 50, target = target))
if(!in_range(src, target)) //Proximity is probably old news by now, do a new check.
@@ -109,8 +108,7 @@
go_out()
/obj/item/device/dogborg/sleeper/proc/go_out(var/target)
- hound = src.loc
- testing("go_out activated")
+ hound = loc
hound.setClickCooldown(50)
if(length(contents) > 0)
hound.visible_message("[hound.name] empties out their contents via their release port.", "You empty your contents via your release port.")
@@ -214,20 +212,16 @@
inject_chem(chem)
. = TRUE
if("cleaning")
- testing("cleaning attempted")
if(!contents)
- testing("cleaning has no contents")
to_chat(src, "Your [src] is already cleaned.")
return
if(patient)
- to_chat(patient, "[hound.name]'s [src.name] fills with caustic enzymes around you!")
- testing("clean_cycle activated")
+ to_chat(patient, "[hound.name]'s [src] fills with caustic enzymes around you!")
to_chat(src, "Cleaning process enabled.")
clean_cycle()
. = TRUE
/obj/item/device/dogborg/sleeper/proc/update_gut()
- testing("update_gut proc fired")
//Well, we HAD one, what happened to them?
if(patient in contents)
if(patient_laststat != patient.stat)
@@ -275,66 +269,63 @@
//Gurgleborg process
/obj/item/device/dogborg/sleeper/proc/clean_cycle()
- testing("clean_cycle activated")
//Sanity
for(var/I in items_preserved)
if(!(I in contents))
items_preserved -= I
var/list/touchable_items = contents - items_preserved
if(cleaning_cycles)
- testing("clean_cycle being used")
cleaning_cycles--
cleaning = TRUE
for(var/mob/living/carbon/human/T in (touchable_items))
if((T.status_flags & GODMODE) || !T.digestable)
- src.items_preserved += T
+ items_preserved += T
else
T.adjustBruteLoss(2)
T.adjustFireLoss(3)
update_gut()
-
- var/atom/target = pick(touchable_items)
- if(iscarbon(target)) //Handle the target being a mob
- var/mob/living/carbon/T = target
- if(T.stat == DEAD && T.digestable) //Mob is now dead
- message_admins("[key_name(hound)] has digested [key_name(T)] as a dogborg. ([hound ? "JMP" : "null"])")
- to_chat(hound,"You feel your belly slowly churn around [T], breaking them down into a soft slurry to be used as power for your systems.")
- to_chat(T,"You feel [hound]'s belly slowly churn around your form, breaking you down into a soft slurry to be used as power for [hound]'s systems.")
- src.hound.cell.give(30000) //Fueeeeellll
- T.stop_sound_channel(CHANNEL_PRED)
- playsound(get_turf(hound),"death_pred",50,0,-6,0,channel=CHANNEL_PRED,ignore_walls = FALSE)
- T.stop_sound_channel(CHANNEL_PRED)
- T.playsound_local("death_prey",60)
- for(var/belly in T.vore_organs)
- var/obj/belly/B = belly
- for(var/atom/movable/thing in B)
- thing.forceMove(src)
- if(ismob(thing))
- to_chat(thing, "As [T] melts away around you, you find yourself in [hound]'s [name]")
- for(var/obj/item/W in T)
- if(!T.dropItemToGround(W))
- qdel(W)
- qdel(T)
- update_gut()
- //Handle the target being anything but a mob
- else if(isobj(target))
- var/obj/T = target
- if(T.type in important_items) //If the object is in the items_preserved global list
- src.items_preserved += T
- //If the object is not one to preserve
- else
- qdel(T)
- src.update_gut()
- src.hound.cell.give(10)
+ if(contents)
+ var/atom/target = pick(touchable_items)
+ if(iscarbon(target)) //Handle the target being a mob
+ var/mob/living/carbon/T = target
+ if(T.stat == DEAD && T.digestable) //Mob is now dead
+ message_admins("[key_name(hound)] has digested [key_name(T)] as a dogborg. ([hound ? "JMP" : "null"])")
+ to_chat(hound,"You feel your belly slowly churn around [T], breaking them down into a soft slurry to be used as power for your systems.")
+ to_chat(T,"You feel [hound]'s belly slowly churn around your form, breaking you down into a soft slurry to be used as power for [hound]'s systems.")
+ hound.cell.give(30000) //Fueeeeellll
+ T.stop_sound_channel(CHANNEL_PRED)
+ playsound(get_turf(hound),"death_pred",50,0,-6,0,channel=CHANNEL_PRED,ignore_walls = FALSE)
+ T.stop_sound_channel(CHANNEL_PRED)
+ T.playsound_local("death_prey",60)
+ for(var/belly in T.vore_organs)
+ var/obj/belly/B = belly
+ for(var/atom/movable/thing in B)
+ thing.forceMove(src)
+ if(ismob(thing))
+ to_chat(thing, "As [T] melts away around you, you find yourself in [hound]'s [name]")
+ for(var/obj/item/W in T)
+ if(!T.dropItemToGround(W))
+ qdel(W)
+ qdel(T)
+ update_gut()
+ //Handle the target being anything but a mob
+ else if(isobj(target))
+ var/obj/T = target
+ if(T.type in important_items) //If the object is in the items_preserved global list
+ items_preserved += T
+ //If the object is not one to preserve
+ else
+ qdel(T)
+ update_gut()
+ hound.cell.give(10)
else
- testing("clean_cycle finished and reset")
cleaning_cycles = initial(cleaning_cycles)
cleaning = FALSE
- to_chat(hound, "Your [src.name] chimes it ends its self-cleaning cycle.")//Belly is entirely empty
+ to_chat(hound, "Your [src] chimes it ends its self-cleaning cycle.")//Belly is entirely empty
update_gut()
if(!length(contents))
- to_chat(hound, "Your [src.name] is now clean. Ending self-cleaning cycle.")
+ to_chat(hound, "Your [src] is now clean. Ending self-cleaning cycle.")
cleaning = FALSE
update_gut()
return
@@ -354,19 +345,14 @@
return is_type_in_typecache(I, important_items)
/obj/item/device/dogborg/sleeper/proc/inject_chem(chem)
- testing("inject chem triggered, checking power")
if(hound.cell.charge <= 800) //This is so borgs don't kill themselves with it. Remember, 750 charge used every injection.
to_chat(hound, "You don't have enough power to synthesize fluids.")
return
- testing("Has power, checking for overdose")
if(patient.reagents.get_reagent_amount(chem) + 10 >= 20) //Preventing people from accidentally killing themselves by trying to inject too many chemicals!
to_chat(hound, "Your stomach is currently too full of fluids to secrete more fluids of this kind.")
return
- testing("isn't overdosing, attempting to add_reagent")
patient.reagents.add_reagent(chem, 10)
- testing("add_reagent")
- src.hound.cell.use(750) //-750 charge per injection
- testing("draining power")
+ hound.cell.use(750) //-750 charge per injection
var/units = round(patient.reagents.get_reagent_amount(chem))
to_chat(hound, "Injecting [units] unit\s of [chem] into occupant.") //If they were immersed, the reagents wouldn't leave with them.
@@ -403,15 +389,15 @@
if(iscarbon(target))
var/mob/living/carbon/brigman = target
if (!brigman.devourable)
- to_chat(user, "The target registers an error code. Unable to insert into [src.name].")
+ to_chat(user, "The target registers an error code. Unable to insert into [src].")
return
if(patient)
- to_chat(user,"Your [src.name] is already occupied.")
+ to_chat(user,"Your [src] is already occupied.")
return
if(brigman.buckled)
- to_chat(user,"[brigman] is buckled and can not be put into your [src.name].")
+ to_chat(user,"[brigman] is buckled and can not be put into your [src].")
return
- user.visible_message("[hound.name] is ingesting [brigman] into their [src.name].", "You start ingesting [brigman] into your [src.name]...")
+ user.visible_message("[hound.name] is ingesting [brigman] into their [src].", "You start ingesting [brigman] into your [src.name]...")
if(do_after(user, 30, target = brigman) && !patient && !brigman.buckled)
if(!in_range(src, brigman)) //Proximity is probably old news by now, do a new check.
return //If they moved away, you can't eat them.
@@ -447,18 +433,15 @@
if(target.anchored)
return
if(length(contents) > (max_item_count - 1))
- to_chat(user,"Your [src.name] is full. Eject or process contents to continue.")
+ to_chat(user,"Your [src] is full. Eject or process contents to continue.")
return
if(isobj(target))
- testing("Checking target type")
if(CheckAccepted(target))
- to_chat(user,"\The [target] registers an error code to your [src.name]")
+ to_chat(user,"\The [target] registers an error code to your [src]")
return
- testing("Target not on the important list")
if(target_obj.w_class > WEIGHT_CLASS_NORMAL)
- to_chat(user,"\The [target] is too large to fit into your [src.name]")
+ to_chat(user,"\The [target] is too large to fit into your [src]")
return
- testing("Target not too large.")
user.visible_message("[hound.name] is ingesting [target.name] into their [src.name].", "You start ingesting [target] into your [src.name]...")
if(do_after(user, 15, target = target) && length(contents) < max_item_count)
if(!in_range(src, target)) //Proximity is probably old news by now, do a new check.
@@ -477,15 +460,15 @@
else if(iscarbon(target))
var/mob/living/carbon/trashman = target
if (!trashman.devourable)
- to_chat(user, "\The [target] registers an error code to your [src.name]")
+ to_chat(user, "[target] registers an error code to your [src]")
return
if(patient)
- to_chat(user,"Your [src.name] is already occupied.")
+ to_chat(user,"Your [src] is already occupied.")
return
if(trashman.buckled)
- to_chat(user,"[trashman] is buckled and can not be put into your [src.name].")
+ to_chat(user,"[trashman] is buckled and can not be put into your [src].")
return
- user.visible_message("[hound.name] is ingesting [trashman] into their [src.name].", "You start ingesting [trashman] into your [src.name]...")
+ user.visible_message("[hound.name] is ingesting [trashman] into their [src].", "You start ingesting [trashman] into your [src.name]...")
if(do_after(user, 30, target = trashman) && !patient && !trashman.buckled && length(contents) < max_item_count)
if(!in_range(src, trashman)) //Proximity is probably old news by now, do a new check.
return //If they moved away, you can't eat them.
diff --git a/code/modules/atmospherics/environmental/LINDA_turf_tile.dm b/code/modules/atmospherics/environmental/LINDA_turf_tile.dm
index 138a7a2607..49a9e96fd6 100644
--- a/code/modules/atmospherics/environmental/LINDA_turf_tile.dm
+++ b/code/modules/atmospherics/environmental/LINDA_turf_tile.dm
@@ -254,6 +254,9 @@
if (!M.anchored && !M.pulledby && M.last_high_pressure_movement_air_cycle < SSair.times_fired)
M.experience_pressure_difference(pressure_difference, pressure_direction)
+/turf/closed/proc/high_pressure_movements()
+ return
+
/atom/movable/var/pressure_resistance = 10
/atom/movable/var/last_high_pressure_movement_air_cycle = 0
diff --git a/modular_citadel/code/modules/vore/eating/living_vr.dm b/modular_citadel/code/modules/vore/eating/living_vr.dm
index 5b2ad312ab..c5428650a9 100644
--- a/modular_citadel/code/modules/vore/eating/living_vr.dm
+++ b/modular_citadel/code/modules/vore/eating/living_vr.dm
@@ -324,19 +324,23 @@
// Verb for saving vore preferences to save file
//
/mob/living/proc/save_vore_prefs()
- if(!(client || client.prefs_vr))
+ if(!client)
+ return FALSE
+ if(client && !client.prefs_vr)
return FALSE
if(!copy_to_prefs_vr())
return FALSE
- if(!client.prefs_vr.save_vore())
+ if(client && !client.prefs_vr.save_vore())
return FALSE
return TRUE
/mob/living/proc/apply_vore_prefs()
- if(!(client || client.prefs_vr))
+ if(!client)
return FALSE
- if(!client.prefs_vr.load_vore())
+ if(client && !client.prefs_vr)
+ return FALSE
+ if(client && !client.prefs_vr.load_vore())
return FALSE
if(!copy_from_prefs_vr())
return FALSE
@@ -344,7 +348,9 @@
return TRUE
/mob/living/proc/copy_to_prefs_vr()
- if(!client || !client.prefs_vr)
+ if(!client)
+ return FALSE
+ if(client && !client.prefs_vr)
src << "You attempted to save your vore prefs but somehow you're in this character without a client.prefs_vr variable. Tell a dev."
return FALSE
@@ -367,7 +373,9 @@
// Proc for applying vore preferences, given bellies
//
/mob/living/proc/copy_from_prefs_vr()
- if(!client || !client.prefs_vr)
+ if(!client)
+ return FALSE
+ if(client && !client.prefs_vr)
src << "You attempted to apply your vore prefs but somehow you're in this character without a client.prefs_vr variable. Tell a dev."
return FALSE
@@ -433,7 +441,7 @@
if(src == stat)
return
- src.setClickCooldown(50)
+ src.setClickCooldown(100)
src.visible_message("[src] licks [tasted]!","You lick [tasted]. They taste rather like [tasted.get_taste_message()].","Slurp!")