Merge remote-tracking branch 'upstream/master' into arcade-carpets
This commit is contained in:
@@ -646,23 +646,14 @@ Traitors and the like can also be revived with the previous role mostly intact.
|
||||
if(!check_rights(R_ADMIN))
|
||||
return
|
||||
|
||||
var/heavy = input("Range of heavy pulse.", text("Input")) as num|null
|
||||
if(heavy == null)
|
||||
return
|
||||
var/light = input("Range of light pulse.", text("Input")) as num|null
|
||||
if(light == null)
|
||||
var/range = input("Range.", text("Input")) as num|null
|
||||
if(!range)
|
||||
return
|
||||
log_admin("[key_name(usr)] created an EM Pulse - log below") //because we'll just log the empulse itself
|
||||
message_admins("[key_name_admin(usr)] created an EM Pulse at [AREACOORD(O)] with range [range]")
|
||||
empulse_using_range(O, range, TRUE) //its details get shown too
|
||||
|
||||
if (heavy || light)
|
||||
|
||||
empulse(O, heavy, light)
|
||||
log_admin("[key_name(usr)] created an EM Pulse ([heavy],[light]) at [AREACOORD(O)]")
|
||||
message_admins("[key_name_admin(usr)] created an EM Pulse ([heavy],[light]) at [AREACOORD(O)]")
|
||||
SSblackbox.record_feedback("tally", "admin_verb", 1, "EM Pulse") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
return
|
||||
else
|
||||
return
|
||||
SSblackbox.record_feedback("tally", "admin_verb", 1, "EM Pulse") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
/client/proc/cmd_admin_gib(mob/M in GLOB.mob_list)
|
||||
set category = "Special Verbs"
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
|
||||
/datum/blobstrain/reagent/electromagnetic_web/death_reaction(obj/structure/blob/B, damage_flag)
|
||||
if(damage_flag == "melee" || damage_flag == "bullet" || damage_flag == "laser")
|
||||
empulse(B.loc, 1, 3) //less than screen range, so you can stand out of range to avoid it
|
||||
empulse_using_range(B.loc, 5) //less than screen range, so you can stand out of range to avoid it
|
||||
|
||||
/datum/reagent/blob/electromagnetic_web
|
||||
name = "Electromagnetic Web"
|
||||
@@ -28,6 +28,6 @@
|
||||
/datum/reagent/blob/electromagnetic_web/reaction_mob(mob/living/M, method=TOUCH, reac_volume, show_message, touch_protection, mob/camera/blob/O)
|
||||
reac_volume = ..()
|
||||
if(prob(reac_volume*2))
|
||||
M.emp_act(EMP_LIGHT)
|
||||
M.emp_act(50)
|
||||
if(M)
|
||||
M.apply_damage(reac_volume, BURN, wound_bonus=CANT_WOUND)
|
||||
|
||||
@@ -204,7 +204,7 @@
|
||||
if(severity > 0)
|
||||
if(overmind)
|
||||
overmind.blobstrain.emp_reaction(src, severity)
|
||||
if(prob(100 - severity * 30))
|
||||
if(prob(severity/1.5))
|
||||
new /obj/effect/temp_visual/emp(get_turf(src))
|
||||
|
||||
/obj/structure/blob/zap_act(power)
|
||||
|
||||
@@ -48,6 +48,6 @@
|
||||
for(var/obj/machinery/light/L in range(5, usr))
|
||||
L.on = 1
|
||||
L.break_light_tube()
|
||||
empulse(get_turf(user), 2, 5, 1)
|
||||
empulse_using_range(get_turf(user), 8, TRUE)
|
||||
playsound(get_turf(user), 'sound/effects/lingempscreech.ogg', 75, TRUE, 5, soundenvwet = 0)
|
||||
return TRUE
|
||||
|
||||
@@ -223,7 +223,7 @@
|
||||
L.flash_act(1, 1)
|
||||
if(issilicon(target))
|
||||
var/mob/living/silicon/S = L
|
||||
S.emp_act(EMP_HEAVY)
|
||||
S.emp_act(80)
|
||||
else //for Nar'sian weaklings
|
||||
to_chat(L, "<span class='heavy_brass'>\"How does it feel to see the light, dog?\"</span>")
|
||||
L.visible_message("<span class='warning'>[L]'s eyes flare with burning light!</span>", \
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
/obj/structure/destructible/clockwork/trap/power_nullifier/activate()
|
||||
if(!activated)
|
||||
activated = TRUE
|
||||
empulse(get_turf(src),1,1,TRUE)
|
||||
empulse_using_range(get_turf(src),1,TRUE)
|
||||
|
||||
/obj/structure/destructible/clockwork/trap/power_nullifier/emp_act(var/strength=1)
|
||||
activate()
|
||||
|
||||
@@ -165,7 +165,7 @@
|
||||
/datum/action/innate/cult/blood_spell/emp/Activate()
|
||||
owner.visible_message("<span class='warning'>[owner]'s hand flashes a bright blue!</span>", \
|
||||
"<span class='cultitalic'>You speak the cursed words, emitting an EMP blast from your hand.</span>")
|
||||
empulse(owner, 2, 5)
|
||||
empulse_using_range(owner, 8)
|
||||
owner.whisper(invocation, language = /datum/language/common)
|
||||
charges--
|
||||
if(charges<=0)
|
||||
@@ -451,7 +451,7 @@
|
||||
L.flash_act(1,1)
|
||||
if(issilicon(target))
|
||||
var/mob/living/silicon/S = L
|
||||
S.emp_act(EMP_HEAVY)
|
||||
S.emp_act(80)
|
||||
else if(iscarbon(target))
|
||||
var/mob/living/carbon/C = L
|
||||
C.silent += clamp(12 - C.silent, 0, 6)
|
||||
@@ -610,7 +610,7 @@
|
||||
var/prev_color = candidate.color
|
||||
candidate.color = "black"
|
||||
if(do_after(user, 90, target = candidate))
|
||||
candidate.emp_act(EMP_HEAVY)
|
||||
candidate.emp_act(80)
|
||||
var/construct_class = alert(user, "Please choose which type of construct you wish to create.",,"Juggernaut","Wraith","Artificer")
|
||||
user.visible_message("<span class='danger'>The dark cloud receedes from what was formerly [candidate], revealing a\n [construct_class]!</span>")
|
||||
switch(construct_class)
|
||||
|
||||
@@ -982,7 +982,7 @@ structure_check() searches for nearby cultist structures required for the invoca
|
||||
visible_message("<span class='warning'>A colossal shockwave of energy bursts from the rune, disintegrating it in the process!</span>")
|
||||
for(var/mob/living/L in range(src, 3))
|
||||
L.DefaultCombatKnockdown(30)
|
||||
empulse(T, 0.42*(intensity), 1)
|
||||
empulse_using_range(T, 0.65*(intensity))
|
||||
var/list/images = list()
|
||||
var/zmatch = T.z
|
||||
var/datum/atom_hud/AH = GLOB.huds[DATA_HUD_SECURITY_ADVANCED]
|
||||
|
||||
@@ -424,8 +424,7 @@
|
||||
range = -1
|
||||
include_user = TRUE
|
||||
charge_max = 300
|
||||
emp_heavy = 6
|
||||
emp_light = 10
|
||||
range = 14
|
||||
sound = 'sound/effects/lingscreech.ogg'
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/fire_cascade
|
||||
|
||||
@@ -300,7 +300,7 @@
|
||||
continue
|
||||
to_chat(human, "<span class='revenwarning'>You feel [pick("your sense of direction flicker out", "a stabbing pain in your head", "your mind fill with static")].</span>")
|
||||
new /obj/effect/temp_visual/revenant(human.loc)
|
||||
human.emp_act(EMP_HEAVY)
|
||||
human.emp_act(80)
|
||||
for(var/obj/thing in T)
|
||||
if(istype(thing, /obj/machinery/power/apc) || istype(thing, /obj/machinery/power/smes)) //Doesn't work on SMES and APCs, to prevent kekkery
|
||||
continue
|
||||
@@ -310,12 +310,12 @@
|
||||
thing.emag_act(null)
|
||||
else
|
||||
if(!istype(thing, /obj/machinery/clonepod)) //I hate everything but mostly the fact there's no better way to do this without just not affecting it at all
|
||||
thing.emp_act(EMP_HEAVY)
|
||||
thing.emp_act(80)
|
||||
for(var/mob/living/silicon/robot/S in T) //Only works on cyborgs, not AI
|
||||
playsound(S, 'sound/machines/warning-buzzer.ogg', 50, 1)
|
||||
new /obj/effect/temp_visual/revenant(S.loc)
|
||||
S.spark_system.start()
|
||||
S.emp_act(EMP_HEAVY)
|
||||
S.emp_act(80)
|
||||
|
||||
//Blight: Infects nearby humans and in general messes living stuff up.
|
||||
/obj/effect/proc_holder/spell/aoe_turf/revenant/blight
|
||||
|
||||
@@ -186,6 +186,20 @@ GLOBAL_LIST_INIT(nonreactive_gases, typecacheof(list(/datum/gas/oxygen, /datum/g
|
||||
moles_visible = MOLES_GAS_VISIBLE * 60
|
||||
rarity = 250
|
||||
|
||||
/datum/gas/methane
|
||||
id = "methane"
|
||||
specific_heat = 30
|
||||
name = "Methane"
|
||||
rarity = 320
|
||||
|
||||
/datum/gas/methyl_bromide
|
||||
id = "methyl_bromide"
|
||||
specific_heat = 42
|
||||
name = "Methyl Bromide"
|
||||
dangerous = TRUE
|
||||
rarity = 310
|
||||
|
||||
|
||||
/obj/effect/overlay/gas
|
||||
icon = 'icons/effects/atmospherics.dmi'
|
||||
mouse_opacity = MOUSE_OPACITY_TRANSPARENT
|
||||
|
||||
@@ -97,7 +97,7 @@
|
||||
/datum/gas/oxygen = new/datum/tlv(16, 19, 135, 140), // Partial pressure, kpa
|
||||
/datum/gas/nitrogen = new/datum/tlv(-1, -1, 1000, 1000),
|
||||
/datum/gas/carbon_dioxide = new/datum/tlv(-1, -1, 5, 10),
|
||||
/datum/gas/miasma = new/datum/tlv/(-1, -1, 2, 5),
|
||||
/datum/gas/miasma = new/datum/tlv(-1, -1, 2, 5),
|
||||
/datum/gas/plasma = new/datum/tlv/dangerous,
|
||||
/datum/gas/nitrous_oxide = new/datum/tlv/dangerous,
|
||||
/datum/gas/bz = new/datum/tlv/dangerous,
|
||||
@@ -106,7 +106,9 @@
|
||||
/datum/gas/tritium = new/datum/tlv/dangerous,
|
||||
/datum/gas/stimulum = new/datum/tlv(-1, -1, 1000, 1000), // Stimulum has only positive effects
|
||||
/datum/gas/nitryl = new/datum/tlv/dangerous,
|
||||
/datum/gas/pluoxium = new/datum/tlv(-1, -1, 1000, 1000) // Unlike oxygen, pluoxium does not fuel plasma/tritium fires
|
||||
/datum/gas/pluoxium = new/datum/tlv(-1, -1, 1000, 1000), // Unlike oxygen, pluoxium does not fuel plasma/tritium fires
|
||||
/datum/gas/methane = new/datum/tlv(-1, -1, 3, 6),
|
||||
/datum/gas/methyl_bromide = new/datum/tlv/dangerous
|
||||
)
|
||||
|
||||
/obj/machinery/airalarm/server // No checks here.
|
||||
@@ -125,7 +127,9 @@
|
||||
/datum/gas/tritium = new/datum/tlv/no_checks,
|
||||
/datum/gas/stimulum = new/datum/tlv/no_checks,
|
||||
/datum/gas/nitryl = new/datum/tlv/no_checks,
|
||||
/datum/gas/pluoxium = new/datum/tlv/no_checks
|
||||
/datum/gas/pluoxium = new/datum/tlv/no_checks,
|
||||
/datum/gas/methane = new/datum/tlv/no_checks,
|
||||
/datum/gas/methyl_bromide = new/datum/tlv/no_checks
|
||||
)
|
||||
|
||||
/obj/machinery/airalarm/kitchen_cold_room // Copypasta: to check temperatures.
|
||||
@@ -144,7 +148,9 @@
|
||||
/datum/gas/tritium = new/datum/tlv/dangerous,
|
||||
/datum/gas/stimulum = new/datum/tlv(-1, -1, 1000, 1000), // Stimulum has only positive effects
|
||||
/datum/gas/nitryl = new/datum/tlv/dangerous,
|
||||
/datum/gas/pluoxium = new/datum/tlv(-1, -1, 1000, 1000) // Unlike oxygen, pluoxium does not fuel plasma/tritium fires
|
||||
/datum/gas/pluoxium = new/datum/tlv(-1, -1, 1000, 1000), // Unlike oxygen, pluoxium does not fuel plasma/tritium fires
|
||||
/datum/gas/methane = new/datum/tlv(-1, -1, 3, 6),
|
||||
/datum/gas/methyl_bromide = new/datum/tlv/dangerous
|
||||
)
|
||||
|
||||
/obj/machinery/airalarm/unlocked
|
||||
@@ -542,7 +548,9 @@
|
||||
/datum/gas/tritium,
|
||||
/datum/gas/bz,
|
||||
/datum/gas/stimulum,
|
||||
/datum/gas/pluoxium
|
||||
/datum/gas/pluoxium,
|
||||
/datum/gas/methane,
|
||||
/datum/gas/methyl_bromide
|
||||
),
|
||||
"scrubbing" = 1,
|
||||
"widenet" = 1,
|
||||
|
||||
@@ -50,7 +50,9 @@
|
||||
"stimulum" = /obj/machinery/portable_atmospherics/canister/stimulum,
|
||||
"pluoxium" = /obj/machinery/portable_atmospherics/canister/pluoxium,
|
||||
"caution" = /obj/machinery/portable_atmospherics/canister,
|
||||
"miasma" = /obj/machinery/portable_atmospherics/canister/miasma
|
||||
"miasma" = /obj/machinery/portable_atmospherics/canister/miasma,
|
||||
"methane" = /obj/machinery/portable_atmospherics/canister/methane,
|
||||
"methyl bromide" = /obj/machinery/portable_atmospherics/canister/methyl_bromide
|
||||
)
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/interact(mob/user)
|
||||
@@ -62,7 +64,7 @@
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/nitrogen
|
||||
name = "n2 canister"
|
||||
desc = "Nitrogen gas. Reportedly useful for something."
|
||||
desc = "Nitrogen. Reportedly useful for something."
|
||||
icon_state = "red"
|
||||
gas_type = /datum/gas/nitrogen
|
||||
|
||||
@@ -80,19 +82,19 @@
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/toxins
|
||||
name = "plasma canister"
|
||||
desc = "Plasma gas. The reason YOU are here. Highly toxic."
|
||||
desc = "Plasma. The reason YOU are here. Highly toxic."
|
||||
icon_state = "orange"
|
||||
gas_type = /datum/gas/plasma
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/bz
|
||||
name = "\improper BZ canister"
|
||||
desc = "BZ, a powerful hallucinogenic nerve agent."
|
||||
desc = "BZ. A powerful hallucinogenic nerve agent."
|
||||
icon_state = "purple"
|
||||
gas_type = /datum/gas/bz
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/nitrous_oxide
|
||||
name = "n2o canister"
|
||||
desc = "Nitrous oxide gas. Known to cause drowsiness."
|
||||
desc = "Nitrous oxide. Known to cause drowsiness."
|
||||
icon_state = "redws"
|
||||
gas_type = /datum/gas/nitrous_oxide
|
||||
|
||||
@@ -115,7 +117,7 @@
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/nitryl
|
||||
name = "nitryl canister"
|
||||
desc = "Nitryl gas. Feels great 'til the acid eats your lungs."
|
||||
desc = "Nitryl. Feels great 'til the acid eats your lungs."
|
||||
icon_state = "brown"
|
||||
gas_type = /datum/gas/nitryl
|
||||
|
||||
@@ -133,7 +135,7 @@
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/water_vapor
|
||||
name = "water vapor canister"
|
||||
desc = "Water Vapor. We get it, you vape."
|
||||
desc = "Water vapor. We get it, you vape."
|
||||
icon_state = "water_vapor"
|
||||
gas_type = /datum/gas/water_vapor
|
||||
filled = 1
|
||||
@@ -145,6 +147,18 @@
|
||||
gas_type = /datum/gas/miasma
|
||||
filled = 1
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/methane
|
||||
name = "methane canister"
|
||||
desc = "Methane. The simplest of hydrocarbons. Non-toxic but highly flammable."
|
||||
icon_state = "greyblackred"
|
||||
gas_type = /datum/gas/methane
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/methyl_bromide
|
||||
name = "methyl bromide canister"
|
||||
desc = "Methyl bromide. A potent toxin to most, essential for the Kharmaan to live."
|
||||
icon_state = "purplecyan"
|
||||
gas_type = /datum/gas/methyl_bromide
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/proc/get_time_left()
|
||||
if(timing)
|
||||
. = round(max(0, valve_timer - world.time) / 10, 1)
|
||||
|
||||
@@ -63,9 +63,9 @@
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
if(is_operational())
|
||||
if(prob(50 / severity))
|
||||
if(prob(severity/2))
|
||||
on = !on
|
||||
if(prob(100 / severity))
|
||||
if(prob(severity))
|
||||
direction = PUMP_OUT
|
||||
pump.target_pressure = rand(0, 100 * ONE_ATMOSPHERE)
|
||||
update_icon()
|
||||
@@ -80,7 +80,6 @@
|
||||
else if(on && holding && direction == PUMP_OUT)
|
||||
investigate_log("[key_name(user)] started a transfer into [holding].", INVESTIGATE_ATMOS)
|
||||
|
||||
|
||||
/obj/machinery/portable_atmospherics/pump/ui_interact(mob/user, datum/tgui/ui)
|
||||
ui = SStgui.try_update_ui(user, src, ui)
|
||||
if(!ui)
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
if(is_operational())
|
||||
if(prob(50 / severity))
|
||||
if(prob(severity/3))
|
||||
on = !on
|
||||
update_icon()
|
||||
|
||||
|
||||
@@ -8,6 +8,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
var/client/parent
|
||||
//doohickeys for savefiles
|
||||
var/path
|
||||
var/vr_path
|
||||
var/default_slot = 1 //Holder so it doesn't default to slot 1, rather the last one used
|
||||
var/max_save_slots = 16
|
||||
|
||||
@@ -544,7 +545,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
|
||||
if(length(pref_species.allowed_limb_ids))
|
||||
if(!chosen_limb_id || !(chosen_limb_id in pref_species.allowed_limb_ids))
|
||||
chosen_limb_id = pref_species.id
|
||||
chosen_limb_id = pref_species.limbs_id || pref_species.id
|
||||
dat += "<h3>Body sprite</h3>"
|
||||
dat += "<a style='display:block;width:100px' href='?_src_=prefs;preference=bodysprite;task=input'>[chosen_limb_id]</a>"
|
||||
|
||||
|
||||
@@ -212,26 +212,31 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
if(!ckey)
|
||||
return
|
||||
path = "data/player_saves/[ckey[1]]/[ckey]/[filename]"
|
||||
vr_path = "data/player_saves/[ckey[1]]/[ckey]/vore"
|
||||
|
||||
/datum/preferences/proc/load_preferences()
|
||||
if(!path)
|
||||
return 0
|
||||
return FALSE
|
||||
if(world.time < loadprefcooldown)
|
||||
if(istype(parent))
|
||||
to_chat(parent, "<span class='warning'>You're attempting to load your preferences a little too fast. Wait half a second, then try again.</span>")
|
||||
return 0
|
||||
return FALSE
|
||||
loadprefcooldown = world.time + PREF_SAVELOAD_COOLDOWN
|
||||
if(!fexists(path))
|
||||
return 0
|
||||
return FALSE
|
||||
|
||||
var/savefile/S = new /savefile(path)
|
||||
if(!S)
|
||||
return 0
|
||||
return FALSE
|
||||
S.cd = "/"
|
||||
|
||||
var/needs_update = savefile_needs_update(S)
|
||||
if(needs_update == -2) //fatal, can't load any data
|
||||
return 0
|
||||
var/bacpath = "[path].updatebac" //todo: if the savefile version is higher then the server, check the backup, and give the player a prompt to load the backup
|
||||
if (fexists(bacpath))
|
||||
fdel(bacpath) //only keep 1 version of backup
|
||||
fcopy(S, bacpath) //byond helpfully lets you use a savefile for the first arg.
|
||||
return FALSE
|
||||
|
||||
. = TRUE
|
||||
|
||||
@@ -293,8 +298,14 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
|
||||
//try to fix any outdated data if necessary
|
||||
if(needs_update >= 0)
|
||||
var/bacpath = "[path].updatebac" //todo: if the savefile version is higher then the server, check the backup, and give the player a prompt to load the backup
|
||||
if (fexists(bacpath))
|
||||
fdel(bacpath) //only keep 1 version of backup
|
||||
fcopy(S, bacpath) //byond helpfully lets you use a savefile for the first arg.
|
||||
update_preferences(needs_update, S) //needs_update = savefile_version if we need an update (positive integer)
|
||||
|
||||
|
||||
|
||||
//Sanitize
|
||||
ooccolor = sanitize_ooccolor(sanitize_hexcolor(ooccolor, 6, 1, initial(ooccolor)))
|
||||
lastchangelog = sanitize_text(lastchangelog, initial(lastchangelog))
|
||||
@@ -336,7 +347,25 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
|
||||
verify_keybindings_valid() // one of these days this will runtime and you'll be glad that i put it in a different proc so no one gets their saves wiped
|
||||
|
||||
return 1
|
||||
if(needs_update >= 0) //save the updated version
|
||||
var/old_default_slot = default_slot
|
||||
var/old_max_save_slots = max_save_slots
|
||||
|
||||
for (var/slot in S.dir) //but first, update all current character slots.
|
||||
if (copytext(slot, 1, 10) != "character")
|
||||
continue
|
||||
var/slotnum = text2num(copytext(slot, 10))
|
||||
if (!slotnum)
|
||||
continue
|
||||
max_save_slots = max(max_save_slots, slotnum) //so we can still update byond member slots after they lose memeber status
|
||||
default_slot = slotnum
|
||||
if (load_character()) // this updtates char slots
|
||||
save_character()
|
||||
default_slot = old_default_slot
|
||||
max_save_slots = old_max_save_slots
|
||||
save_preferences()
|
||||
|
||||
return TRUE
|
||||
|
||||
/datum/preferences/proc/verify_keybindings_valid()
|
||||
// Sanitize the actual keybinds to make sure they exist.
|
||||
@@ -426,17 +455,17 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
|
||||
/datum/preferences/proc/load_character(slot)
|
||||
if(!path)
|
||||
return 0
|
||||
return FALSE
|
||||
if(world.time < loadcharcooldown) //This is before the check to see if the filepath exists to ensure that BYOND can't get hung up on read attempts when the hard drive is a little slow
|
||||
if(istype(parent))
|
||||
to_chat(parent, "<span class='warning'>You're attempting to load your character a little too fast. Wait half a second, then try again.</span>")
|
||||
return "SLOW THE FUCK DOWN" //the reason this isn't null is to make sure that people don't have their character slots overridden by random chars if they accidentally double-click a slot
|
||||
loadcharcooldown = world.time + PREF_SAVELOAD_COOLDOWN
|
||||
if(!fexists(path))
|
||||
return 0
|
||||
return FALSE
|
||||
var/savefile/S = new /savefile(path)
|
||||
if(!S)
|
||||
return 0
|
||||
return FALSE
|
||||
S.cd = "/"
|
||||
if(!slot)
|
||||
slot = default_slot
|
||||
@@ -448,7 +477,7 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
S.cd = "/character[slot]"
|
||||
var/needs_update = savefile_needs_update(S)
|
||||
if(needs_update == -2) //fatal, can't load any data
|
||||
return 0
|
||||
return FALSE
|
||||
|
||||
. = TRUE
|
||||
|
||||
@@ -466,7 +495,7 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
pref_species = new newtype
|
||||
|
||||
|
||||
scars_index = rand(1,5)
|
||||
scars_index = rand(1,5) // WHY
|
||||
|
||||
//Character
|
||||
S["real_name"] >> real_name
|
||||
@@ -481,7 +510,7 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
S["hair_color"] >> hair_color
|
||||
S["facial_hair_color"] >> facial_hair_color
|
||||
S["left_eye_color"] >> left_eye_color
|
||||
S["right_eye_color"] >> left_eye_color
|
||||
S["right_eye_color"] >> right_eye_color
|
||||
S["use_custom_skin_tone"] >> use_custom_skin_tone
|
||||
S["skin_tone"] >> skin_tone
|
||||
S["hair_style_name"] >> hair_style
|
||||
@@ -609,8 +638,11 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
|
||||
S["vore_flags"] >> vore_flags
|
||||
S["vore_taste"] >> vore_taste
|
||||
S["belly_prefs"] >> belly_prefs
|
||||
|
||||
var/char_vr_path = "[vr_path]/character_[default_slot]_v2.json"
|
||||
if(fexists(char_vr_path))
|
||||
var/list/json_from_file = json_decode(file2text(char_vr_path))
|
||||
if(json_from_file)
|
||||
belly_prefs = json_from_file["belly_prefs"]
|
||||
//gear loadout
|
||||
var/text_to_load
|
||||
S["loadout"] >> text_to_load
|
||||
@@ -627,6 +659,7 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
gear_points -= init_cost
|
||||
|
||||
//try to fix any outdated data if necessary
|
||||
//preference updating will handle saving the updated data for us.
|
||||
if(needs_update >= 0)
|
||||
update_character(needs_update, S) //needs_update == savefile_version if we need an update (positive integer)
|
||||
|
||||
@@ -877,7 +910,11 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
|
||||
WRITE_FILE(S["vore_flags"] , vore_flags)
|
||||
WRITE_FILE(S["vore_taste"] , vore_taste)
|
||||
WRITE_FILE(S["belly_prefs"] , belly_prefs)
|
||||
var/char_vr_path = "[vr_path]/character_[default_slot]_v2.json"
|
||||
var/belly_prefs_json = safe_json_encode(list("belly_prefs" = belly_prefs))
|
||||
if(fexists(char_vr_path))
|
||||
fdel(char_vr_path)
|
||||
text2file(belly_prefs_json,char_vr_path)
|
||||
|
||||
WRITE_FILE(S["persistent_scars"] , persistent_scars)
|
||||
WRITE_FILE(S["scars1"] , scars_list["1"])
|
||||
|
||||
@@ -62,13 +62,12 @@
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
var/mob/living/carbon/human/user = src.loc
|
||||
switch(severity)
|
||||
if(1)
|
||||
if(activated && user && ishuman(user) && (user.wear_suit == src))
|
||||
to_chat(user, "<span class='danger'>E:FATAL:RAM_READ_FAIL\nE:FATAL:STACK_EMPTY\nE:FATAL:READ_NULL_POINT\nE:FATAL:PWR_BUS_OVERLOAD</span>")
|
||||
to_chat(user, "<span class='userdanger'>An electromagnetic pulse disrupts your [name] and violently tears you out of time-bluespace!</span>")
|
||||
user.emote("scream")
|
||||
deactivate(1, 1)
|
||||
if(severity >= 70)
|
||||
if(activated && user && ishuman(user) && (user.wear_suit == src))
|
||||
to_chat(user, "<span class='danger'>E:FATAL:RAM_READ_FAIL\nE:FATAL:STACK_EMPTY\nE:FATAL:READ_NULL_POINT\nE:FATAL:PWR_BUS_OVERLOAD</span>")
|
||||
to_chat(user, "<span class='userdanger'>An electromagnetic pulse disrupts your [name] and violently tears you out of time-bluespace!</span>")
|
||||
user.emote("scream")
|
||||
deactivate(1, 1)
|
||||
|
||||
/obj/item/clothing/suit/space/chronos/proc/finish_chronowalk(mob/living/carbon/human/user, turf/to_turf)
|
||||
if(!user)
|
||||
|
||||
@@ -525,7 +525,7 @@ Contains:
|
||||
icon_state = "hunter"
|
||||
item_state = "swat_suit"
|
||||
allowed = list(/obj/item/gun, /obj/item/ammo_box, /obj/item/ammo_casing, /obj/item/melee/baton, /obj/item/restraints/handcuffs, /obj/item/tank/internals, /obj/item/kitchen/knife/combat)
|
||||
armor = list("melee" = 60, "bullet" = 40, "laser" = 40, "energy" = 50, "bomb" = 100, "bio" = 100, "rad" = 100, "fire" = 100, "acid" = 100, "wpound" = 25)
|
||||
armor = list("melee" = 60, "bullet" = 40, "laser" = 40, "energy" = 50, "bomb" = 100, "bio" = 100, "rad" = 100, "fire" = 100, "acid" = 100, "wound" = 25)
|
||||
strip_delay = 130
|
||||
resistance_flags = FIRE_PROOF | ACID_PROOF
|
||||
|
||||
|
||||
@@ -102,3 +102,20 @@
|
||||
/obj/item/clothing/neck/cloak/polychromic/ComponentInitialize()
|
||||
. = ..()
|
||||
AddElement(/datum/element/polychromic, poly_colors, 3)
|
||||
|
||||
/obj/item/clothing/neck/cloak/alt
|
||||
name = "cloak"
|
||||
desc = "A ragged up white cloak. It reminds you of a place not far from here."
|
||||
icon_state = "cloak"
|
||||
item_state = "cloak"
|
||||
|
||||
/obj/item/clothing/neck/cloak/alt/polychromic
|
||||
name = "polychromic cloak"
|
||||
desc = "A ragged up cloak. It reminds you of a place not far from here."
|
||||
icon_state = "cloak"
|
||||
item_state = "cloak"
|
||||
var/list/poly_colors = list("#FFFFFF", "#676767", "#4C4C4C")
|
||||
|
||||
/obj/item/clothing/neck/cloak/alt/polychromic/ComponentInitialize()
|
||||
. = ..()
|
||||
AddElement(/datum/element/polychromic, poly_colors, 3)
|
||||
|
||||
@@ -33,6 +33,13 @@
|
||||
fitted = FEMALE_UNIFORM_TOP
|
||||
mutantrace_variation = STYLE_DIGITIGRADE|STYLE_NO_ANTHRO_ICON
|
||||
|
||||
/obj/item/clothing/under/rank/cargo/tech/long
|
||||
name = "cargo technician's jumpsuit (trousers)"
|
||||
desc = "A variant of the cargo technician's uniform with proper trousers, suited for colder climates and modest workers."
|
||||
icon_state = "cargo_long"
|
||||
item_state = "lb_suit"
|
||||
alt_covers_chest = TRUE
|
||||
|
||||
/obj/item/clothing/under/rank/cargo/miner
|
||||
name = "shaft miner's jumpsuit"
|
||||
desc = "It's a snappy jumpsuit with a sturdy set of overalls. It is very dirty."
|
||||
|
||||
@@ -23,4 +23,4 @@
|
||||
|
||||
/datum/round_event/communications_blackout/start()
|
||||
for(var/obj/machinery/telecomms/T in GLOB.telecomms_list)
|
||||
T.emp_act(EMP_HEAVY)
|
||||
T.emp_act(80)
|
||||
|
||||
@@ -141,7 +141,7 @@
|
||||
for(var/obj/machinery/rnd/server/S in GLOB.machines)
|
||||
if(S.stat & (NOPOWER|BROKEN))
|
||||
continue
|
||||
S.emp_act(1)
|
||||
S.emp_act(80)
|
||||
new /obj/effect/temp_visual/emp(get_turf(S))
|
||||
|
||||
/obj/machinery/shuttle_scrambler/proc/dump_loot(mob/user)
|
||||
|
||||
@@ -36,4 +36,4 @@
|
||||
// at all
|
||||
P.ex_act(EXPLODE_DEVASTATE)
|
||||
else
|
||||
P.emp_act(EMP_HEAVY)
|
||||
P.emp_act(80)
|
||||
|
||||
@@ -893,7 +893,8 @@
|
||||
if(issilicon(user)) //How does AI know what plant is?
|
||||
return
|
||||
if(harvest)
|
||||
return myseed.harvest(user)
|
||||
myseed.harvest(user)
|
||||
return
|
||||
|
||||
else if(dead)
|
||||
dead = 0
|
||||
|
||||
@@ -59,3 +59,17 @@
|
||||
var/mob/living/silicon/robot/R = user.mob
|
||||
R.uneq_active()
|
||||
return TRUE
|
||||
|
||||
/datum/keybinding/robot/drone/can_use(client/user)
|
||||
return isdrone(user.mob)
|
||||
|
||||
/datum/keybinding/robot/drone/quick_equip_drone // QOL: Drone quickequip
|
||||
hotkey_keys = list("E")
|
||||
name = "quick_equip_drone"
|
||||
full_name = "Quick Equip (Drone)"
|
||||
description = "Quickly puts an item in the best slot available"
|
||||
|
||||
/datum/keybinding/robot/drone/quick_equip_drone/down(client/user)
|
||||
var/mob/living/simple_animal/drone/D = user.mob
|
||||
D.quick_equip()
|
||||
return TRUE
|
||||
@@ -61,24 +61,18 @@
|
||||
playsound(src,'sound/effects/sparks4.ogg',50,1)
|
||||
qdel(src)
|
||||
|
||||
/obj/item/wormhole_jaunter/emp_act(power)
|
||||
/obj/item/wormhole_jaunter/emp_act(severity)
|
||||
. = ..()
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
|
||||
var/mob/M = loc
|
||||
if(istype(M))
|
||||
var/triggered = FALSE
|
||||
if(M.get_item_by_slot(SLOT_BELT) == src)
|
||||
if(power == 1)
|
||||
triggered = TRUE
|
||||
else if(power == 2 && prob(50))
|
||||
triggered = TRUE
|
||||
|
||||
if(triggered)
|
||||
M.visible_message("<span class='warning'>[src] overloads and activates!</span>")
|
||||
SSblackbox.record_feedback("tally", "jaunter", 1, "EMP") // EMP accidental activation
|
||||
activate(M)
|
||||
if(prob(severity))
|
||||
M.visible_message("<span class='warning'>[src] overloads and activates!</span>")
|
||||
SSblackbox.record_feedback("tally", "jaunter", 1, "EMP") // EMP accidental activation
|
||||
activate(M)
|
||||
|
||||
/obj/item/wormhole_jaunter/proc/chasm_react(mob/source, datum/component/chasm/C)
|
||||
to_chat(source, "Your [name] activates, saving you from the chasm!</span>")
|
||||
|
||||
@@ -169,13 +169,7 @@
|
||||
if(!brainmob || iscyborg(loc))
|
||||
return
|
||||
else
|
||||
switch(severity)
|
||||
if(1)
|
||||
brainmob.emp_damage = min(brainmob.emp_damage + rand(20,30), 30)
|
||||
if(2)
|
||||
brainmob.emp_damage = min(brainmob.emp_damage + rand(10,20), 30)
|
||||
if(3)
|
||||
brainmob.emp_damage = min(brainmob.emp_damage + rand(0,10), 30)
|
||||
brainmob.emp_damage = min(brainmob.emp_damage + rand(-5,5) + severity/3, 30)
|
||||
brainmob.emote("alarm")
|
||||
|
||||
/obj/item/mmi/Destroy()
|
||||
|
||||
@@ -412,13 +412,8 @@
|
||||
if(!informed)
|
||||
to_chat(src, "<span class='userdanger'>You feel a sharp pain as your robotic limbs overload.</span>")
|
||||
informed = TRUE
|
||||
switch(severity)
|
||||
if(1)
|
||||
L.receive_damage(0,10)
|
||||
Stun(200)
|
||||
if(2)
|
||||
L.receive_damage(0,5)
|
||||
Stun(100)
|
||||
L.receive_damage(0,severity/10)
|
||||
Stun(severity*2)
|
||||
|
||||
/mob/living/carbon/human/acid_act(acidpwr, acid_volume, bodyzone_hit)
|
||||
var/list/damaged = list()
|
||||
|
||||
@@ -96,6 +96,8 @@
|
||||
throw_alert("not_enough_co2", /obj/screen/alert/not_enough_co2)
|
||||
else if(S.breathid == "n2")
|
||||
throw_alert("not_enough_nitro", /obj/screen/alert/not_enough_nitro)
|
||||
else if(S.breathid == "ch3br")
|
||||
throw_alert("not_enough_ch3br", /obj/screen/alert/not_enough_ch3br)
|
||||
|
||||
return FALSE
|
||||
else
|
||||
|
||||
@@ -362,10 +362,11 @@ GLOBAL_LIST_EMPTY(roundstart_race_names)
|
||||
if(H.client && has_field_of_vision && CONFIG_GET(flag/use_field_of_vision))
|
||||
H.LoadComponent(/datum/component/field_of_vision, H.field_of_vision_type)
|
||||
|
||||
C.add_or_update_variable_movespeed_modifier(/datum/movespeed_modifier/species, TRUE, multiplicative_slowdown = speedmod)
|
||||
|
||||
update_species_slowdown(C)
|
||||
SEND_SIGNAL(C, COMSIG_SPECIES_GAIN, src, old_species)
|
||||
|
||||
/datum/species/proc/update_species_slowdown(mob/living/carbon/human/H)
|
||||
H.add_or_update_variable_movespeed_modifier(/datum/movespeed_modifier/species, TRUE, multiplicative_slowdown = speedmod)
|
||||
|
||||
// EDIT ENDS
|
||||
|
||||
|
||||
@@ -141,4 +141,5 @@
|
||||
H.setMovetype(H.movement_type & ~FLYING)
|
||||
override_float = FALSE
|
||||
H.pass_flags &= ~PASSTABLE
|
||||
H.CloseWings()
|
||||
H.CloseWings()
|
||||
update_species_slowdown(H)
|
||||
|
||||
@@ -84,11 +84,7 @@
|
||||
EMPeffect = TRUE
|
||||
spec_updatehealth(H)
|
||||
to_chat(H, "<span class='notice'>You feel the light of your body leave you.</span>")
|
||||
switch(severity)
|
||||
if(EMP_LIGHT)
|
||||
addtimer(CALLBACK(src, .proc/stop_emp, H), 10 SECONDS, TIMER_UNIQUE|TIMER_OVERRIDE) //We're out for 10 seconds
|
||||
if(EMP_HEAVY)
|
||||
addtimer(CALLBACK(src, .proc/stop_emp, H), 20 SECONDS, TIMER_UNIQUE|TIMER_OVERRIDE) //We're out for 20 seconds
|
||||
addtimer(CALLBACK(src, .proc/stop_emp, H), (severity/5) SECONDS, TIMER_UNIQUE|TIMER_OVERRIDE) //lights out
|
||||
|
||||
/datum/species/ethereal/proc/on_emag_act(mob/living/carbon/human/H, mob/user)
|
||||
if(emageffect)
|
||||
|
||||
@@ -249,6 +249,8 @@
|
||||
var/mob/living/carbon/human/spare = new /mob/living/carbon/human(H.loc)
|
||||
|
||||
spare.underwear = "Nude"
|
||||
spare.undershirt = "Nude"
|
||||
spare.socks = "Nude"
|
||||
H.dna.transfer_identity(spare, transfer_SE=1)
|
||||
spare.dna.features["mcolor"] = pick("FFFFFF","7F7F7F", "7FFF7F", "7F7FFF", "FF7F7F", "7FFFFF", "FF7FFF", "FFFF7F")
|
||||
spare.real_name = spare.dna.real_name
|
||||
@@ -435,6 +437,8 @@
|
||||
heatmod = 1
|
||||
burnmod = 1
|
||||
|
||||
allowed_limb_ids = list("slime","stargazer","lum")
|
||||
|
||||
/datum/action/innate/slime_change
|
||||
name = "Alter Form"
|
||||
check_flags = AB_CHECK_CONSCIOUS
|
||||
|
||||
@@ -184,7 +184,7 @@
|
||||
else if(isliving(AM))
|
||||
var/mob/living/L = AM
|
||||
if(isethereal(AM))
|
||||
AM.emp_act(EMP_LIGHT)
|
||||
AM.emp_act(50)
|
||||
if(iscyborg(AM))
|
||||
var/mob/living/silicon/robot/borg = AM
|
||||
if(borg.lamp_intensity)
|
||||
|
||||
@@ -227,6 +227,21 @@
|
||||
return
|
||||
else if(isinsect(C))
|
||||
playsound(C, 'sound/voice/moth/mothlaugh.ogg', 50, 1)
|
||||
else if(isjellyperson(C))
|
||||
var/mob/living/carbon/human/H = C
|
||||
if(H.dna.features["mam_ears"] == "Cat" || H.dna.features["mam_ears"] == "Cat, Big") //slime have cat ear. slime go nya.
|
||||
playsound(C, pick('sound/voice/jelly/nyahaha1.ogg',
|
||||
'sound/voice/jelly/nyahaha2.ogg',
|
||||
'sound/voice/jelly/nyaha.ogg',
|
||||
'sound/voice/jelly/nyahehe.ogg'),
|
||||
50, 1)
|
||||
return
|
||||
else if(user.gender == FEMALE)
|
||||
playsound(C, 'sound/voice/jelly/womanlaugh.ogg', 50, 1)
|
||||
return
|
||||
else
|
||||
playsound(C, pick('sound/voice/jelly/manlaugh1.ogg', 'sound/voice/jelly/manlaugh2.ogg'), 50, 1)
|
||||
return
|
||||
else if(ishumanbasic(C))
|
||||
if(user.gender == FEMALE)
|
||||
playsound(C, 'sound/voice/human/womanlaugh.ogg', 50, 1)
|
||||
|
||||
@@ -19,13 +19,14 @@
|
||||
. = ..()
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
disconnect_shell()
|
||||
if (prob(30))
|
||||
switch(pick(1,2))
|
||||
if(1)
|
||||
view_core()
|
||||
if(2)
|
||||
SSshuttle.requestEvac(src,"ALERT: Energy surge detected in AI core! Station integrity may be compromised! Initiati--%m091#ar-BZZT")
|
||||
if(severity >= 60)
|
||||
disconnect_shell()
|
||||
if(prob(30))
|
||||
switch(pick(1,2))
|
||||
if(1)
|
||||
view_core()
|
||||
if(2)
|
||||
SSshuttle.requestEvac(src,"ALERT: Energy surge detected in AI core! Station integrity may be compromised! Initiati--%m091#ar-BZZT")
|
||||
|
||||
/mob/living/silicon/ai/ex_act(severity, target)
|
||||
switch(severity)
|
||||
|
||||
@@ -7,8 +7,8 @@
|
||||
. = ..()
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
take_holo_damage(50/severity)
|
||||
DefaultCombatKnockdown(400/severity)
|
||||
take_holo_damage(severity/2)
|
||||
DefaultCombatKnockdown(severity*4)
|
||||
silent = max(silent, (PAI_EMP_SILENCE_DURATION) / SSmobs.wait / severity)
|
||||
if(holoform)
|
||||
fold_in(force = TRUE)
|
||||
|
||||
@@ -85,12 +85,7 @@
|
||||
. = ..()
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
switch(severity)
|
||||
if(1)
|
||||
Paralyze(160)
|
||||
if(2)
|
||||
Paralyze(60)
|
||||
|
||||
Paralyze(10 + severity/1.2)
|
||||
|
||||
/mob/living/silicon/robot/emag_act(mob/user)
|
||||
if(user == src)//To prevent syndieborgs from emagging themselves
|
||||
|
||||
@@ -105,14 +105,10 @@
|
||||
to_chat(src, "<span class='danger'>Warning: Electromagnetic pulse detected.</span>")
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
switch(severity)
|
||||
if(1)
|
||||
src.take_bodypart_damage(20)
|
||||
if(2)
|
||||
src.take_bodypart_damage(10)
|
||||
src.take_bodypart_damage(severity/5)
|
||||
to_chat(src, "<span class='userdanger'>*BZZZT*</span>")
|
||||
for(var/mob/living/M in buckled_mobs)
|
||||
if(prob(severity*50))
|
||||
if(prob(severity/2))
|
||||
unbuckle_mob(M)
|
||||
M.DefaultCombatKnockdown(40)
|
||||
M.visible_message("<span class='boldwarning'>[M] is thrown off of [src]!</span>",
|
||||
|
||||
@@ -370,7 +370,7 @@
|
||||
ejectpai(0)
|
||||
if(on)
|
||||
turn_off()
|
||||
spawn(severity*300)
|
||||
spawn(3 * severity)
|
||||
stat &= ~EMPED
|
||||
if(was_on)
|
||||
turn_on()
|
||||
@@ -1060,4 +1060,4 @@ Pass a positive integer as an argument to override a bot's default speed.
|
||||
path.Cut(1, 2)
|
||||
|
||||
/mob/living/silicon/rust_heretic_act()
|
||||
adjustBruteLoss(500)
|
||||
adjustBruteLoss(500)
|
||||
|
||||
@@ -459,12 +459,10 @@ Auto Patrol[]"},
|
||||
|
||||
|
||||
/mob/living/simple_animal/bot/ed209/emp_act(severity)
|
||||
if(severity == 2 && prob(70))
|
||||
severity = 1
|
||||
. = ..()
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
if (severity >= 2)
|
||||
if (severity >= 65)
|
||||
new /obj/effect/temp_visual/emp(loc)
|
||||
var/list/mob/living/carbon/targets = new
|
||||
for(var/mob/living/carbon/C in view(12,src))
|
||||
|
||||
@@ -729,7 +729,6 @@
|
||||
if(load)
|
||||
load.emp_act(severity)
|
||||
|
||||
|
||||
/mob/living/simple_animal/bot/mulebot/explode()
|
||||
visible_message("<span class='boldannounce'>[src] blows apart!</span>")
|
||||
var/atom/Tsec = drop_location()
|
||||
|
||||
@@ -220,11 +220,10 @@
|
||||
return
|
||||
Stun(100)
|
||||
to_chat(src, "<span class='danger'><b>ER@%R: MME^RY CO#RU9T!</b> R&$b@0tin)...</span>")
|
||||
if(severity == 1)
|
||||
if(severity >= 65)
|
||||
adjustBruteLoss(heavy_emp_damage)
|
||||
to_chat(src, "<span class='userdanger'>HeAV% DA%^MMA+G TO I/O CIR!%UUT!</span>")
|
||||
|
||||
|
||||
/mob/living/simple_animal/drone/proc/triggerAlarm(class, area/A, O, obj/alarmsource)
|
||||
if(alarmsource.z != z)
|
||||
return
|
||||
@@ -240,7 +239,6 @@
|
||||
L[A.name] = list(A, list(alarmsource))
|
||||
to_chat(src, "--- [class] alarm detected in [A.name]!")
|
||||
|
||||
|
||||
/mob/living/simple_animal/drone/proc/cancelAlarm(class, area/A, obj/origin)
|
||||
if(stat != DEAD)
|
||||
var/list/L = alarms[class]
|
||||
|
||||
@@ -80,7 +80,9 @@
|
||||
if(C.can_absorb_dna(owner))
|
||||
C.add_new_profile(owner)
|
||||
|
||||
C.purchasedpowers += new /obj/effect/proc_holder/changeling/humanform(null)
|
||||
var/obj/effect/proc_holder/changeling/humanform/hf = new
|
||||
C.purchasedpowers += hf
|
||||
hf.on_purchase(origin.current, TRUE)
|
||||
M.key = origin.key
|
||||
owner.gib()
|
||||
|
||||
|
||||
@@ -485,11 +485,13 @@ mob/visible_message(message, self_message, blind_message, vision_distance = DEFA
|
||||
if(!ckey)
|
||||
return
|
||||
SEND_SIGNAL(new_mob, COMSIG_MOB_PRE_PLAYER_CHANGE, new_mob, src)
|
||||
if (client && client.prefs && client.prefs.auto_ooc)
|
||||
if (client.prefs.chat_toggles & CHAT_OOC && isliving(new_mob))
|
||||
client.prefs.chat_toggles ^= CHAT_OOC
|
||||
if (!(client.prefs.chat_toggles & CHAT_OOC) && isdead(new_mob))
|
||||
client.prefs.chat_toggles ^= CHAT_OOC
|
||||
if (client)
|
||||
if(client.prefs?.auto_ooc)
|
||||
if (client.prefs.chat_toggles & CHAT_OOC && isliving(new_mob))
|
||||
client.prefs.chat_toggles ^= CHAT_OOC
|
||||
if (!(client.prefs.chat_toggles & CHAT_OOC) && isdead(new_mob))
|
||||
client.prefs.chat_toggles ^= CHAT_OOC
|
||||
client.change_view(CONFIG_GET(string/default_view))
|
||||
new_mob.ckey = ckey
|
||||
if(send_signal)
|
||||
SEND_SIGNAL(src, COMSIG_MOB_KEY_CHANGE, new_mob, src)
|
||||
|
||||
@@ -6,5 +6,5 @@
|
||||
if(!ninjacost(250,N_STEALTH_CANCEL))
|
||||
var/mob/living/carbon/human/H = affecting
|
||||
playsound(H.loc, 'sound/effects/empulse.ogg', 60, 2)
|
||||
empulse(H, 4, 6) //Procs sure are nice. Slightly weaker than wizard's disable tch.
|
||||
empulse_using_range(H, 9) //Procs sure are nice. Slightly weaker than wizard's disable tch.
|
||||
s_coold = 2
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
/obj/machinery/hydroponics/constructable/automagic
|
||||
name = "automated hydroponics system"
|
||||
desc = "The bane of botanists everywhere. Accepts chemical reagents via plumbing, automatically harvests and removes dead plants."
|
||||
icon_state = "hydrotray4"
|
||||
obj_flags = CAN_BE_HIT | UNIQUE_RENAME
|
||||
circuit = /obj/item/circuitboard/machine/hydroponics/automagic
|
||||
self_sufficiency_req = 400 //automating hydroponics makes gaia sad so she needs more drugs to turn they tray godly.
|
||||
@@ -31,11 +32,12 @@
|
||||
. = ..()
|
||||
START_PROCESSING(SSobj, src)
|
||||
create_reagents(100 , AMOUNT_VISIBLE)
|
||||
AddComponent(/datum/component/plumbing/simple_demand)
|
||||
|
||||
/obj/machinery/hydroponics/constructable/automagic/ComponentInitialize()
|
||||
. = ..()
|
||||
AddComponent(/datum/component/simple_rotation, ROTATION_ALTCLICK | ROTATION_CLOCKWISE | ROTATION_COUNTERCLOCKWISE | ROTATION_VERBS, null, CALLBACK(src, .proc/can_be_rotated))
|
||||
AddComponent(/datum/component/plumbing/simple_demand)
|
||||
|
||||
|
||||
/obj/machinery/hydroponics/constructable/proc/can_be_rotated(mob/user, rotation_type)
|
||||
return !anchored
|
||||
|
||||
@@ -30,7 +30,6 @@
|
||||
|
||||
var/stored_power = 0//Power to deploy per tick
|
||||
|
||||
|
||||
/obj/machinery/power/am_control_unit/Initialize()
|
||||
. = ..()
|
||||
linked_shielding = list()
|
||||
@@ -44,7 +43,6 @@
|
||||
QDEL_NULL(fueljar)
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/machinery/power/am_control_unit/process()
|
||||
if(exploding)
|
||||
explosion(get_turf(src),8,12,18,12)
|
||||
@@ -72,7 +70,6 @@
|
||||
|
||||
return
|
||||
|
||||
|
||||
/obj/machinery/power/am_control_unit/proc/produce_power()
|
||||
playsound(src.loc, 'sound/effects/bang.ogg', 25, 1)
|
||||
var/core_power = reported_core_efficiency//Effectively how much fuel we can safely deal with
|
||||
@@ -103,15 +100,9 @@
|
||||
. = ..()
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
switch(severity)
|
||||
if(1)
|
||||
if(active)
|
||||
toggle_power()
|
||||
stability -= rand(15,30)
|
||||
if(2)
|
||||
if(active)
|
||||
toggle_power()
|
||||
stability -= rand(10,20)
|
||||
if(active)
|
||||
toggle_power()
|
||||
stability -= rand(round(severity/5),round(severity/3))
|
||||
|
||||
/obj/machinery/power/am_control_unit/blob_act()
|
||||
stability -= 20
|
||||
@@ -123,20 +114,17 @@
|
||||
check_stability()
|
||||
return
|
||||
|
||||
|
||||
/obj/machinery/power/am_control_unit/ex_act(severity, target)
|
||||
stability -= (80 - (severity * 20))
|
||||
check_stability()
|
||||
return
|
||||
|
||||
|
||||
/obj/machinery/power/am_control_unit/bullet_act(obj/item/projectile/Proj)
|
||||
. = ..()
|
||||
if(Proj.flag != "bullet")
|
||||
stability -= Proj.force
|
||||
check_stability()
|
||||
|
||||
|
||||
/obj/machinery/power/am_control_unit/power_change()
|
||||
..()
|
||||
if(stat & NOPOWER)
|
||||
@@ -150,7 +138,6 @@
|
||||
|
||||
return
|
||||
|
||||
|
||||
/obj/machinery/power/am_control_unit/update_icon_state()
|
||||
if(active)
|
||||
icon_state = "control_on"
|
||||
@@ -158,7 +145,6 @@
|
||||
icon_state = "control"
|
||||
//No other icons for it atm
|
||||
|
||||
|
||||
/obj/machinery/power/am_control_unit/attackby(obj/item/W, mob/user, params)
|
||||
if(istype(W, /obj/item/wrench))
|
||||
if(!anchored)
|
||||
@@ -192,7 +178,6 @@
|
||||
else
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/machinery/power/am_control_unit/take_damage(damage, damage_type = BRUTE, sound_effect = 1)
|
||||
switch(damage_type)
|
||||
if(BRUTE)
|
||||
@@ -221,7 +206,6 @@
|
||||
update_shield_icons = 1
|
||||
return 1
|
||||
|
||||
|
||||
/obj/machinery/power/am_control_unit/proc/remove_shielding(obj/machinery/am_shielding/AMS)
|
||||
if(!istype(AMS))
|
||||
return 0
|
||||
@@ -231,13 +215,11 @@
|
||||
toggle_power()
|
||||
return 1
|
||||
|
||||
|
||||
/obj/machinery/power/am_control_unit/proc/check_stability()//TODO: make it break when low also might want to add a way to fix it like a part or such that can be replaced
|
||||
if(stability <= 0)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
|
||||
/obj/machinery/power/am_control_unit/proc/toggle_power(powerfail = 0)
|
||||
active = !active
|
||||
if(active)
|
||||
@@ -249,7 +231,6 @@
|
||||
update_icon()
|
||||
return
|
||||
|
||||
|
||||
/obj/machinery/power/am_control_unit/proc/check_shield_icons()//Forces icon_update for all shields
|
||||
if(shield_icon_delay)
|
||||
return
|
||||
|
||||
@@ -1449,7 +1449,7 @@
|
||||
environ = 0
|
||||
update_icon()
|
||||
update()
|
||||
addtimer(CALLBACK(src, .proc/reset, APC_RESET_EMP), 600)
|
||||
addtimer(CALLBACK(src, .proc/reset, APC_RESET_EMP), severity*8)
|
||||
|
||||
/obj/machinery/power/apc/blob_act(obj/structure/blob/B)
|
||||
set_broken()
|
||||
|
||||
@@ -136,8 +136,8 @@
|
||||
. = ..()
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
charge -= 1000 / severity
|
||||
if (charge < 0)
|
||||
charge -= 10 * severity
|
||||
if(charge < 0)
|
||||
charge = 0
|
||||
|
||||
/obj/item/stock_parts/cell/ex_act(severity, target)
|
||||
@@ -359,7 +359,7 @@
|
||||
. = ..()
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
charge = clamp((charge-(10000/severity)),0,maxcharge)
|
||||
charge = clamp((charge-(100*severity)),0,maxcharge)
|
||||
|
||||
/obj/item/stock_parts/cell/emergency_light
|
||||
name = "miniature power cell"
|
||||
|
||||
@@ -209,7 +209,7 @@
|
||||
if(obj_flags & EMAGGED)
|
||||
return
|
||||
obj_flags |= EMAGGED
|
||||
emp_act(EMP_HEAVY)
|
||||
emp_act(100)
|
||||
|
||||
/obj/machinery/power/port_gen/pacman/attack_ai(mob/user)
|
||||
interact(user)
|
||||
|
||||
@@ -434,7 +434,7 @@
|
||||
|
||||
|
||||
/obj/singularity/proc/emp_area()
|
||||
empulse(src, 8, 10)
|
||||
empulse_using_range(src, 10)
|
||||
return
|
||||
|
||||
/obj/singularity/singularity_act()
|
||||
|
||||
@@ -407,7 +407,7 @@
|
||||
outputting = output_attempt
|
||||
output_level = rand(0, output_level_max)
|
||||
input_level = rand(0, input_level_max)
|
||||
charge -= 1e6/severity
|
||||
charge -= 10000*severity
|
||||
if (charge < 0)
|
||||
charge = 0
|
||||
update_icon()
|
||||
|
||||
@@ -346,7 +346,7 @@
|
||||
if(issilicon(closest_mob))
|
||||
var/mob/living/silicon/S = closest_mob
|
||||
if((zap_flags & ZAP_MOB_STUN) && (zap_flags & ZAP_MOB_DAMAGE))
|
||||
S.emp_act(EMP_LIGHT)
|
||||
S.emp_act(50)
|
||||
next_range = 7 // metallic folks bounce it further
|
||||
else
|
||||
next_range = 5
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
/obj/item/gun/energy/emp_act(severity)
|
||||
. = ..()
|
||||
if(!(. & EMP_PROTECT_CONTENTS))
|
||||
cell.use(round(cell.charge / severity))
|
||||
cell.use(round(cell.charge * severity/100))
|
||||
chambered = null //we empty the chamber
|
||||
recharge_newshot() //and try to charge a new shot
|
||||
update_icon()
|
||||
|
||||
@@ -132,7 +132,7 @@
|
||||
. = ..()
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
fail_chance = min(fail_chance + round(15/severity), 100)
|
||||
fail_chance = min(fail_chance + round(severity/6.6), 100)
|
||||
|
||||
/obj/item/gun/energy/e_gun/nuclear/update_overlays()
|
||||
. = ..()
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
|
||||
/obj/item/projectile/ion/on_hit(atom/target, blocked = FALSE)
|
||||
..()
|
||||
empulse(target, emp_radius, emp_radius)
|
||||
empulse_using_range(target, emp_radius)
|
||||
return BULLET_ACT_HIT
|
||||
|
||||
/obj/item/projectile/ion/weak
|
||||
|
||||
@@ -32,14 +32,13 @@
|
||||
/obj/machinery/smoke_machine/Initialize()
|
||||
. = ..()
|
||||
create_reagents(REAGENTS_BASE_VOLUME)
|
||||
// AddComponent(/datum/component/plumbing/simple_demand)
|
||||
for(var/obj/item/stock_parts/matter_bin/B in component_parts)
|
||||
reagents.maximum_volume += REAGENTS_BASE_VOLUME * B.rating
|
||||
AddComponent(/datum/component/plumbing/simple_demand)
|
||||
|
||||
/obj/machinery/smoke_machine/ComponentInitialize()
|
||||
. = ..()
|
||||
AddComponent(/datum/component/simple_rotation, ROTATION_ALTCLICK | ROTATION_CLOCKWISE | ROTATION_COUNTERCLOCKWISE | ROTATION_VERBS, null, CALLBACK(src, .proc/can_be_rotated))
|
||||
AddComponent(/datum/component/plumbing/simple_demand) //this SURELY CANT' LEAD TO BAD THINGS HAPPENING.
|
||||
|
||||
/obj/machinery/smoke_machine/proc/can_be_rotated(mob/user, rotation_type)
|
||||
return !anchored
|
||||
|
||||
@@ -114,12 +114,9 @@
|
||||
|
||||
/datum/chemical_reaction/emp_pulse/on_reaction(datum/reagents/holder, multiplier)
|
||||
var/location = get_turf(holder.my_atom)
|
||||
// 100 multiplier = 4 heavy range & 7 light range. A few tiles smaller than traitor EMP grandes.
|
||||
// 200 multiplier = 8 heavy range & 14 light range. 4 tiles larger than traitor EMP grenades.
|
||||
empulse(location, round(multiplier / 12), round(multiplier / 7), 1)
|
||||
empulse(location, multiplier)
|
||||
holder.clear_reagents()
|
||||
|
||||
|
||||
/datum/chemical_reaction/beesplosion
|
||||
name = "Bee Explosion"
|
||||
id = "beesplosion"
|
||||
|
||||
@@ -296,7 +296,7 @@
|
||||
required_other = TRUE
|
||||
|
||||
/datum/chemical_reaction/slime/slimeoverload/on_reaction(datum/reagents/holder, multiplier)
|
||||
empulse(get_turf(holder.my_atom), 3, 7)
|
||||
empulse_using_range(get_turf(holder.my_atom), 10)
|
||||
..()
|
||||
|
||||
/datum/chemical_reaction/slime/slimecell
|
||||
|
||||
@@ -328,7 +328,7 @@
|
||||
throwSmoke(loc)
|
||||
else if(prob(EFFECT_PROB_MEDIUM-badThingCoeff))
|
||||
visible_message("<span class='warning'>[src] melts [exp_on], ionizing the air around it!</span>")
|
||||
empulse(loc, 4, 6)
|
||||
empulse_using_range(loc, 9)
|
||||
investigate_log("Experimentor has generated an Electromagnetic Pulse.", INVESTIGATE_EXPERIMENTOR)
|
||||
ejectItem(TRUE)
|
||||
////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
@@ -123,7 +123,7 @@
|
||||
rogue_types = list(/datum/nanite_program/toxic)
|
||||
|
||||
/datum/nanite_program/emp/on_trigger(comm_message)
|
||||
empulse(host_mob, 1, 2)
|
||||
empulse_using_range(host_mob, 3)
|
||||
|
||||
/datum/nanite_program/pyro/active_effect()
|
||||
host_mob.fire_stacks += 1
|
||||
|
||||
@@ -40,12 +40,12 @@
|
||||
else
|
||||
working = TRUE
|
||||
|
||||
/obj/machinery/rnd/server/emp_act()
|
||||
/obj/machinery/rnd/server/emp_act(severity)
|
||||
. = ..()
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
stat |= EMPED
|
||||
addtimer(CALLBACK(src, .proc/unemp), 600)
|
||||
addtimer(CALLBACK(src, .proc/unemp), severity*9)
|
||||
refresh_working()
|
||||
|
||||
/obj/machinery/rnd/server/proc/unemp()
|
||||
|
||||
@@ -258,7 +258,7 @@
|
||||
if(SLIME_ACTIVATE_MAJOR)
|
||||
user.visible_message("<span class='warning'>[user]'s skin starts flashing intermittently...</span>", "<span class='warning'>Your skin starts flashing intermittently...</span>")
|
||||
if(do_after(user, 25, target = user))
|
||||
empulse(user, 1, 2)
|
||||
empulse_using_range(user, 3)
|
||||
user.visible_message("<span class='warning'>[user]'s skin flashes!</span>", "<span class='warning'>Your skin flashes as you emit an electromagnetic pulse!</span>")
|
||||
return 600
|
||||
|
||||
|
||||
@@ -3,9 +3,7 @@
|
||||
desc = "This spell emplodes an area."
|
||||
charge_max = 250
|
||||
cooldown_min = 50
|
||||
|
||||
var/emp_heavy = 2
|
||||
var/emp_light = 3
|
||||
var/emp_range = 4 //same as a 50/50 reaction of uranium and iron
|
||||
|
||||
action_icon_state = "emp"
|
||||
sound = 'sound/weapons/zapbang.ogg'
|
||||
@@ -15,6 +13,6 @@
|
||||
for(var/mob/living/target in targets)
|
||||
if(target.anti_magic_check())
|
||||
continue
|
||||
empulse(target.loc, emp_heavy, emp_light)
|
||||
empulse_using_range(target.loc, emp_range)
|
||||
|
||||
return
|
||||
return
|
||||
|
||||
@@ -96,8 +96,7 @@
|
||||
include_user = 1
|
||||
cooldown_min = 200 //50 deciseconds reduction per rank
|
||||
|
||||
emp_heavy = 6
|
||||
emp_light = 10
|
||||
range = 14
|
||||
sound = 'sound/magic/disable_tech.ogg'
|
||||
|
||||
/obj/effect/proc_holder/spell/targeted/turf_teleport/blink
|
||||
|
||||
@@ -355,7 +355,7 @@
|
||||
else
|
||||
damage = min(damage, WOUND_MAX_CONSIDERED_DAMAGE)
|
||||
|
||||
var/base_roll = rand(max(damage/1.5,25), round(damage ** WOUND_DAMAGE_EXPONENT))
|
||||
var/base_roll = rand(max(damage/1.5,25), round(damage ** CONFIG_GET(number/wound_exponent))) + (get_damage()*CONFIG_GET(number/wound_damage_multiplier))
|
||||
var/injury_roll = base_roll
|
||||
injury_roll += check_woundings_mods(woundtype, damage, wound_bonus, bare_wound_bonus)
|
||||
var/list/wounds_checking = GLOB.global_wound_types[woundtype]
|
||||
|
||||
@@ -33,10 +33,9 @@
|
||||
. = ..()
|
||||
if(!owner || . & EMP_PROTECT_SELF)
|
||||
return
|
||||
owner.reagents.add_reagent(/datum/reagent/toxin/bad_food, poison_amount / severity)
|
||||
owner.reagents.add_reagent(/datum/reagent/toxin/bad_food, poison_amount * severity/100)
|
||||
to_chat(owner, "<span class='warning'>You feel like your insides are burning.</span>")
|
||||
|
||||
|
||||
/obj/item/organ/cyberimp/chest/nutriment/plus
|
||||
name = "Nutriment pump implant PLUS"
|
||||
desc = "This implant will synthesize and pump into your bloodstream a small amount of nutriment when you are hungry."
|
||||
@@ -115,10 +114,10 @@
|
||||
|
||||
if(ishuman(owner))
|
||||
var/mob/living/carbon/human/H = owner
|
||||
if(H.stat != DEAD && prob(50 / severity) && H.can_heartattack())
|
||||
if(H.stat != DEAD && prob(severity/2) && H.can_heartattack())
|
||||
H.set_heartattack(TRUE)
|
||||
to_chat(H, "<span class='userdanger'>You feel a horrible agony in your chest!</span>")
|
||||
addtimer(CALLBACK(src, .proc/undo_heart_attack), 60 SECONDS / severity)
|
||||
addtimer(CALLBACK(src, .proc/undo_heart_attack), (60 * severity/100) SECONDS)
|
||||
|
||||
/obj/item/organ/cyberimp/chest/reviver/proc/undo_heart_attack()
|
||||
var/mob/living/carbon/human/H = owner
|
||||
|
||||
@@ -34,11 +34,10 @@
|
||||
. = ..()
|
||||
if(!owner || . & EMP_PROTECT_SELF)
|
||||
return
|
||||
var/stun_amount = 200/severity
|
||||
var/stun_amount = 2*severity
|
||||
owner.Stun(stun_amount)
|
||||
to_chat(owner, "<span class='warning'>Your body seizes up!</span>")
|
||||
|
||||
|
||||
/obj/item/organ/cyberimp/brain/anti_drop
|
||||
name = "anti-drop implant"
|
||||
desc = "This cybernetic brain implant will allow you to force your hand muscles to contract, preventing item dropping. Twitch ear to toggle."
|
||||
@@ -68,12 +67,11 @@
|
||||
release_items()
|
||||
to_chat(owner, "<span class='notice'>Your hands relax...</span>")
|
||||
|
||||
|
||||
/obj/item/organ/cyberimp/brain/anti_drop/emp_act(severity)
|
||||
. = ..()
|
||||
if(!owner || . & EMP_PROTECT_SELF)
|
||||
return
|
||||
var/range = severity ? 10 : 5
|
||||
var/range = severity/10
|
||||
var/atom/A
|
||||
if(active)
|
||||
release_items()
|
||||
@@ -114,7 +112,7 @@
|
||||
return
|
||||
crit_fail = TRUE
|
||||
organ_flags |= ORGAN_FAILING
|
||||
addtimer(CALLBACK(src, .proc/reboot), 90 / severity)
|
||||
addtimer(CALLBACK(src, .proc/reboot), 0.9 * severity)
|
||||
|
||||
/obj/item/organ/cyberimp/brain/anti_stun/proc/reboot()
|
||||
crit_fail = FALSE
|
||||
@@ -136,6 +134,6 @@
|
||||
. = ..()
|
||||
if(!owner || . & EMP_PROTECT_SELF)
|
||||
return
|
||||
if(prob(60/severity))
|
||||
if(prob(0.6*severity))
|
||||
to_chat(owner, "<span class='warning'>Your breathing tube suddenly closes!</span>")
|
||||
owner.losebreath += 2
|
||||
|
||||
@@ -131,4 +131,4 @@
|
||||
. = ..()
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
damage += 40/severity
|
||||
damage += 0.5 * severity
|
||||
|
||||
@@ -166,7 +166,7 @@
|
||||
return
|
||||
to_chat(owner, "<span class='warning'>Static obfuscates your vision!</span>")
|
||||
owner.flash_act(visual = 1)
|
||||
if(severity == EMP_HEAVY)
|
||||
if(severity >= 70)
|
||||
owner.adjustOrganLoss(ORGAN_SLOT_EYES, 20)
|
||||
|
||||
|
||||
|
||||
@@ -198,8 +198,8 @@ obj/item/organ/heart/slime
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
Stop()
|
||||
addtimer(CALLBACK(src, .proc/Restart), 20/severity SECONDS)
|
||||
damage += 100/severity
|
||||
addtimer(CALLBACK(src, .proc/Restart), 0.2*severity SECONDS)
|
||||
damage += severity
|
||||
|
||||
/obj/item/organ/heart/cybernetic/upgraded
|
||||
name = "upgraded cybernetic heart"
|
||||
|
||||
@@ -112,8 +112,4 @@
|
||||
. = ..()
|
||||
if(. & EMP_PROTECT_SELF)
|
||||
return
|
||||
switch(severity)
|
||||
if(1)
|
||||
damage+=100
|
||||
if(2)
|
||||
damage+=50
|
||||
damage += severity
|
||||
|
||||
@@ -36,6 +36,10 @@
|
||||
var/safe_co2_max = 10 // Yes it's an arbitrary value who cares?
|
||||
var/safe_toxins_min = 0
|
||||
var/safe_toxins_max = MOLES_GAS_VISIBLE
|
||||
var/safe_ch3br_min = 0
|
||||
var/safe_ch3br_max = 1 //problematic even at low concentrations
|
||||
var/safe_methane_min = 0
|
||||
var/safe_methane_max = 0
|
||||
var/SA_para_min = 1 //Sleeping agent
|
||||
var/SA_sleep_min = 5 //Sleeping agent
|
||||
var/BZ_trip_balls_min = 1 //BZ gas
|
||||
@@ -53,6 +57,9 @@
|
||||
var/tox_breath_dam_min = MIN_TOXIC_GAS_DAMAGE
|
||||
var/tox_breath_dam_max = MAX_TOXIC_GAS_DAMAGE
|
||||
var/tox_damage_type = TOX
|
||||
var/methane_breath_dam_min = MIN_TOXIC_GAS_DAMAGE
|
||||
var/methane_breath_dam_max = MAX_TOXIC_GAS_DAMAGE
|
||||
var/methane_damage_type = OXY
|
||||
|
||||
var/cold_message = "your face freezing and an icicle forming"
|
||||
var/cold_level_1_threshold = 260
|
||||
@@ -129,6 +136,8 @@
|
||||
H.throw_alert("not_enough_co2", /obj/screen/alert/not_enough_co2)
|
||||
else if(safe_nitro_min)
|
||||
H.throw_alert("not_enough_nitro", /obj/screen/alert/not_enough_nitro)
|
||||
else if(safe_ch3br_min)
|
||||
H.throw_alert("not_enough_ch3br", /obj/screen/alert/not_enough_ch3br)
|
||||
return FALSE
|
||||
|
||||
var/gas_breathed = 0
|
||||
@@ -138,6 +147,8 @@
|
||||
var/N2_pp = breath.get_breath_partial_pressure(breath.get_moles(/datum/gas/nitrogen))
|
||||
var/Toxins_pp = breath.get_breath_partial_pressure(breath.get_moles(/datum/gas/plasma))
|
||||
var/CO2_pp = breath.get_breath_partial_pressure(breath.get_moles(/datum/gas/carbon_dioxide))
|
||||
var/CH4_pp = breath.get_breath_partial_pressure(breath.get_moles(/datum/gas/methane))
|
||||
var/CH3Br_pp = breath.get_breath_partial_pressure(breath.get_moles(/datum/gas/methyl_bromide))
|
||||
|
||||
|
||||
//-- OXY --//
|
||||
@@ -278,6 +289,58 @@
|
||||
breath.adjust_moles(/datum/gas/carbon_dioxide, gas_breathed)
|
||||
gas_breathed = 0
|
||||
|
||||
//-- METHANE --//
|
||||
|
||||
//Too much methane!
|
||||
if(safe_methane_max)
|
||||
if(CH4_pp > safe_methane_max) //Same effect as excess nitrogen, generally nontoxic
|
||||
var/ratio = (breath.get_moles(/datum/gas/methane)/safe_methane_max) * 10
|
||||
H.apply_damage_type(clamp(ratio, methane_breath_dam_min, methane_breath_dam_max), methane_damage_type)
|
||||
H.throw_alert("too_much_ch4", /obj/screen/alert/too_much_ch4)
|
||||
H.losebreath += 2
|
||||
else
|
||||
H.clear_alert("too_much_ch4")
|
||||
//Too little methane!
|
||||
if(safe_methane_min)
|
||||
if(CH4_pp < safe_methane_min)
|
||||
gas_breathed = handle_too_little_breath(H, CH4_pp, safe_methane_min, breath.get_moles(/datum/gas/methane))
|
||||
H.throw_alert("not_enough_ch4", /obj/screen/alert/not_enough_ch4)
|
||||
else
|
||||
H.failed_last_breath = FALSE
|
||||
if(H.health >= H.crit_threshold)
|
||||
H.adjustOxyLoss(-breathModifier)
|
||||
gas_breathed = breath.get_moles(/datum/gas/methane)
|
||||
H.clear_alert("not_enough_ch4")
|
||||
|
||||
//Exhale
|
||||
breath.adjust_moles(/datum/gas/methane, -gas_breathed)
|
||||
breath.adjust_moles(/datum/gas/methyl_bromide, gas_breathed)
|
||||
gas_breathed = 0
|
||||
|
||||
//-- CH3BR --//
|
||||
|
||||
//Too much methyl bromide!
|
||||
if(safe_ch3br_max)
|
||||
if(CH3Br_pp > safe_ch3br_max)
|
||||
if(prob(CH3Br_pp/0.5))
|
||||
H.adjustOrganLoss(ORGAN_SLOT_LUNGS, 3, 150) //Inhaling this is a bad idea
|
||||
if(prob(CH3Br_pp/2))
|
||||
to_chat(H, "<span class='alert'>Your throat closes up!</span>")
|
||||
H.silent = max(H.silent, 3)
|
||||
H.throw_alert("too_much_ch3br", /obj/screen/alert/too_much_ch3br)
|
||||
else
|
||||
H.clear_alert("too_much_ch3br")
|
||||
//Too little methyl bromide!
|
||||
if(safe_ch3br_min)
|
||||
if(CH3Br_pp < safe_ch3br_min)
|
||||
gas_breathed = handle_too_little_breath(H, CH3Br_pp, safe_ch3br_min, breath.get_moles(/datum/gas/methyl_bromide))
|
||||
H.throw_alert("not_enough_ch3br", /obj/screen/alert/not_enough_ch3br)
|
||||
else
|
||||
H.failed_last_breath = FALSE
|
||||
if(H.health >= H.crit_threshold)
|
||||
H.adjustOxyLoss(-breathModifier)
|
||||
gas_breathed = breath.get_moles(/datum/gas/methyl_bromide)
|
||||
H.clear_alert("not_enough_ch3br")
|
||||
|
||||
//-- TRACES --//
|
||||
|
||||
@@ -487,7 +550,6 @@
|
||||
owner.losebreath = 20
|
||||
owner.adjustOrganLoss(ORGAN_SLOT_LUNGS, 25)
|
||||
|
||||
|
||||
/obj/item/organ/lungs/cybernetic/upgraded
|
||||
name = "upgraded cybernetic lungs"
|
||||
desc = "A more advanced version of the stock cybernetic lungs. They are capable of filtering out lower levels of toxins and carbon dioxide."
|
||||
|
||||
@@ -10,5 +10,9 @@
|
||||
Fail("Flavor text is failing to save.")
|
||||
if(P.features["ooc_notes"] != "Bar")
|
||||
Fail("OOC text is failing to save.")
|
||||
P.save_character()
|
||||
P.load_character()
|
||||
if(P.features["flavor_text"] != "Foo")
|
||||
Fail("Repeated saving and loading possibly causing save deletion.")
|
||||
catch(var/exception/e)
|
||||
Fail("Failed to save and load character due to exception [e.file]:[e.line], [e.name]")
|
||||
|
||||
@@ -137,6 +137,7 @@
|
||||
products = list(/obj/item/clothing/suit/hooded/wintercoat/cargo = 3,
|
||||
/obj/item/clothing/under/rank/cargo/tech = 5,
|
||||
/obj/item/clothing/under/rank/cargo/tech/skirt = 5,
|
||||
/obj/item/clothing/under/rank/cargo/tech/long = 5,
|
||||
/obj/item/clothing/shoes/sneakers/black = 5,
|
||||
/obj/item/clothing/gloves/fingerless = 5,
|
||||
/obj/item/clothing/head/soft = 5,
|
||||
|
||||
@@ -273,16 +273,7 @@
|
||||
to_chat(src,"<span class='warning'>You attempted to apply your vore prefs but somehow you're in this character without a client.prefs variable. Tell a dev.</span>")
|
||||
return FALSE
|
||||
ENABLE_BITFIELD(vore_flags,VOREPREF_INIT)
|
||||
|
||||
// garbage data coming back the other way or breaking absorbed would be bad, so instead we do this
|
||||
vore_flags |= CHECK_BITFIELD(client.prefs.vore_flags,DIGESTABLE) // set to 1 if prefs is 1
|
||||
vore_flags |= CHECK_BITFIELD(client.prefs.vore_flags,DEVOURABLE)
|
||||
vore_flags |= CHECK_BITFIELD(client.prefs.vore_flags,FEEDING)
|
||||
|
||||
vore_flags &= CHECK_BITFIELD(client.prefs.vore_flags,DIGESTABLE) // set to 0 if prefs is 0
|
||||
vore_flags &= CHECK_BITFIELD(client.prefs.vore_flags,DEVOURABLE)
|
||||
vore_flags &= CHECK_BITFIELD(client.prefs.vore_flags,FEEDING)
|
||||
|
||||
COPY_SPECIFIC_BITFIELDS(vore_flags,client.prefs.vore_flags,DIGESTABLE | DEVOURABLE | FEEDING | LICKABLE)
|
||||
vore_taste = client.prefs.vore_taste
|
||||
|
||||
release_vore_contents(silent = TRUE)
|
||||
|
||||
Reference in New Issue
Block a user