Merge branch 'master' of https://github.com/Citadel-Station-13/Citadel-Station-13 into Ghommie-cit698
This commit is contained in:
@@ -429,6 +429,10 @@
|
||||
for(var/datum/dynamic_ruleset/roundstart/rule in GLOB.dynamic_forced_roundstart_ruleset)
|
||||
dat += {"<A href='?src=[REF(src)];[HrefToken()];f_dynamic_roundstart_remove=\ref[rule]'>-> [rule.name] <-</A><br>"}
|
||||
dat += "<A href='?src=[REF(src)];[HrefToken()];f_dynamic_roundstart_clear=1'>(Clear Rulesets)</A><br>"
|
||||
dat += "<A href='?src=[REF(src)];[HrefToken()];f_dynamic_storyteller=1'>(Force Storyteller)</A><br>"
|
||||
if (GLOB.dynamic_forced_storyteller)
|
||||
var/datum/dynamic_storyteller/S = GLOB.dynamic_forced_storyteller
|
||||
dat += "<A href='?src=[REF(src)];[HrefToken()];f_dynamic_storyteller_clear=1'>-> [initial(S.name)] <-</A><br>"
|
||||
dat += "<A href='?src=[REF(src)];[HrefToken()];f_dynamic_options=1'>(Dynamic mode options)</A><br>"
|
||||
else if (SSticker.IsRoundInProgress())
|
||||
dat += "<A href='?src=[REF(src)];[HrefToken()];f_dynamic_latejoin=1'>(Force Next Latejoin Ruleset)</A><br>"
|
||||
@@ -690,7 +694,7 @@
|
||||
var/prev_dynamic_voting = CONFIG_GET(flag/dynamic_voting)
|
||||
CONFIG_SET(flag/dynamic_voting,!prev_dynamic_voting)
|
||||
if (!prev_dynamic_voting)
|
||||
to_chat(world, "<B>Vote is now a ranked choice of dynamic storytellers.</B>")
|
||||
to_chat(world, "<B>Vote is now between dynamic storytellers.</B>")
|
||||
else
|
||||
to_chat(world, "<B>Vote is now between extended and secret.</B>")
|
||||
log_admin("[key_name(usr)] [prev_dynamic_voting ? "disabled" : "enabled"] dynamic voting.")
|
||||
|
||||
@@ -81,7 +81,7 @@ GLOBAL_PROTECT(admin_verbs_admin)
|
||||
)
|
||||
GLOBAL_LIST_INIT(admin_verbs_ban, list(/client/proc/unban_panel, /client/proc/DB_ban_panel, /client/proc/stickybanpanel))
|
||||
GLOBAL_PROTECT(admin_verbs_ban)
|
||||
GLOBAL_LIST_INIT(admin_verbs_sounds, list(/client/proc/play_local_sound, /client/proc/play_sound, /client/proc/set_round_end_sound))
|
||||
GLOBAL_LIST_INIT(admin_verbs_sounds, list(/client/proc/play_local_sound, /client/proc/play_sound, /client/proc/manual_play_web_sound, /client/proc/set_round_end_sound))
|
||||
GLOBAL_PROTECT(admin_verbs_sounds)
|
||||
GLOBAL_LIST_INIT(admin_verbs_fun, list(
|
||||
/client/proc/cmd_admin_dress,
|
||||
@@ -364,7 +364,7 @@ GLOBAL_PROTECT(admin_verbs_hideable)
|
||||
log_admin("[key_name(usr)] admin ghosted.")
|
||||
message_admins("[key_name_admin(usr)] admin ghosted.")
|
||||
var/mob/body = mob
|
||||
body.ghostize(1)
|
||||
body.ghostize(1, voluntary = TRUE)
|
||||
if(body && !body.key)
|
||||
body.key = "@[key]" //Haaaaaaaack. But the people have spoken. If it breaks; blame adminbus
|
||||
SSblackbox.record_feedback("tally", "admin_verb", 1, "Admin Ghost") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
@@ -120,7 +120,7 @@ GLOBAL_PROTECT(AdminProcCallSpamPrevention)
|
||||
//adv proc call this, ya nerds
|
||||
/world/proc/WrapAdminProcCall(datum/target, procname, list/arguments)
|
||||
if(target == GLOBAL_PROC)
|
||||
return call(procname)(arglist(arguments))
|
||||
return call(text2path("/proc/[procname]"))(arglist(arguments))
|
||||
else if(target != world)
|
||||
return call(target, procname)(arglist(arguments))
|
||||
else
|
||||
|
||||
@@ -95,7 +95,7 @@
|
||||
var/new_volume = input(user, "Choose a volume.", "Sound Emitter", sound_volume) as null|num
|
||||
if(isnull(new_volume))
|
||||
return
|
||||
new_volume = CLAMP(new_volume, 0, 100)
|
||||
new_volume = clamp(new_volume, 0, 100)
|
||||
sound_volume = new_volume
|
||||
to_chat(user, "<span class='notice'>Volume set to [sound_volume]%.</span>")
|
||||
if(href_list["edit_mode"])
|
||||
@@ -118,7 +118,7 @@
|
||||
var/new_radius = input(user, "Choose a radius.", "Sound Emitter", sound_volume) as null|num
|
||||
if(isnull(new_radius))
|
||||
return
|
||||
new_radius = CLAMP(new_radius, 0, 127)
|
||||
new_radius = clamp(new_radius, 0, 127)
|
||||
play_radius = new_radius
|
||||
to_chat(user, "<span class='notice'>Audible radius set to [play_radius].</span>")
|
||||
if(href_list["play"])
|
||||
|
||||
@@ -393,7 +393,7 @@
|
||||
var/nsd = CONFIG_GET(number/note_stale_days)
|
||||
var/nfd = CONFIG_GET(number/note_fresh_days)
|
||||
if (agegate && type == "note" && isnum(nsd) && isnum(nfd) && nsd > nfd)
|
||||
var/alpha = CLAMP(100 - (age - nfd) * (85 / (nsd - nfd)), 15, 100)
|
||||
var/alpha = clamp(100 - (age - nfd) * (85 / (nsd - nfd)), 15, 100)
|
||||
if (alpha < 100)
|
||||
if (alpha <= 15)
|
||||
if (skipped)
|
||||
|
||||
@@ -1394,6 +1394,32 @@
|
||||
log_admin("[key_name(usr)] removed [rule] from the forced roundstart rulesets.")
|
||||
message_admins("[key_name(usr)] removed [rule] from the forced roundstart rulesets.", 1)
|
||||
|
||||
else if(href_list["f_dynamic_storyteller"])
|
||||
if(!check_rights(R_ADMIN))
|
||||
return
|
||||
if(SSticker && SSticker.mode)
|
||||
return alert(usr, "The game has already started.", null, null, null, null)
|
||||
if(GLOB.master_mode != "dynamic")
|
||||
return alert(usr, "The game mode has to be dynamic mode.", null, null, null, null)
|
||||
var/list/choices = list()
|
||||
for(var/T in config.storyteller_cache)
|
||||
var/datum/dynamic_storyteller/S = T
|
||||
choices[initial(S.name)] = T
|
||||
var/choice = choices[input("Select storyteller:", "Storyteller", "Classic") as null|anything in choices]
|
||||
if(choice)
|
||||
GLOB.dynamic_forced_storyteller = choice
|
||||
log_admin("[key_name(usr)] forced the storyteller to [GLOB.dynamic_forced_storyteller].")
|
||||
message_admins("[key_name(usr)] forced the storyteller to [GLOB.dynamic_forced_storyteller].")
|
||||
Game()
|
||||
|
||||
else if(href_list["f_dynamic_storyteller_clear"])
|
||||
if(!check_rights(R_ADMIN))
|
||||
return
|
||||
GLOB.dynamic_forced_storyteller = null
|
||||
Game()
|
||||
log_admin("[key_name(usr)] cleared the forced storyteller. The mode will pick one as normal.")
|
||||
message_admins("[key_name(usr)] cleared the forced storyteller. The mode will pick one as normal.", 1)
|
||||
|
||||
else if(href_list["f_dynamic_latejoin"])
|
||||
if(!check_rights(R_ADMIN))
|
||||
return
|
||||
@@ -2363,7 +2389,7 @@
|
||||
return
|
||||
|
||||
var/list/offset = splittext(href_list["offset"],",")
|
||||
var/number = CLAMP(text2num(href_list["object_count"]), 1, 100)
|
||||
var/number = clamp(text2num(href_list["object_count"]), 1, 100)
|
||||
var/X = offset.len > 0 ? text2num(offset[1]) : 0
|
||||
var/Y = offset.len > 1 ? text2num(offset[2]) : 0
|
||||
var/Z = offset.len > 2 ? text2num(offset[3]) : 0
|
||||
|
||||
@@ -85,7 +85,7 @@
|
||||
if ("set_charge")
|
||||
var/newcharge = input("New charge (0-[borg.cell.maxcharge]):", borg.name, borg.cell.charge) as num|null
|
||||
if (newcharge)
|
||||
borg.cell.charge = CLAMP(newcharge, 0, borg.cell.maxcharge)
|
||||
borg.cell.charge = clamp(newcharge, 0, borg.cell.maxcharge)
|
||||
message_admins("[key_name_admin(user)] set the charge of [ADMIN_LOOKUPFLW(borg)] to [borg.cell.charge].")
|
||||
log_admin("[key_name(user)] set the charge of [key_name(borg)] to [borg.cell.charge].")
|
||||
if ("remove_cell")
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
var/freq = input(usr, "What frequency would you like the sound to play at?",, 1) as null|num
|
||||
if(!freq)
|
||||
freq = 1
|
||||
vol = CLAMP(vol, 1, 100)
|
||||
vol = clamp(vol, 1, 100)
|
||||
|
||||
var/sound/admin_sound = new()
|
||||
admin_sound.file = S
|
||||
@@ -138,6 +138,49 @@
|
||||
|
||||
SSblackbox.record_feedback("tally", "admin_verb", 1, "Play Internet Sound")
|
||||
|
||||
/client/proc/manual_play_web_sound()
|
||||
set category = "Fun"
|
||||
set name = "Manual Play Internet Sound"
|
||||
if(!check_rights(R_SOUNDS))
|
||||
return
|
||||
|
||||
var/web_sound_input = input("Enter content stream URL (fetch this from local youtube-dl!)", "Play Internet Sound via direct URL") as text|null
|
||||
if(istext(web_sound_input))
|
||||
if(!length(web_sound_input))
|
||||
log_admin("[key_name(src)] stopped web sound")
|
||||
message_admins("[key_name(src)] stopped web sound")
|
||||
var/mob/M
|
||||
for(var/i in GLOB.player_list)
|
||||
M = i
|
||||
M?.client?.chatOutput?.stopMusic()
|
||||
return
|
||||
else
|
||||
if(web_sound_input && !findtext(web_sound_input, GLOB.is_http_protocol))
|
||||
to_chat(src, "<span class='boldwarning'>BLOCKED: Content URL not using http(s) protocol</span>")
|
||||
return
|
||||
var/freq = input(usr, "What frequency would you like the sound to play at?",, 1) as null|num
|
||||
if(isnull(freq))
|
||||
return
|
||||
if(!freq)
|
||||
freq = 1
|
||||
SSblackbox.record_feedback("nested tally", "played_url", 1, list("[ckey]", "[web_sound_input]"))
|
||||
var/logstr = "[key_name(src)] played web sound at freq [freq]: [web_sound_input]"
|
||||
log_admin(logstr)
|
||||
message_admins(logstr)
|
||||
var/mob/M
|
||||
var/client/C
|
||||
var/datum/chatOutput/O
|
||||
for(var/i in GLOB.player_list)
|
||||
M = i
|
||||
C = M.client
|
||||
if(!(C?.prefs?.toggles & SOUND_MIDI))
|
||||
continue
|
||||
O = C.chatOutput
|
||||
if(!O || O.broken || !O.loaded)
|
||||
continue
|
||||
O.sendMusic(web_sound_input, freq)
|
||||
SSblackbox.record_feedback("tally", "admin_verb", 1, "Manual Play Internet Sound")
|
||||
|
||||
/client/proc/set_round_end_sound(S as sound)
|
||||
set category = "Fun"
|
||||
set name = "Set Round End Sound"
|
||||
|
||||
@@ -1379,3 +1379,47 @@ GLOBAL_LIST_EMPTY(custom_outfits) //Admin created outfits
|
||||
else
|
||||
message_admins("[key_name_admin(usr)] has [newstate ? "activated" : "deactivated"] job exp exempt status on [key_name_admin(C)]")
|
||||
log_admin("[key_name(usr)] has [newstate ? "activated" : "deactivated"] job exp exempt status on [key_name(C)]")
|
||||
|
||||
/// Allow admin to add or remove traits of datum
|
||||
/datum/admins/proc/modify_traits(datum/D)
|
||||
if(!D)
|
||||
return
|
||||
|
||||
var/add_or_remove = input("Remove/Add?", "Trait Remove/Add") as null|anything in list("Add","Remove")
|
||||
if(!add_or_remove)
|
||||
return
|
||||
var/list/availible_traits = list()
|
||||
|
||||
switch(add_or_remove)
|
||||
if("Add")
|
||||
for(var/key in GLOB.traits_by_type)
|
||||
if(istype(D,key))
|
||||
availible_traits += GLOB.traits_by_type[key]
|
||||
if("Remove")
|
||||
if(!GLOB.trait_name_map)
|
||||
GLOB.trait_name_map = generate_trait_name_map()
|
||||
for(var/trait in D.status_traits)
|
||||
var/name = GLOB.trait_name_map[trait] || trait
|
||||
availible_traits[name] = trait
|
||||
|
||||
var/chosen_trait = input("Select trait to modify", "Trait") as null|anything in sortList(availible_traits)
|
||||
if(!chosen_trait)
|
||||
return
|
||||
chosen_trait = availible_traits[chosen_trait]
|
||||
|
||||
var/source = "adminabuse"
|
||||
switch(add_or_remove)
|
||||
if("Add") //Not doing source choosing here intentionally to make this bit faster to use, you can always vv it.
|
||||
ADD_TRAIT(D,chosen_trait,source)
|
||||
if("Remove")
|
||||
var/specific = input("All or specific source ?", "Trait Remove/Add") as null|anything in list("All","Specific")
|
||||
if(!specific)
|
||||
return
|
||||
switch(specific)
|
||||
if("All")
|
||||
source = null
|
||||
if("Specific")
|
||||
source = input("Source to be removed","Trait Remove/Add") as null|anything in sortList(D.status_traits[chosen_trait])
|
||||
if(!source)
|
||||
return
|
||||
REMOVE_TRAIT(D,chosen_trait,source)
|
||||
|
||||
@@ -194,9 +194,10 @@ GLOBAL_PROTECT(VVpixelmovement)
|
||||
else
|
||||
variable = L[index]
|
||||
//EXPERIMENTAL - Keep old associated value while modifying key, if any
|
||||
var/found = L[variable]
|
||||
if(!isnull(found))
|
||||
old_assoc_value = found
|
||||
if(IS_VALID_ASSOC_KEY(variable))
|
||||
var/found = L[variable]
|
||||
if(!isnull(found))
|
||||
old_assoc_value = found
|
||||
//
|
||||
|
||||
default = vv_get_class(objectvar, variable)
|
||||
|
||||
@@ -47,5 +47,33 @@
|
||||
usr.client.debug_variables(src)
|
||||
if(href_list[VV_HK_MARK])
|
||||
usr.client.mark_datum(target)
|
||||
if(href_list[VV_HK_ADDCOMPONENT])
|
||||
if(!check_rights(NONE))
|
||||
return
|
||||
var/list/names = list()
|
||||
var/list/componentsubtypes = subtypesof(/datum/component)
|
||||
names += "---Components---"
|
||||
names += componentsubtypes
|
||||
names += "---Elements---"
|
||||
names += subtypesof(/datum/element)
|
||||
var/result = input(usr, "Choose a component/element to add","better know what ur fuckin doin pal") as null|anything in names
|
||||
if(!usr || !result || result == "---Components---" || result == "---Elements---")
|
||||
return
|
||||
if(QDELETED(src))
|
||||
to_chat(usr, "That thing doesn't exist anymore!")
|
||||
return
|
||||
var/list/lst = get_callproc_args()
|
||||
if(!lst)
|
||||
return
|
||||
var/datumname = "error"
|
||||
lst.Insert(1, result)
|
||||
if(result in componentsubtypes)
|
||||
datumname = "component"
|
||||
target._AddComponent(lst)
|
||||
else
|
||||
datumname = "element"
|
||||
target._AddElement(lst)
|
||||
log_admin("[key_name(usr)] has added [result] [datumname] to [key_name(src)].")
|
||||
message_admins("<span class='notice'>[key_name_admin(usr)] has added [result] [datumname] to [key_name_admin(src)].</span>")
|
||||
if(href_list[VV_HK_CALLPROC])
|
||||
usr.client.callproc_datum(target)
|
||||
|
||||
@@ -42,7 +42,7 @@
|
||||
if(objective.completable)
|
||||
var/completion = objective.check_completion()
|
||||
if(completion >= 1)
|
||||
report += "<B>Objective #[objective_count]</B>: [objective.explanation_text] <span class='greentext'><B>Success!</span>"
|
||||
report += "<B>Objective #[objective_count]</B>: [objective.explanation_text] <span class='greentext'><B>Success!</B></span>"
|
||||
else if(completion <= 0)
|
||||
report += "<B>Objective #[objective_count]</B>: [objective.explanation_text] <span class='redtext'>Fail.</span>"
|
||||
win = FALSE
|
||||
|
||||
@@ -6,6 +6,7 @@
|
||||
status = ORGAN_ROBOTIC
|
||||
beating = TRUE
|
||||
organ_flags = ORGAN_NO_SPOIL
|
||||
no_pump = TRUE
|
||||
var/true_name = "baseline placebo referencer"
|
||||
var/cooldown_low = 300
|
||||
var/cooldown_high = 300
|
||||
@@ -92,6 +93,7 @@
|
||||
update_gland_hud()
|
||||
|
||||
/obj/item/organ/heart/gland/on_life()
|
||||
. = ..()
|
||||
if(!beating)
|
||||
// alien glands are immune to stopping.
|
||||
beating = TRUE
|
||||
|
||||
@@ -42,7 +42,7 @@
|
||||
/mob/living/simple_animal/hostile/blob/fire_act(exposed_temperature, exposed_volume)
|
||||
..()
|
||||
if(exposed_temperature)
|
||||
adjustFireLoss(CLAMP(0.01 * exposed_temperature, 1, 5))
|
||||
adjustFireLoss(clamp(0.01 * exposed_temperature, 1, 5))
|
||||
else
|
||||
adjustFireLoss(5)
|
||||
|
||||
|
||||
@@ -203,7 +203,7 @@ GLOBAL_LIST_EMPTY(blob_nodes)
|
||||
B.hud_used.blobpwrdisplay.maptext = "<div align='center' valign='middle' style='position:relative; top:0px; left:6px'><font color='#82ed00'>[round(blob_core.obj_integrity)]</font></div>"
|
||||
|
||||
/mob/camera/blob/proc/add_points(points)
|
||||
blob_points = CLAMP(blob_points + points, 0, max_blob_points)
|
||||
blob_points = clamp(blob_points + points, 0, max_blob_points)
|
||||
hud_used.blobpwrdisplay.maptext = "<div align='center' valign='middle' style='position:relative; top:0px; left:6px'><font color='#82ed00'>[round(blob_points)]</font></div>"
|
||||
|
||||
/mob/camera/blob/say(message, bubble_type, var/list/spans = list(), sanitize = TRUE, datum/language/language = null, ignore_spam = FALSE, forced = null)
|
||||
|
||||
@@ -77,7 +77,7 @@
|
||||
|
||||
/obj/structure/blob/CanAStarPass(ID, dir, caller)
|
||||
. = 0
|
||||
if(ismovableatom(caller))
|
||||
if(ismovable(caller))
|
||||
var/atom/movable/mover = caller
|
||||
. = . || (mover.pass_flags & PASSBLOB)
|
||||
|
||||
|
||||
@@ -14,10 +14,10 @@
|
||||
set waitfor = FALSE // Don't make on_gain() wait for this function to finish. This lets this code run on the side.
|
||||
var/notice_healing
|
||||
while(owner && !AmFinalDeath()) // owner.has_antag_datum(ANTAG_DATUM_BLOODSUCKER) == src
|
||||
if(owner.current.stat == CONSCIOUS && !poweron_feed && !HAS_TRAIT(owner.current, TRAIT_DEATHCOMA)) // Deduct Blood
|
||||
if(owner.current.stat == CONSCIOUS && !poweron_feed && !HAS_TRAIT(owner.current, TRAIT_FAKEDEATH)) // Deduct Blood
|
||||
AddBloodVolume(passive_blood_drain) // -.1 currently
|
||||
if(HandleHealing(1)) // Heal
|
||||
if(notice_healing == FALSE && owner.current.blood_volume > 0)
|
||||
if(!notice_healing && owner.current.blood_volume > 0)
|
||||
to_chat(owner, "<span class='notice'>The power of your blood begins knitting your wounds...</span>")
|
||||
notice_healing = TRUE
|
||||
else if(notice_healing == TRUE)
|
||||
@@ -25,7 +25,7 @@
|
||||
HandleStarving() // Death
|
||||
HandleDeath() // Standard Update
|
||||
update_hud()// Daytime Sleep in Coffin
|
||||
if(SSticker.mode.is_daylight() && !HAS_TRAIT_FROM(owner.current, TRAIT_DEATHCOMA, "bloodsucker"))
|
||||
if(SSticker.mode.is_daylight() && !HAS_TRAIT_FROM(owner.current, TRAIT_FAKEDEATH, "bloodsucker"))
|
||||
if(istype(owner.current.loc, /obj/structure/closet/crate/coffin))
|
||||
Torpor_Begin()
|
||||
// Wait before next pass
|
||||
@@ -39,7 +39,7 @@
|
||||
/////////////////////////////////////////////////////////////////////////////////////////////////////////////////////
|
||||
|
||||
/datum/antagonist/bloodsucker/proc/AddBloodVolume(value)
|
||||
owner.current.blood_volume = CLAMP(owner.current.blood_volume + value, 0, max_blood_volume)
|
||||
owner.current.blood_volume = clamp(owner.current.blood_volume + value, 0, max_blood_volume)
|
||||
update_hud()
|
||||
|
||||
/datum/antagonist/bloodsucker/proc/HandleFeeding(mob/living/carbon/target, mult=1)
|
||||
@@ -83,7 +83,7 @@
|
||||
// NOTE: Mult of 0 is just a TEST to see if we are injured and need to go into Torpor!
|
||||
//It is called from your coffin on close (by you only)
|
||||
var/actual_regen = regen_rate + additional_regen
|
||||
if(poweron_masquerade == TRUE || owner.current.AmStaked())
|
||||
if(poweron_masquerade|| owner.current.AmStaked())
|
||||
return FALSE
|
||||
if(owner.current.reagents.has_reagent(/datum/reagent/consumable/garlic))
|
||||
return FALSE
|
||||
@@ -101,8 +101,8 @@
|
||||
var/mob/living/carbon/C = owner.current
|
||||
var/costMult = 1 // Coffin makes it cheaper
|
||||
var/fireheal = 0 // BURN: Heal in Coffin while Fakedeath, or when damage above maxhealth (you can never fully heal fire)
|
||||
var/amInCoffinWhileTorpor = istype(C.loc, /obj/structure/closet/crate/coffin) && (mult == 0 || HAS_TRAIT(C, TRAIT_FAKEDEATH)) // Check for mult 0 OR death coma. (mult 0 means we're testing from coffin)
|
||||
if(amInCoffinWhileTorpor)
|
||||
// Check for mult 0 OR death coma. (mult 0 means we're testing from coffin)
|
||||
if(istype(C.loc, /obj/structure/closet/crate/coffin) && (mult == 0 || HAS_TRAIT(C, TRAIT_FAKEDEATH)))
|
||||
mult *= 4 // Increase multiplier if we're sleeping in a coffin.
|
||||
fireheal = min(C.getFireLoss(), regen_rate) // NOTE: Burn damage ONLY heals in torpor.
|
||||
C.ExtinguishMob()
|
||||
@@ -112,7 +112,10 @@
|
||||
CheckVampOrgans() // Heart, Eyes
|
||||
if(check_limbs(costMult))
|
||||
return TRUE
|
||||
|
||||
else if(owner.current.stat >= UNCONSCIOUS) //Faster regeneration and slight burn healing while unconcious
|
||||
mult *= 2
|
||||
fireheal = min(C.getFireLoss(), regen_rate * 0.2)
|
||||
|
||||
// BRUTE: Always Heal
|
||||
var/bruteheal = min(C.getBruteLoss(), actual_regen)
|
||||
var/toxinheal = min(C.getToxLoss(), actual_regen)
|
||||
@@ -120,8 +123,6 @@
|
||||
if(bruteheal + fireheal + toxinheal > 0) // Just a check? Don't heal/spend, and return.
|
||||
if(mult == 0)
|
||||
return TRUE
|
||||
if(owner.current.stat >= UNCONSCIOUS) //Faster regeneration while unconcious, so you dont have to wait all day
|
||||
mult *= 2
|
||||
// We have damage. Let's heal (one time)
|
||||
C.adjustBruteLoss(-bruteheal * mult, forced = TRUE)// Heal BRUTE / BURN in random portions throughout the body.
|
||||
C.adjustFireLoss(-fireheal * mult, forced = TRUE)
|
||||
@@ -129,7 +130,7 @@
|
||||
//C.heal_overall_damage(bruteheal * mult, fireheal * mult) // REMOVED: We need to FORCE this, because otherwise, vamps won't heal EVER. Swapped to above.
|
||||
AddBloodVolume((bruteheal * -0.5 + fireheal * -1 + toxinheal * -0.2) / mult * costMult) // Costs blood to heal
|
||||
return TRUE // Healed! Done for this tick.
|
||||
|
||||
|
||||
|
||||
|
||||
/datum/antagonist/bloodsucker/proc/check_limbs(costMult)
|
||||
@@ -137,7 +138,7 @@
|
||||
var/mob/living/carbon/C = owner.current
|
||||
var/list/missing = C.get_missing_limbs()
|
||||
if(missing.len && C.blood_volume < limb_regen_cost + 5)
|
||||
return FALSE
|
||||
return FALSE
|
||||
for(var/targetLimbZone in missing) // 1) Find ONE Limb and regenerate it.
|
||||
C.regenerate_limb(targetLimbZone, FALSE) // regenerate_limbs() <--- If you want to EXCLUDE certain parts, do it like this ----> regenerate_limbs(0, list("head"))
|
||||
AddBloodVolume(50)
|
||||
@@ -146,12 +147,6 @@
|
||||
to_chat(C, "<span class='notice'>Your flesh knits as it regrows your [L]!</span>")
|
||||
playsound(C, 'sound/magic/demon_consume.ogg', 50, TRUE)
|
||||
return TRUE
|
||||
/*for(var/obj/item/bodypart/BP in C.bodyparts)
|
||||
if(!istype(BP) && !BP.status == 2)
|
||||
return FALSE
|
||||
to_chat(C, "<span class='notice'>Your body expels the [BP]!</span>")
|
||||
BP.drop_limb()
|
||||
return TRUE */
|
||||
|
||||
/datum/antagonist/bloodsucker/proc/CureDisabilities()
|
||||
var/mob/living/carbon/C = owner.current
|
||||
@@ -176,14 +171,14 @@
|
||||
// EMPTY: Frenzy!
|
||||
// BLOOD_VOLUME_GOOD: [336] Pale (handled in bloodsucker_integration.dm
|
||||
// BLOOD_VOLUME_BAD: [224] Jitter
|
||||
if(owner.current.blood_volume < BLOOD_VOLUME_BAD && !prob(0.5))
|
||||
if(owner.current.blood_volume < BLOOD_VOLUME_BAD && !prob(0.5 && HAS_TRAIT(owner, TRAIT_FAKEDEATH)) && !poweron_masquerade)
|
||||
owner.current.Jitter(3)
|
||||
// BLOOD_VOLUME_SURVIVE: [122] Blur Vision
|
||||
if(owner.current.blood_volume < BLOOD_VOLUME_BAD / 2)
|
||||
owner.current.blur_eyes(8 - 8 * (owner.current.blood_volume / BLOOD_VOLUME_BAD))
|
||||
// Nutrition
|
||||
owner.current.nutrition = clamp(owner.current.blood_volume, 545, 0) //The amount of blood is how full we are.
|
||||
//A bit higher regeneration based on blood volume
|
||||
//A bit higher regeneration based on blood volume
|
||||
if(owner.current.blood_volume < 700)
|
||||
additional_regen = 0.4
|
||||
else if(owner.current.blood_volume < BLOOD_VOLUME_NORMAL)
|
||||
@@ -230,16 +225,16 @@
|
||||
Torpor_Begin()
|
||||
to_chat(owner, "<span class='danger'>Your immortal body will not yet relinquish your soul to the abyss. You enter Torpor.</span>")
|
||||
sleep(30) //To avoid spam
|
||||
if(poweron_masquerade == TRUE)
|
||||
if(poweron_masquerade)
|
||||
to_chat(owner, "<span class='warning'>Your wounds will not heal until you disable the <span class='boldnotice'>Masquerade</span> power.</span>")
|
||||
// End Torpor:
|
||||
else // No damage, OR toxin healed AND brute healed and NOT in coffin (since you cannot heal burn)
|
||||
if(total_damage <= 0 || total_toxloss <= 0 && total_brute <= 0 && !istype(owner.current.loc, /obj/structure/closet/crate/coffin))
|
||||
// Not Daytime, Not in Torpor
|
||||
if(!SSticker.mode.is_daylight() && HAS_TRAIT_FROM(owner.current, TRAIT_FAKEDEATH, "bloodsucker"))
|
||||
// Not Daytime, Not in Torpor, enough health to not die the moment you end torpor
|
||||
if(!SSticker.mode.is_daylight() && HAS_TRAIT_FROM(owner.current, TRAIT_FAKEDEATH, "bloodsucker") && total_damage < owner.current.getMaxHealth())
|
||||
Torpor_End()
|
||||
// Fake Unconscious
|
||||
if(poweron_masquerade == TRUE && total_damage >= owner.current.getMaxHealth() - HEALTH_THRESHOLD_FULLCRIT)
|
||||
if(poweron_masquerade && total_damage >= owner.current.getMaxHealth() - HEALTH_THRESHOLD_FULLCRIT)
|
||||
owner.current.Unconscious(20, 1)
|
||||
|
||||
/datum/antagonist/bloodsucker/proc/Torpor_Begin(amInCoffin = FALSE)
|
||||
@@ -249,6 +244,7 @@
|
||||
ADD_TRAIT(owner.current, TRAIT_NODEATH, "bloodsucker") // Without this, you'll just keep dying while you recover.
|
||||
ADD_TRAIT(owner.current, TRAIT_RESISTHIGHPRESSURE, "bloodsucker") // So you can heal in space. Otherwise you just...heal forever.
|
||||
ADD_TRAIT(owner.current, TRAIT_RESISTLOWPRESSURE, "bloodsucker")
|
||||
owner.current.Jitter(0)
|
||||
// Visuals
|
||||
owner.current.update_sight()
|
||||
owner.current.reload_fullscreen()
|
||||
@@ -256,6 +252,9 @@
|
||||
for(var/datum/action/bloodsucker/power in powers)
|
||||
if(power.active && !power.can_use_in_torpor)
|
||||
power.DeactivatePower()
|
||||
if(owner.current.suiciding)
|
||||
owner.current.suiciding = FALSE //Youll die but not for long.
|
||||
to_chat(owner.current, "<span class='warning'>Your body keeps you going, even as you try to end yourself.</span>")
|
||||
|
||||
/datum/antagonist/bloodsucker/proc/Torpor_End()
|
||||
owner.current.stat = SOFT_CRIT
|
||||
@@ -369,8 +368,8 @@
|
||||
//Puke blood only if puke_blood is true, and loose some blood, else just puke normally.
|
||||
if(puke_blood)
|
||||
C.blood_volume = max(0, C.blood_volume - foodInGut * 2)
|
||||
C.vomit(foodInGut * 4, foodInGut * 2, 0)
|
||||
else
|
||||
C.vomit(foodInGut * 4, foodInGut * 2, 0)
|
||||
else
|
||||
C.vomit(foodInGut * 4, FALSE, 0)
|
||||
C.Stun(30)
|
||||
//C.Dizzy(50)
|
||||
|
||||
@@ -87,7 +87,7 @@
|
||||
// Heads?
|
||||
if (target_role == "HEAD")
|
||||
target_amount = rand(1, round(SSticker.mode.num_players() / 20))
|
||||
target_amount = CLAMP(target_amount,1,3)
|
||||
target_amount = clamp(target_amount,1,3)
|
||||
// Department?
|
||||
else
|
||||
switch(target_role)
|
||||
@@ -100,7 +100,7 @@
|
||||
if("Quartermaster")
|
||||
department_string = "Cargo"
|
||||
target_amount = rand(round(SSticker.mode.num_players() / 20), round(SSticker.mode.num_players() / 10))
|
||||
target_amount = CLAMP(target_amount, 2, 4)
|
||||
target_amount = clamp(target_amount, 2, 4)
|
||||
..()
|
||||
|
||||
// EXPLANATION
|
||||
|
||||
@@ -45,15 +45,15 @@
|
||||
// (FINAL LIL WARNING)
|
||||
while(time_til_cycle > 5)
|
||||
sleep(10)
|
||||
if (cancel_me)
|
||||
if(cancel_me)
|
||||
return
|
||||
//sleep(TIME_BLOODSUCKER_DAY_FINAL_WARN - 50)
|
||||
warn_daylight(3,"<span class = 'userdanger'>Seek cover, for Sol rises!</span>")
|
||||
|
||||
// Part 3: Night Ending
|
||||
while (time_til_cycle > 0)
|
||||
while(time_til_cycle > 0)
|
||||
sleep(10)
|
||||
if (cancel_me)
|
||||
if(cancel_me)
|
||||
return
|
||||
//sleep(50)
|
||||
warn_daylight(4,"<span class = 'userdanger'>Solar flares bombard the station with deadly UV light!</span><br><span class = ''>Stay in cover for the next [TIME_BLOODSUCKER_DAY / 60] minutes or risk Final Death!</span>",\
|
||||
@@ -69,11 +69,11 @@
|
||||
while(time_til_cycle > 0)
|
||||
punish_vamps()
|
||||
sleep(TIME_BLOODSUCKER_BURN_INTERVAL)
|
||||
if (cancel_me)
|
||||
if(cancel_me)
|
||||
return
|
||||
//daylight_time -= TIME_BLOODSUCKER_BURN_INTERVAL
|
||||
// Issue Level Up!
|
||||
if(!issued_XP && time_til_cycle <= 15)
|
||||
if(!issued_XP && time_til_cycle <= 5)
|
||||
issued_XP = TRUE
|
||||
vamps_rank_up()
|
||||
|
||||
|
||||
@@ -227,7 +227,7 @@
|
||||
// Traits
|
||||
for(var/T in defaultTraits)
|
||||
REMOVE_TRAIT(owner.current, T, BLOODSUCKER_TRAIT)
|
||||
if(had_toxlover == TRUE)
|
||||
if(had_toxlover)
|
||||
ADD_TRAIT(owner.current, TRAIT_TOXINLOVER, SPECIES_TRAIT)
|
||||
|
||||
// Traits: Species
|
||||
|
||||
@@ -200,39 +200,3 @@
|
||||
to_chat(resident, "<span class='notice'>You fix the mechanism and lock it.</span>")
|
||||
broken = FALSE
|
||||
locked = TRUE
|
||||
|
||||
// Look up recipes.dm OR pneumaticCannon.dm
|
||||
/datum/crafting_recipe/bloodsucker/blackcoffin
|
||||
name = "Black Coffin"
|
||||
result = /obj/structure/closet/crate/coffin/blackcoffin
|
||||
tools = list(/obj/item/weldingtool,
|
||||
/obj/item/screwdriver)
|
||||
reqs = list(/obj/item/stack/sheet/cloth = 1,
|
||||
/obj/item/stack/sheet/mineral/wood = 5,
|
||||
/obj/item/stack/sheet/metal = 1)
|
||||
///obj/item/stack/packageWrap = 8,
|
||||
///obj/item/pipe = 2)
|
||||
time = 150
|
||||
category = CAT_MISC
|
||||
always_availible = TRUE
|
||||
|
||||
/datum/crafting_recipe/bloodsucker/meatcoffin
|
||||
name = "Meat Coffin"
|
||||
result =/obj/structure/closet/crate/coffin/meatcoffin
|
||||
tools = list(/obj/item/kitchen/knife,
|
||||
/obj/item/kitchen/rollingpin)
|
||||
reqs = list(/obj/item/reagent_containers/food/snacks/meat/slab = 5,
|
||||
/obj/item/restraints/handcuffs/cable = 1)
|
||||
time = 150
|
||||
category = CAT_MISC
|
||||
always_availible = TRUE
|
||||
|
||||
/datum/crafting_recipe/bloodsucker/metalcoffin
|
||||
name = "Metal Coffin"
|
||||
result =/obj/structure/closet/crate/coffin/metalcoffin
|
||||
tools = list(/obj/item/weldingtool,
|
||||
/obj/item/screwdriver)
|
||||
reqs = list(/obj/item/stack/sheet/metal = 5)
|
||||
time = 100
|
||||
category = CAT_MISC
|
||||
always_availible = TRUE
|
||||
|
||||
@@ -63,7 +63,7 @@
|
||||
// Find Animals in Area
|
||||
/* if(rand(0,2) == 0)
|
||||
var/mobCount = 0
|
||||
var/mobMax = CLAMP(area_turfs.len / 25, 1, 4)
|
||||
var/mobMax = clamp(area_turfs.len / 25, 1, 4)
|
||||
for (var/turf/T in area_turfs)
|
||||
if(!T) continue
|
||||
var/mob/living/simple_animal/SA = locate() in T
|
||||
|
||||
@@ -18,14 +18,11 @@
|
||||
. = ..()
|
||||
if(!.)
|
||||
return
|
||||
|
||||
// must have nobody around to see the cloak
|
||||
var/watchers = viewers(9,get_turf(owner))
|
||||
for(var/mob/living/M in watchers)
|
||||
for(var/mob/living/M in viewers(9, owner))
|
||||
if(M != owner)
|
||||
to_chat(owner, "<span class='warning'>You may only vanish into the shadows unseen.</span>")
|
||||
return FALSE
|
||||
|
||||
return TRUE
|
||||
|
||||
/datum/action/bloodsucker/cloak/ActivatePower()
|
||||
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
|
||||
/datum/action/bloodsucker/fortitude
|
||||
name = "Fortitude"//"Cellular Emporium"
|
||||
name = "Fortitude"
|
||||
desc = "Withstand egregious physical wounds and walk away from attacks that would stun, pierce, and dismember lesser beings. You cannot run while active."
|
||||
button_icon_state = "power_fortitude"
|
||||
bloodcost = 30
|
||||
@@ -11,28 +11,27 @@
|
||||
bloodsucker_can_buy = TRUE
|
||||
amToggle = TRUE
|
||||
warn_constant_cost = TRUE
|
||||
var/was_running
|
||||
|
||||
var/this_resist // So we can raise and lower your brute resist based on what your level_current WAS.
|
||||
var/fortitude_resist // So we can raise and lower your brute resist based on what your level_current WAS.
|
||||
|
||||
/datum/action/bloodsucker/fortitude/ActivatePower()
|
||||
var/datum/antagonist/bloodsucker/bloodsuckerdatum = owner.mind.has_antag_datum(ANTAG_DATUM_BLOODSUCKER)
|
||||
var/datum/antagonist/bloodsucker/B = owner.mind.has_antag_datum(ANTAG_DATUM_BLOODSUCKER)
|
||||
var/mob/living/user = owner
|
||||
to_chat(user, "<span class='notice'>Your flesh, skin, and muscles become as steel.</span>")
|
||||
// Traits & Effects
|
||||
ADD_TRAIT(user, TRAIT_PIERCEIMMUNE, "fortitude")
|
||||
ADD_TRAIT(user, TRAIT_NODISMEMBER, "fortitude")
|
||||
ADD_TRAIT(user, TRAIT_STUNIMMUNE, "fortitude")
|
||||
ADD_TRAIT(user, TRAIT_NORUNNING, "fortitude")
|
||||
if(ishuman(owner))
|
||||
var/mob/living/carbon/human/H = owner
|
||||
this_resist = max(0.3, 0.7 - level_current * 0.1)
|
||||
H.physiology.brute_mod *= this_resist//0.5
|
||||
H.physiology.burn_mod *= this_resist//0.5
|
||||
// Stop Running (Taken from /datum/quirk/nyctophobia in negative.dm)
|
||||
var/was_running = (user.m_intent == MOVE_INTENT_RUN)
|
||||
fortitude_resist = max(0.3, 0.7 - level_current * 0.1)
|
||||
H.physiology.brute_mod *= fortitude_resist
|
||||
H.physiology.burn_mod *= fortitude_resist
|
||||
was_running = (user.m_intent == MOVE_INTENT_RUN)
|
||||
if(was_running)
|
||||
user.toggle_move_intent()
|
||||
while(bloodsuckerdatum && ContinueActive(user) || user.m_intent == MOVE_INTENT_RUN)
|
||||
while(B && ContinueActive(user) || user.m_intent == MOVE_INTENT_RUN)
|
||||
if(istype(user.buckled, /obj/vehicle)) //We dont want people using fortitude being able to use vehicles
|
||||
var/obj/vehicle/V = user.buckled
|
||||
var/datum/component/riding/VRD = V.GetComponent(/datum/component/riding)
|
||||
@@ -44,20 +43,21 @@
|
||||
to_chat(user, "<span class='notice'>You fall off the [V], your weight making you too heavy to be supported by it.</span>")
|
||||
// Pay Blood Toll (if awake)
|
||||
if(user.stat == CONSCIOUS)
|
||||
bloodsuckerdatum.AddBloodVolume(-0.5) // Used to be 0.3 blood per 2 seconds, but we're making it more expensive to keep on.
|
||||
B.AddBloodVolume(-0.5)
|
||||
sleep(20) // Check every few ticks that we haven't disabled this power
|
||||
// Return to Running (if you were before)
|
||||
if(was_running && user.m_intent != MOVE_INTENT_RUN)
|
||||
user.toggle_move_intent()
|
||||
|
||||
|
||||
/datum/action/bloodsucker/fortitude/DeactivatePower(mob/living/user = owner, mob/living/target)
|
||||
..()
|
||||
// Restore Traits & Effects
|
||||
REMOVE_TRAIT(user, TRAIT_PIERCEIMMUNE, "fortitude")
|
||||
REMOVE_TRAIT(user, TRAIT_NODISMEMBER, "fortitude")
|
||||
REMOVE_TRAIT(user, TRAIT_STUNIMMUNE, "fortitude")
|
||||
REMOVE_TRAIT(user, TRAIT_NORUNNING, "fortitude")
|
||||
if(ishuman(owner))
|
||||
var/mob/living/carbon/human/H = owner
|
||||
H.physiology.brute_mod /= this_resist//0.5
|
||||
H.physiology.burn_mod /= this_resist//0.5
|
||||
if(!ishuman(owner))
|
||||
return
|
||||
var/mob/living/carbon/human/H = owner
|
||||
H.physiology.brute_mod /= fortitude_resist
|
||||
H.physiology.burn_mod /= fortitude_resist
|
||||
if(was_running && user.m_intent == MOVE_INTENT_WALK)
|
||||
user.toggle_move_intent()
|
||||
|
||||
|
||||
@@ -1,88 +1,46 @@
|
||||
// Level 1: Grapple level 2
|
||||
// Level 2: Grapple 3 from Behind
|
||||
// Level 3: Grapple 3 from Shadows
|
||||
/datum/action/bloodsucker/targeted/lunge
|
||||
|
||||
|
||||
/datum/action/bloodsucker/lunge
|
||||
name = "Predatory Lunge"
|
||||
desc = "Spring at your target and aggressively grapple them without warning. Attacks from concealment or the rear may even knock them down."
|
||||
desc = "Prepare the strenght to grapple your prey."
|
||||
button_icon_state = "power_lunge"
|
||||
bloodcost = 10
|
||||
cooldown = 120
|
||||
target_range = 3
|
||||
power_activates_immediately = TRUE
|
||||
message_Trigger = "Whom will you ensnare within your grasp?"
|
||||
must_be_capacitated = TRUE
|
||||
cooldown = 30
|
||||
bloodsucker_can_buy = TRUE
|
||||
warn_constant_cost = TRUE
|
||||
amToggle = TRUE
|
||||
var/leap_skill_mod = 5
|
||||
|
||||
/datum/action/bloodsucker/targeted/lunge/CheckCanUse(display_error)
|
||||
if(!..(display_error))// DEFAULT CHECKS
|
||||
return FALSE
|
||||
// Being Grabbed
|
||||
if(owner.pulledby && owner.pulledby.grab_state >= GRAB_AGGRESSIVE)
|
||||
if(display_error)
|
||||
to_chat(owner, "<span class='warning'>You're being grabbed!</span>")
|
||||
return FALSE
|
||||
if(!owner.has_gravity(owner.loc))//TODO figure out how to check if theyre able to move while in nograv
|
||||
if(display_error)
|
||||
to_chat(owner, "<span class='warning'>You cant lunge while floating!</span>")
|
||||
return FALSE
|
||||
return TRUE
|
||||
/datum/action/bloodsucker/lunge/New()
|
||||
. = ..()
|
||||
|
||||
|
||||
/datum/action/bloodsucker/targeted/lunge/CheckValidTarget(atom/A)
|
||||
return iscarbon(A)
|
||||
/datum/action/bloodsucker/lunge/Destroy()
|
||||
. = ..()
|
||||
UnregisterSignal(owner, COMSIG_CARBON_TACKLED)
|
||||
|
||||
/datum/action/bloodsucker/targeted/lunge/CheckCanTarget(atom/A, display_error)
|
||||
// Check: Self
|
||||
if(target == owner)
|
||||
return FALSE
|
||||
// Check: Range
|
||||
//if (!(target in view(target_range, get_turf(owner))))
|
||||
// if (display_error)
|
||||
// to_chat(owner, "<span class='warning'>Your victim is too far away.</span>")
|
||||
// return FALSE
|
||||
// DEFAULT CHECKS (Distance)
|
||||
if(!..())
|
||||
return FALSE
|
||||
// Check: Turf
|
||||
var/mob/living/L = A
|
||||
if(!isturf(L.loc))
|
||||
return FALSE
|
||||
return TRUE
|
||||
/datum/action/bloodsucker/lunge/ActivatePower()
|
||||
var/mob/living/carbon/user = owner
|
||||
var/datum/antagonist/bloodsucker/B = user.mind.has_antag_datum(ANTAG_DATUM_BLOODSUCKER)
|
||||
var/datum/component/tackler/T = user.LoadComponent(/datum/component/tackler)
|
||||
T.stamina_cost = 50
|
||||
T.base_knockdown = 3 SECONDS
|
||||
T.range = 4
|
||||
T.speed = 0.8
|
||||
T.skill_mod = 5 //Monstrous tackling
|
||||
T.min_distance = 2
|
||||
active = TRUE
|
||||
user.toggle_throw_mode()
|
||||
RegisterSignal(user, COMSIG_CARBON_TACKLED, .proc/DelayedDeactivatePower)
|
||||
while(B && ContinueActive(user))
|
||||
B.AddBloodVolume(-0.1)
|
||||
sleep(5)
|
||||
|
||||
/datum/action/bloodsucker/targeted/lunge/FireTargetedPower(atom/A)
|
||||
// set waitfor = FALSE <---- DONT DO THIS!We WANT this power to hold up ClickWithPower(), so that we can unlock the power when it's done.
|
||||
var/mob/living/carbon/target = A
|
||||
var/turf/T = get_turf(target)
|
||||
var/mob/living/L = owner
|
||||
// Clear Vars
|
||||
owner.pulling = null
|
||||
// Will we Knock them Down?
|
||||
var/do_knockdown = !is_A_facing_B(target,owner) || owner.alpha <= 0 || istype(owner.loc, /obj/structure/closet)
|
||||
// CAUSES: Target has their back to me, I'm invisible, or I'm in a Closet
|
||||
// Step One: Heatseek toward Target's Turf
|
||||
addtimer(CALLBACK(GLOBAL_PROC, .proc/_walk, owner, 0), 2 SECONDS)
|
||||
target.playsound_local(get_turf(owner), 'sound/bloodsucker/lunge_warn.ogg', 60, FALSE, pressure_affected = FALSE) // target-only telegraphing
|
||||
owner.playsound_local(owner, 'sound/bloodsucker/lunge_warn.ogg', 60, FALSE, pressure_affected = FALSE) // audio feedback to the user
|
||||
if(do_mob(owner, owner, 7, TRUE, TRUE))
|
||||
walk_towards(owner, T, 0.1, 10) // yes i know i shouldn't use this but i don't know how to work in anything better
|
||||
if(get_turf(owner) != T && !(isliving(target) && target.Adjacent(owner)) && owner.incapacitated() && !CHECK_MOBILITY(L, MOBILITY_STAND))
|
||||
var/send_dir = get_dir(owner, T)
|
||||
new /datum/forced_movement(owner, get_ranged_target_turf(owner, send_dir, 1), 1, FALSE)
|
||||
owner.spin(10)
|
||||
// Step Two: Check if I'm at/adjectent to Target's CURRENT turf (not original...that was just a destination)
|
||||
for(var/i in 1 to 6)
|
||||
if (target.Adjacent(owner))
|
||||
// LEVEL 2: If behind target, mute or unconscious!
|
||||
if(do_knockdown) // && level_current >= 1)
|
||||
target.Knockdown(15 + 10 * level_current,1)
|
||||
target.adjustStaminaLoss(40 + 10 * level_current)
|
||||
// Cancel Walk (we were close enough to contact them)
|
||||
walk(owner, 0)
|
||||
target.Stun(10,1) //Without this the victim can just walk away
|
||||
target.grabbedby(owner) // Taken from mutations.dm under changelings
|
||||
target.grippedby(owner, instant = TRUE) //instant aggro grab
|
||||
break
|
||||
sleep(3)
|
||||
//Without this, the leap component would get removed too early, causing the normal crash into effects.
|
||||
/datum/action/bloodsucker/lunge/proc/DelayedDeactivatePower()
|
||||
addtimer(CALLBACK(src, .proc/DeactivatePower), 1 SECONDS, TIMER_UNIQUE)
|
||||
|
||||
/datum/action/bloodsucker/targeted/lunge/DeactivatePower(mob/living/user = owner, mob/living/target)
|
||||
..() // activate = FALSE
|
||||
user.update_mobility()
|
||||
/datum/action/bloodsucker/lunge/DeactivatePower(mob/living/user = owner)
|
||||
. = ..()
|
||||
qdel(user.GetComponent(/datum/component/tackler))
|
||||
UnregisterSignal(user, COMSIG_CARBON_TACKLED)
|
||||
|
||||
@@ -52,6 +52,7 @@
|
||||
REMOVE_TRAIT(user, TRAIT_NOHARDCRIT, "bloodsucker")
|
||||
REMOVE_TRAIT(user, TRAIT_NOSOFTCRIT, "bloodsucker")
|
||||
REMOVE_TRAIT(user, TRAIT_VIRUSIMMUNE, "bloodsucker")
|
||||
REMOVE_TRAIT(user, TRAIT_NOBREATH, "bloodsucker")
|
||||
var/obj/item/organ/heart/vampheart/H = user.getorganslot(ORGAN_SLOT_HEART)
|
||||
var/obj/item/organ/eyes/vassal/bloodsucker/E = user.getorganslot(ORGAN_SLOT_EYES)
|
||||
E.flash_protect = 0
|
||||
@@ -93,6 +94,7 @@
|
||||
ADD_TRAIT(user, TRAIT_NOHARDCRIT, "bloodsucker")
|
||||
ADD_TRAIT(user, TRAIT_NOSOFTCRIT, "bloodsucker")
|
||||
ADD_TRAIT(user, TRAIT_VIRUSIMMUNE, "bloodsucker")
|
||||
ADD_TRAIT(user, TRAIT_NOBREATH, "bloodsucker")
|
||||
|
||||
// HEART
|
||||
var/obj/item/organ/heart/H = user.getorganslot(ORGAN_SLOT_HEART)
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
|
||||
/datum/action/bloodsucker/targeted/trespass/CheckValidTarget(atom/A)
|
||||
// Can't target my tile
|
||||
if (A == get_turf(owner) || get_turf(A) == get_turf(owner))
|
||||
if(A == get_turf(owner) || get_turf(A) == get_turf(owner))
|
||||
return FALSE
|
||||
|
||||
return TRUE // All we care about is destination. Anything you click is fine.
|
||||
@@ -43,13 +43,13 @@
|
||||
// Are either tiles WALLS?
|
||||
var/turf/from_turf = get_turf(owner)
|
||||
var/this_dir // = get_dir(from_turf, target_turf)
|
||||
for (var/i=1 to 2)
|
||||
for(var/i=1 to 2)
|
||||
// Keep Prev Direction if we've reached final turf
|
||||
if (from_turf != final_turf)
|
||||
if(from_turf != final_turf)
|
||||
this_dir = get_dir(from_turf, final_turf) // Recalculate dir so we don't overshoot on a diagonal.
|
||||
from_turf = get_step(from_turf, this_dir)
|
||||
// ERROR! Wall!
|
||||
if (iswallturf(from_turf))
|
||||
if(iswallturf(from_turf))
|
||||
if (display_error)
|
||||
var/wallwarning = (i == 1) ? "in the way" : "at your destination"
|
||||
to_chat(owner, "<span class='warning'>There is a solid wall [wallwarning].</span>")
|
||||
@@ -84,7 +84,7 @@
|
||||
user.next_move = world.time + mist_delay
|
||||
user.Stun(mist_delay, ignore_canstun = TRUE)
|
||||
user.notransform = TRUE
|
||||
user.density = 0
|
||||
user.density = FALSE
|
||||
var/invis_was = user.invisibility
|
||||
user.invisibility = INVISIBILITY_MAXIMUM
|
||||
|
||||
@@ -94,7 +94,7 @@
|
||||
sleep(mist_delay / 2)
|
||||
|
||||
// Move & Freeze
|
||||
if (isturf(target_turf))
|
||||
if(isturf(target_turf))
|
||||
do_teleport(owner, target_turf, no_effects=TRUE, channel = TELEPORT_CHANNEL_QUANTUM) // in teleport.dm?
|
||||
user.next_move = world.time + mist_delay / 2
|
||||
user.Stun(mist_delay / 2, ignore_canstun = TRUE)
|
||||
|
||||
@@ -93,7 +93,7 @@
|
||||
H.socks = random_socks(H.gender)
|
||||
//H.eye_color = random_eye_color()
|
||||
REMOVE_TRAIT(H, TRAIT_DISFIGURED, null) //
|
||||
H.dna.features = random_features(H.dna.species?.id)
|
||||
H.dna.features = random_features(H.dna.species?.id, H.gender)
|
||||
|
||||
// Apply Appearance
|
||||
H.update_body(TRUE) // Outfit and underwear, also body and privates.
|
||||
|
||||
@@ -111,7 +111,7 @@
|
||||
if(objective.completable)
|
||||
var/completion = objective.check_completion()
|
||||
if(completion >= 1)
|
||||
parts += "<B>Objective #[objective_count]</B>: [objective.explanation_text] <span class='greentext'><B>Success!</span>"
|
||||
parts += "<B>Objective #[objective_count]</B>: [objective.explanation_text] <span class='greentext'><B>Success!</B></span>"
|
||||
else if(completion <= 0)
|
||||
parts += "<B>Objective #[objective_count]</B>: [objective.explanation_text] <span class='redtext'>Fail.</span>"
|
||||
win = FALSE
|
||||
|
||||
@@ -430,7 +430,7 @@
|
||||
objectives += destroy_objective
|
||||
else
|
||||
if(prob(70))
|
||||
var/datum/objective/assassinate/kill_objective = new
|
||||
var/datum/objective/assassinate/once/kill_objective = new
|
||||
kill_objective.owner = owner
|
||||
if(team_mode) //No backstabbing while in a team
|
||||
kill_objective.find_target_by_role(role = ROLE_CHANGELING, role_type = 1, invert = 1)
|
||||
@@ -563,7 +563,7 @@
|
||||
if(objective.completable)
|
||||
var/completion = objective.check_completion()
|
||||
if(completion >= 1)
|
||||
parts += "<B>Objective #[count]</B>: [objective.explanation_text] <span class='greentext'><B>Success!</span>"
|
||||
parts += "<B>Objective #[count]</B>: [objective.explanation_text] <span class='greentext'><B>Success!</B></span>"
|
||||
else if(completion <= 0)
|
||||
parts += "<B>Objective #[count]</B>: [objective.explanation_text] <span class='redtext'>Fail.</span>"
|
||||
changelingwin = FALSE
|
||||
|
||||
@@ -27,7 +27,7 @@
|
||||
|
||||
changeling.purchasedpowers -= src
|
||||
|
||||
var/newmob = user.humanize(TR_KEEPITEMS | TR_KEEPIMPLANTS | TR_KEEPORGANS | TR_KEEPDAMAGE | TR_KEEPVIRUS)
|
||||
var/newmob = user.humanize(TR_KEEPITEMS | TR_KEEPIMPLANTS | TR_KEEPORGANS | TR_KEEPDAMAGE | TR_KEEPVIRUS | TR_KEEPSE)
|
||||
|
||||
changeling_transform(newmob, chosen_prof)
|
||||
return TRUE
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
to_chat(user, "<span class='notice'>Our muscles tense and strengthen.</span>")
|
||||
changeling.chem_recharge_slowdown += 0.5
|
||||
else
|
||||
user.remove_movespeed_modifier(MOVESPEED_ID_CHANGELING_MUSCLES)
|
||||
user.remove_movespeed_modifier(/datum/movespeed_modifier/strained_muscles)
|
||||
to_chat(user, "<span class='notice'>Our muscles relax.</span>")
|
||||
changeling.chem_recharge_slowdown -= 0.5
|
||||
if(stacks >= 20)
|
||||
@@ -36,12 +36,12 @@
|
||||
/obj/effect/proc_holder/changeling/strained_muscles/proc/muscle_loop(mob/living/carbon/user)
|
||||
var/datum/antagonist/changeling/changeling = user.mind.has_antag_datum(/datum/antagonist/changeling)
|
||||
while(active)
|
||||
user.add_movespeed_modifier(MOVESPEED_ID_CHANGELING_MUSCLES, update=TRUE, priority=100, multiplicative_slowdown=-1, blacklisted_movetypes=(FLYING|FLOATING))
|
||||
user.add_movespeed_modifier(/datum/movespeed_modifier/strained_muscles)
|
||||
if(user.stat != CONSCIOUS || user.staminaloss >= 90)
|
||||
active = !active
|
||||
to_chat(user, "<span class='notice'>Our muscles relax without the energy to strengthen them.</span>")
|
||||
user.DefaultCombatKnockdown(40)
|
||||
user.remove_movespeed_modifier(MOVESPEED_ID_CHANGELING_MUSCLES)
|
||||
user.remove_movespeed_modifier(/datum/movespeed_modifier/strained_muscles)
|
||||
changeling.chem_recharge_slowdown -= 0.5
|
||||
break
|
||||
|
||||
|
||||
@@ -239,7 +239,7 @@
|
||||
if(!do_after(user, repair_values["healing_for_cycle"] * fabricator.speed_multiplier, target = src, \
|
||||
extra_checks = CALLBACK(fabricator, /obj/item/clockwork/replica_fabricator.proc/fabricator_repair_checks, repair_values, src, user, TRUE)))
|
||||
break
|
||||
obj_integrity = CLAMP(obj_integrity + repair_values["healing_for_cycle"], 0, max_integrity)
|
||||
obj_integrity = clamp(obj_integrity + repair_values["healing_for_cycle"], 0, max_integrity)
|
||||
adjust_clockwork_power(-repair_values["power_required"])
|
||||
playsound(src, 'sound/machines/click.ogg', 50, 1)
|
||||
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
if(GLOB.ratvar_awakens)
|
||||
current_power = GLOB.clockwork_power = INFINITY
|
||||
else
|
||||
current_power = GLOB.clockwork_power = CLAMP(GLOB.clockwork_power + amount, 0, MAX_CLOCKWORK_POWER)
|
||||
current_power = GLOB.clockwork_power = clamp(GLOB.clockwork_power + amount, 0, MAX_CLOCKWORK_POWER)
|
||||
for(var/obj/effect/clockwork/sigil/transmission/T in GLOB.all_clockwork_objects)
|
||||
T.update_icon()
|
||||
var/unlock_message
|
||||
|
||||
@@ -211,7 +211,7 @@
|
||||
var/mob/living/carbon/C = L
|
||||
C.stuttering = max(8, C.stuttering)
|
||||
C.drowsyness = max(8, C.drowsyness)
|
||||
C.confused += CLAMP(16 - C.confused, 0, 8)
|
||||
C.confused += clamp(16 - C.confused, 0, 8)
|
||||
C.apply_status_effect(STATUS_EFFECT_BELLIGERENT)
|
||||
L.adjustFireLoss(15)
|
||||
..()
|
||||
|
||||
@@ -59,7 +59,7 @@
|
||||
if(issilicon(L))
|
||||
L.DefaultCombatKnockdown(100)
|
||||
else if(iscultist(L))
|
||||
L.confused += CLAMP(10 - L.confused, 0, 5) // Spearthrow now confuses enemy cultists + just deals extra damage / sets on fire instead of hardstunning + damage
|
||||
L.confused += clamp(10 - L.confused, 0, 5) // Spearthrow now confuses enemy cultists + just deals extra damage / sets on fire instead of hardstunning + damage
|
||||
to_chat(L, "<span class ='userdanger'>[src] crashes into you with burning force, sending you reeling!</span>")
|
||||
L.adjust_fire_stacks(2)
|
||||
L.DefaultCombatKnockdown(1)
|
||||
|
||||
@@ -111,7 +111,7 @@
|
||||
var/mob/living/L = M.current
|
||||
if(ishuman(L) && L.stat != DEAD)
|
||||
human_servants++
|
||||
construct_limit = round(CLAMP((human_servants / 4), 1, 3)) //1 per 4 human servants, maximum of 3
|
||||
construct_limit = round(clamp((human_servants / 4), 1, 3)) //1 per 4 human servants, maximum of 3
|
||||
|
||||
//Summon Neovgre: Summon a very powerful combat mech that explodes when destroyed for massive damage.
|
||||
/datum/clockwork_scripture/create_object/summon_arbiter
|
||||
|
||||
@@ -63,4 +63,4 @@
|
||||
break
|
||||
if(!M)
|
||||
M = H.apply_status_effect(STATUS_EFFECT_MANIAMOTOR, src)
|
||||
M.severity = CLAMP(M.severity + ((11 - get_dist(src, H)) * efficiency * efficiency), 0, MAX_MANIA_SEVERITY)
|
||||
M.severity = clamp(M.severity + ((11 - get_dist(src, H)) * efficiency * efficiency), 0, MAX_MANIA_SEVERITY)
|
||||
|
||||
@@ -454,16 +454,16 @@
|
||||
S.emp_act(EMP_HEAVY)
|
||||
else if(iscarbon(target))
|
||||
var/mob/living/carbon/C = L
|
||||
C.silent += CLAMP(12 - C.silent, 0, 6)
|
||||
C.stuttering += CLAMP(30 - C.stuttering, 0, 15)
|
||||
C.cultslurring += CLAMP(30 - C.cultslurring, 0, 15)
|
||||
C.silent += clamp(12 - C.silent, 0, 6)
|
||||
C.stuttering += clamp(30 - C.stuttering, 0, 15)
|
||||
C.cultslurring += clamp(30 - C.cultslurring, 0, 15)
|
||||
C.Jitter(15)
|
||||
else // cultstun no longer hardstuns + damages hostile cultists, instead debuffs them hard + deals some damage; debuffs for a bit longer since they don't add the clockie belligerent debuff
|
||||
if(iscarbon(target))
|
||||
var/mob/living/carbon/C = L
|
||||
C.stuttering = max(10, C.stuttering)
|
||||
C.drowsyness = max(10, C.drowsyness)
|
||||
C.confused += CLAMP(20 - C.confused, 0, 10)
|
||||
C.confused += clamp(20 - C.confused, 0, 10)
|
||||
L.adjustBruteLoss(15)
|
||||
to_chat(user, "<span class='cultitalic'>In an brilliant flash of red, [L] [iscultist(L) ? "writhes in pain" : "falls to the ground!"]</span>")
|
||||
uses--
|
||||
|
||||
@@ -441,7 +441,7 @@
|
||||
if(objective.completable)
|
||||
var/completion = objective.check_completion()
|
||||
if(completion >= 1)
|
||||
parts += "<B>Objective #[count]</B>: [objective.explanation_text] <span class='greentext'><B>Success!</span>"
|
||||
parts += "<B>Objective #[count]</B>: [objective.explanation_text] <span class='greentext'><B>Success!</B></span>"
|
||||
else if(completion <= 0)
|
||||
parts += "<B>Objective #[count]</B>: [objective.explanation_text] <span class='redtext'>Fail.</span>"
|
||||
else
|
||||
|
||||
@@ -539,7 +539,7 @@
|
||||
if(SSshuttle.emergency.mode == SHUTTLE_CALL)
|
||||
var/cursetime = 1800
|
||||
var/timer = SSshuttle.emergency.timeLeft(1) + cursetime
|
||||
var/security_num = seclevel2num(get_security_level())
|
||||
var/security_num = SECLEVEL2NUM(NUM2SECLEVEL(GLOB.security_level))
|
||||
var/set_coefficient = 1
|
||||
switch(security_num)
|
||||
if(SEC_LEVEL_GREEN)
|
||||
@@ -731,7 +731,7 @@
|
||||
if(!L.anti_magic_check())
|
||||
if(is_servant_of_ratvar(L))
|
||||
to_chat(L, "<span class='cultlarge'>\"Kneel for me, scum\"</span>")
|
||||
L.confused += CLAMP(10 - L.confused, 0, 5) //confuses and lightly knockdowns + damages hostile cultists instead of hardstunning like before
|
||||
L.confused += clamp(10 - L.confused, 0, 5) //confuses and lightly knockdowns + damages hostile cultists instead of hardstunning like before
|
||||
L.DefaultCombatKnockdown(15)
|
||||
L.adjustBruteLoss(10)
|
||||
else
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
if(objective.completable)
|
||||
var/completion = objective.check_completion()
|
||||
if(completion >= 1)
|
||||
result += "<B>Objective #[count]</B>: [objective.explanation_text] <span class='greentext'><B>Success!</span>"
|
||||
result += "<B>Objective #[count]</B>: [objective.explanation_text] <span class='greentext'><B>Success!</B></span>"
|
||||
else if(completion <= 0)
|
||||
result += "<B>Objective #[count]</B>: [objective.explanation_text] <span class='redtext'>Fail.</span>"
|
||||
win = FALSE
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
STOP_PROCESSING(SSobj, core)
|
||||
update_icon()
|
||||
GLOB.poi_list |= src
|
||||
previous_level = get_security_level()
|
||||
previous_level = NUM2SECLEVEL(GLOB.security_level)
|
||||
|
||||
/obj/machinery/nuclearbomb/Destroy()
|
||||
safety = FALSE
|
||||
@@ -358,7 +358,7 @@
|
||||
if(NUKEUI_AWAIT_TIMER)
|
||||
var/number_value = text2num(numeric_input)
|
||||
if(number_value)
|
||||
timer_set = CLAMP(number_value, minimum_timer_set, maximum_timer_set)
|
||||
timer_set = clamp(number_value, minimum_timer_set, maximum_timer_set)
|
||||
playsound(src, 'sound/machines/nuke/general_beep.ogg', 50, FALSE)
|
||||
set_safety()
|
||||
. = TRUE
|
||||
@@ -419,7 +419,7 @@
|
||||
return
|
||||
timing = !timing
|
||||
if(timing)
|
||||
previous_level = get_security_level()
|
||||
previous_level = NUM2SECLEVEL(GLOB.security_level)
|
||||
detonation_timer = world.time + (timer_set * 10)
|
||||
for(var/obj/item/pinpointer/nuke/syndicate/S in GLOB.pinpointer_list)
|
||||
S.switch_mode_to(TRACK_INFILTRATOR)
|
||||
|
||||
@@ -64,8 +64,8 @@
|
||||
|
||||
/mob/living/simple_animal/slaughter/phasein()
|
||||
. = ..()
|
||||
add_movespeed_modifier(MOVESPEED_ID_SLAUGHTER, update=TRUE, priority=100, multiplicative_slowdown=-1)
|
||||
addtimer(CALLBACK(src, .proc/remove_movespeed_modifier, MOVESPEED_ID_SLAUGHTER, TRUE), 6 SECONDS, TIMER_UNIQUE | TIMER_OVERRIDE)
|
||||
add_movespeed_modifier(/datum/movespeed_modifier/slaughter)
|
||||
addtimer(CALLBACK(src, .proc/remove_movespeed_modifier, /datum/movespeed_modifier/slaughter), 6 SECONDS, TIMER_UNIQUE | TIMER_OVERRIDE)
|
||||
|
||||
|
||||
//The loot from killing a slaughter demon - can be consumed to allow the user to blood crawl
|
||||
|
||||
@@ -239,7 +239,7 @@
|
||||
if(objective.completable)
|
||||
var/completion = objective.check_completion()
|
||||
if(completion >= 1)
|
||||
objectives_text += "<br><B>Objective #[count]</B>: [objective.explanation_text] <span class='greentext'><B>Success!</span>"
|
||||
objectives_text += "<br><B>Objective #[count]</B>: [objective.explanation_text] <span class='greentext'><B>Success!</B></span>"
|
||||
else if(completion <= 0)
|
||||
objectives_text += "<br><B>Objective #[count]</B>: [objective.explanation_text] <span class='redtext'>Fail.</span>"
|
||||
traitorwin = FALSE
|
||||
|
||||
@@ -159,7 +159,7 @@
|
||||
/obj/item/scrying/attack_self(mob/user)
|
||||
to_chat(user, "<span class='notice'>You can see...everything!</span>")
|
||||
visible_message("<span class='danger'>[user] stares into [src], their eyes glazing over.</span>")
|
||||
user.ghostize(1)
|
||||
user.ghostize(1, voluntary = TRUE)
|
||||
|
||||
/////////////////////////////////////////Necromantic Stone///////////////////
|
||||
|
||||
|
||||
@@ -294,7 +294,7 @@
|
||||
name = "Staff of Change"
|
||||
desc = "An artefact that spits bolts of coruscating energy which cause the target's very form to reshape itself."
|
||||
item_path = /obj/item/gun/magic/staff/change
|
||||
dynamic_requirement = 60
|
||||
dynamic_requirement = 200
|
||||
|
||||
/datum/spellbook_entry/item/staffanimation
|
||||
name = "Staff of Animation"
|
||||
@@ -361,7 +361,7 @@
|
||||
desc = "A collection of wands that allow for a wide variety of utility. Wands have a limited number of charges, so be conservative in use. Comes in a handy belt."
|
||||
item_path = /obj/item/storage/belt/wands/full
|
||||
category = "Defensive"
|
||||
dynamic_requirement = 60
|
||||
dynamic_requirement = 200
|
||||
|
||||
/datum/spellbook_entry/item/armor
|
||||
name = "Mastercrafted Armor Set"
|
||||
@@ -386,7 +386,7 @@
|
||||
name = "Plasma Fist"
|
||||
desc = "A forbidden martial art designed on the surging power of plasma. Use it to harness the ancient power."
|
||||
item_path = /obj/item/book/granter/martial/plasma_fist
|
||||
cost = 3
|
||||
cost = 2
|
||||
|
||||
/datum/spellbook_entry/item/guardian
|
||||
name = "Guardian Deck"
|
||||
|
||||
@@ -269,7 +269,7 @@
|
||||
if(objective.completable)
|
||||
var/completion = objective.check_completion()
|
||||
if(completion >= 1)
|
||||
parts += "<B>Objective #[count]</B>: [objective.explanation_text] <span class='greentext'><B>Success!</span>"
|
||||
parts += "<B>Objective #[count]</B>: [objective.explanation_text] <span class='greentext'><B>Success!</B></span>"
|
||||
else if(completion <= 0)
|
||||
parts += "<B>Objective #[count]</B>: [objective.explanation_text] <span class='redtext'>Fail.</span>"
|
||||
wizardwin = FALSE
|
||||
|
||||
@@ -229,6 +229,7 @@
|
||||
var/flashcd = 20
|
||||
var/overheat = 0
|
||||
var/obj/item/organ/cyberimp/arm/flash/I = null
|
||||
var/active_light_strength = 7
|
||||
|
||||
/obj/item/assembly/flash/armimplant/burn_out()
|
||||
if(I && I.owner)
|
||||
@@ -248,6 +249,12 @@
|
||||
update_icon(1)
|
||||
return TRUE
|
||||
|
||||
/obj/item/assembly/flash/armimplant/Moved(oldLoc, dir)
|
||||
. = ..()
|
||||
if(!ismob(loc))
|
||||
set_light(0)
|
||||
else
|
||||
set_light(7)
|
||||
|
||||
/obj/item/assembly/flash/armimplant/proc/cooldown()
|
||||
overheat = FALSE
|
||||
|
||||
@@ -192,6 +192,7 @@ GLOBAL_LIST_INIT(nonreactive_gases, typecacheof(list(/datum/gas/oxygen, /datum/g
|
||||
anchored = TRUE // should only appear in vis_contents, but to be safe
|
||||
layer = FLY_LAYER
|
||||
appearance_flags = TILE_BOUND
|
||||
vis_flags = NONE
|
||||
|
||||
/obj/effect/overlay/gas/New(state, alph)
|
||||
. = ..()
|
||||
|
||||
@@ -282,7 +282,7 @@
|
||||
|
||||
var/new_heat_capacity = air.heat_capacity()
|
||||
if(new_heat_capacity > MINIMUM_HEAT_CAPACITY)
|
||||
air.temperature = CLAMP(((air.temperature*old_heat_capacity + reaction_energy)/new_heat_capacity),TCMB,INFINITY)
|
||||
air.temperature = clamp(((air.temperature*old_heat_capacity + reaction_energy)/new_heat_capacity),TCMB,INFINITY)
|
||||
return REACTING
|
||||
|
||||
/datum/gas_reaction/nitrylformation //The formation of nitryl. Endothermic. Requires N2O as a catalyst.
|
||||
|
||||
@@ -159,13 +159,13 @@
|
||||
pump_direction = 1
|
||||
|
||||
if("set_input_pressure" in signal.data)
|
||||
input_pressure_min = CLAMP(text2num(signal.data["set_input_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
input_pressure_min = clamp(text2num(signal.data["set_input_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
|
||||
if("set_output_pressure" in signal.data)
|
||||
output_pressure_max = CLAMP(text2num(signal.data["set_output_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
output_pressure_max = clamp(text2num(signal.data["set_output_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
|
||||
if("set_external_pressure" in signal.data)
|
||||
external_pressure_bound = CLAMP(text2num(signal.data["set_external_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
external_pressure_bound = clamp(text2num(signal.data["set_external_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
|
||||
if("status" in signal.data)
|
||||
spawn(2)
|
||||
|
||||
@@ -122,7 +122,7 @@ Passive gate is similar to the regular pump except:
|
||||
pressure = text2num(pressure)
|
||||
. = TRUE
|
||||
if(.)
|
||||
target_pressure = CLAMP(pressure, 0, MAX_OUTPUT_PRESSURE)
|
||||
target_pressure = clamp(pressure, 0, MAX_OUTPUT_PRESSURE)
|
||||
investigate_log("was set to [target_pressure] kPa by [key_name(usr)]", INVESTIGATE_ATMOS)
|
||||
update_icon()
|
||||
|
||||
@@ -144,7 +144,7 @@ Passive gate is similar to the regular pump except:
|
||||
on = !on
|
||||
|
||||
if("set_output_pressure" in signal.data)
|
||||
target_pressure = CLAMP(text2num(signal.data["set_output_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
target_pressure = clamp(text2num(signal.data["set_output_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
|
||||
if(on != old_on)
|
||||
investigate_log("was turned [on ? "on" : "off"] by a remote signal", INVESTIGATE_ATMOS)
|
||||
|
||||
@@ -145,7 +145,7 @@
|
||||
pressure = text2num(pressure)
|
||||
. = TRUE
|
||||
if(.)
|
||||
target_pressure = CLAMP(pressure, 0, MAX_OUTPUT_PRESSURE)
|
||||
target_pressure = clamp(pressure, 0, MAX_OUTPUT_PRESSURE)
|
||||
investigate_log("was set to [target_pressure] kPa by [key_name(usr)]", INVESTIGATE_ATMOS)
|
||||
update_icon()
|
||||
|
||||
@@ -167,7 +167,7 @@
|
||||
on = !on
|
||||
|
||||
if("set_output_pressure" in signal.data)
|
||||
target_pressure = CLAMP(text2num(signal.data["set_output_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
target_pressure = clamp(text2num(signal.data["set_output_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
|
||||
if(on != old_on)
|
||||
investigate_log("was turned [on ? "on" : "off"] by a remote signal", INVESTIGATE_ATMOS)
|
||||
|
||||
@@ -91,7 +91,7 @@
|
||||
pressure = text2num(pressure)
|
||||
. = TRUE
|
||||
if(.)
|
||||
open_pressure = CLAMP(pressure, close_pressure, 50*ONE_ATMOSPHERE)
|
||||
open_pressure = clamp(pressure, close_pressure, 50*ONE_ATMOSPHERE)
|
||||
investigate_log("open pressure was set to [open_pressure] kPa by [key_name(usr)]", INVESTIGATE_ATMOS)
|
||||
if("close_pressure")
|
||||
var/pressure = params["close_pressure"]
|
||||
@@ -106,6 +106,6 @@
|
||||
pressure = text2num(pressure)
|
||||
. = TRUE
|
||||
if(.)
|
||||
close_pressure = CLAMP(pressure, 0, open_pressure)
|
||||
close_pressure = clamp(pressure, 0, open_pressure)
|
||||
investigate_log("close pressure was set to [close_pressure] kPa by [key_name(usr)]", INVESTIGATE_ATMOS)
|
||||
update_icon()
|
||||
|
||||
@@ -135,7 +135,7 @@
|
||||
rate = text2num(rate)
|
||||
. = TRUE
|
||||
if(.)
|
||||
transfer_rate = CLAMP(rate, 0, MAX_TRANSFER_RATE)
|
||||
transfer_rate = clamp(rate, 0, MAX_TRANSFER_RATE)
|
||||
investigate_log("was set to [transfer_rate] L/s by [key_name(usr)]", INVESTIGATE_ATMOS)
|
||||
update_icon()
|
||||
|
||||
@@ -153,7 +153,7 @@
|
||||
|
||||
if("set_transfer_rate" in signal.data)
|
||||
var/datum/gas_mixture/air1 = airs[1]
|
||||
transfer_rate = CLAMP(text2num(signal.data["set_transfer_rate"]),0,air1.volume)
|
||||
transfer_rate = clamp(text2num(signal.data["set_transfer_rate"]),0,air1.volume)
|
||||
|
||||
if(on != old_on)
|
||||
investigate_log("was turned [on ? "on" : "off"] by a remote signal", INVESTIGATE_ATMOS)
|
||||
|
||||
@@ -175,7 +175,7 @@
|
||||
rate = text2num(rate)
|
||||
. = TRUE
|
||||
if(.)
|
||||
transfer_rate = CLAMP(rate, 0, MAX_TRANSFER_RATE)
|
||||
transfer_rate = clamp(rate, 0, MAX_TRANSFER_RATE)
|
||||
investigate_log("was set to [transfer_rate] L/s by [key_name(usr)]", INVESTIGATE_ATMOS)
|
||||
if("filter")
|
||||
filter_type = null
|
||||
|
||||
@@ -164,7 +164,7 @@
|
||||
pressure = text2num(pressure)
|
||||
. = TRUE
|
||||
if(.)
|
||||
target_pressure = CLAMP(pressure, 0, MAX_OUTPUT_PRESSURE)
|
||||
target_pressure = clamp(pressure, 0, MAX_OUTPUT_PRESSURE)
|
||||
investigate_log("was set to [target_pressure] kPa by [key_name(usr)]", INVESTIGATE_ATMOS)
|
||||
if("node1")
|
||||
var/value = text2num(params["concentration"])
|
||||
|
||||
@@ -123,7 +123,7 @@
|
||||
if("set_volume_rate" in signal.data)
|
||||
var/number = text2num(signal.data["set_volume_rate"])
|
||||
var/datum/gas_mixture/air_contents = airs[1]
|
||||
volume_rate = CLAMP(number, 0, air_contents.volume)
|
||||
volume_rate = clamp(number, 0, air_contents.volume)
|
||||
|
||||
if("status" in signal.data)
|
||||
spawn(2)
|
||||
@@ -172,7 +172,7 @@
|
||||
rate = text2num(rate)
|
||||
. = TRUE
|
||||
if(.)
|
||||
volume_rate = CLAMP(rate, 0, MAX_TRANSFER_RATE)
|
||||
volume_rate = clamp(rate, 0, MAX_TRANSFER_RATE)
|
||||
investigate_log("was set to [volume_rate] L/s by [key_name(usr)]", INVESTIGATE_ATMOS)
|
||||
update_icon()
|
||||
broadcast_status()
|
||||
|
||||
@@ -92,7 +92,7 @@
|
||||
pressure = text2num(pressure)
|
||||
. = TRUE
|
||||
if(.)
|
||||
open_pressure = CLAMP(pressure, close_pressure, 50*ONE_ATMOSPHERE)
|
||||
open_pressure = clamp(pressure, close_pressure, 50*ONE_ATMOSPHERE)
|
||||
investigate_log("open pressure was set to [open_pressure] kPa by [key_name(usr)]", INVESTIGATE_ATMOS)
|
||||
if("close_pressure")
|
||||
var/pressure = params["close_pressure"]
|
||||
@@ -107,6 +107,6 @@
|
||||
pressure = text2num(pressure)
|
||||
. = TRUE
|
||||
if(.)
|
||||
close_pressure = CLAMP(pressure, 0, open_pressure)
|
||||
close_pressure = clamp(pressure, 0, open_pressure)
|
||||
investigate_log("close pressure was set to [close_pressure] kPa by [key_name(usr)]", INVESTIGATE_ATMOS)
|
||||
update_icon()
|
||||
|
||||
@@ -170,7 +170,7 @@
|
||||
target = text2num(target)
|
||||
. = TRUE
|
||||
if(.)
|
||||
target_temperature = CLAMP(target, min_temperature, max_temperature)
|
||||
target_temperature = clamp(target, min_temperature, max_temperature)
|
||||
investigate_log("was set to [target_temperature] K by [key_name(usr)]", INVESTIGATE_ATMOS)
|
||||
|
||||
update_icon()
|
||||
@@ -225,6 +225,7 @@
|
||||
if(!istype(user) || !user.canUseTopic(src, BE_CLOSE))
|
||||
return
|
||||
target_temperature = min_temperature
|
||||
to_chat(user,"<span class='notice'>You minimize the temperature on the [src].</span>")
|
||||
investigate_log("was set to [target_temperature] K by [key_name(usr)]", INVESTIGATE_ATMOS)
|
||||
message_admins("[src.name] was minimized by [ADMIN_LOOKUPFLW(usr)] at [ADMIN_COORDJMP(T)], [A]")
|
||||
return TRUE
|
||||
@@ -257,6 +258,7 @@
|
||||
if(!istype(user) || !user.canUseTopic(src, BE_CLOSE))
|
||||
return
|
||||
target_temperature = max_temperature
|
||||
to_chat(user,"<span class='notice'>You maximize the temperature on the [src].</span>")
|
||||
investigate_log("was set to [target_temperature] K by [key_name(usr)]", INVESTIGATE_ATMOS)
|
||||
message_admins("[src.name] was maximized by [ADMIN_LOOKUPFLW(usr)] at [ADMIN_COORDJMP(T)], [A]")
|
||||
return TRUE
|
||||
|
||||
@@ -210,13 +210,13 @@
|
||||
|
||||
if("set_internal_pressure" in signal.data)
|
||||
var/old_pressure = internal_pressure_bound
|
||||
internal_pressure_bound = CLAMP(text2num(signal.data["set_internal_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
internal_pressure_bound = clamp(text2num(signal.data["set_internal_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
if(old_pressure != internal_pressure_bound)
|
||||
investigate_log(" internal pressure was set to [internal_pressure_bound] by [key_name(signal_sender)]",INVESTIGATE_ATMOS)
|
||||
|
||||
if("set_external_pressure" in signal.data)
|
||||
var/old_pressure = external_pressure_bound
|
||||
external_pressure_bound = CLAMP(text2num(signal.data["set_external_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
external_pressure_bound = clamp(text2num(signal.data["set_external_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
if(old_pressure != external_pressure_bound)
|
||||
investigate_log(" external pressure was set to [external_pressure_bound] by [key_name(signal_sender)]",INVESTIGATE_ATMOS)
|
||||
|
||||
@@ -227,10 +227,10 @@
|
||||
internal_pressure_bound = 0
|
||||
|
||||
if("adjust_internal_pressure" in signal.data)
|
||||
internal_pressure_bound = CLAMP(internal_pressure_bound + text2num(signal.data["adjust_internal_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
internal_pressure_bound = clamp(internal_pressure_bound + text2num(signal.data["adjust_internal_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
|
||||
if("adjust_external_pressure" in signal.data)
|
||||
external_pressure_bound = CLAMP(external_pressure_bound + text2num(signal.data["adjust_external_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
external_pressure_bound = clamp(external_pressure_bound + text2num(signal.data["adjust_external_pressure"]),0,ONE_ATMOSPHERE*50)
|
||||
|
||||
if("init" in signal.data)
|
||||
name = signal.data["init"]
|
||||
|
||||
@@ -128,7 +128,7 @@
|
||||
if(initialize_directions & dir)
|
||||
return ..()
|
||||
if((NORTH|EAST) & dir)
|
||||
user.ventcrawl_layer = CLAMP(user.ventcrawl_layer + 1, PIPING_LAYER_MIN, PIPING_LAYER_MAX)
|
||||
user.ventcrawl_layer = clamp(user.ventcrawl_layer + 1, PIPING_LAYER_MIN, PIPING_LAYER_MAX)
|
||||
if((SOUTH|WEST) & dir)
|
||||
user.ventcrawl_layer = CLAMP(user.ventcrawl_layer - 1, PIPING_LAYER_MIN, PIPING_LAYER_MAX)
|
||||
user.ventcrawl_layer = clamp(user.ventcrawl_layer - 1, PIPING_LAYER_MIN, PIPING_LAYER_MAX)
|
||||
to_chat(user, "You align yourself with the [user.ventcrawl_layer]\th output.")
|
||||
|
||||
@@ -390,7 +390,7 @@
|
||||
pressure = text2num(pressure)
|
||||
. = TRUE
|
||||
if(.)
|
||||
release_pressure = CLAMP(round(pressure), can_min_release_pressure, can_max_release_pressure)
|
||||
release_pressure = clamp(round(pressure), can_min_release_pressure, can_max_release_pressure)
|
||||
investigate_log("was set to [release_pressure] kPa by [key_name(usr)].", INVESTIGATE_ATMOS)
|
||||
if("valve")
|
||||
var/logmsg
|
||||
@@ -434,7 +434,7 @@
|
||||
var/N = text2num(user_input)
|
||||
if(!N)
|
||||
return
|
||||
timer_set = CLAMP(N,minimum_timer_set,maximum_timer_set)
|
||||
timer_set = clamp(N,minimum_timer_set,maximum_timer_set)
|
||||
log_admin("[key_name(usr)] has activated a prototype valve timer")
|
||||
. = TRUE
|
||||
if("toggle_timer")
|
||||
|
||||
@@ -150,7 +150,7 @@
|
||||
pressure = text2num(pressure)
|
||||
. = TRUE
|
||||
if(.)
|
||||
pump.target_pressure = CLAMP(round(pressure), PUMP_MIN_PRESSURE, PUMP_MAX_PRESSURE)
|
||||
pump.target_pressure = clamp(round(pressure), PUMP_MIN_PRESSURE, PUMP_MAX_PRESSURE)
|
||||
investigate_log("was set to [pump.target_pressure] kPa by [key_name(usr)].", INVESTIGATE_ATMOS)
|
||||
if("eject")
|
||||
if(holding)
|
||||
|
||||
@@ -487,8 +487,7 @@
|
||||
suit = /obj/item/clothing/suit/space/hardsuit/shielded/ctf
|
||||
toggle_helmet = FALSE // see the whites of their eyes
|
||||
shoes = /obj/item/clothing/shoes/combat
|
||||
gloves = /obj/item/clothing/gloves/combat
|
||||
id = /obj/item/card/id/syndicate
|
||||
gloves = /obj/item/clothing/gloves/tackler/combat
|
||||
belt = /obj/item/gun/ballistic/automatic/pistol/deagle/ctf
|
||||
l_pocket = /obj/item/ammo_box/magazine/recharge/ctf
|
||||
r_pocket = /obj/item/ammo_box/magazine/recharge/ctf
|
||||
|
||||
@@ -490,7 +490,7 @@
|
||||
glasses = /obj/item/clothing/glasses/eyepatch
|
||||
mask = /obj/item/clothing/mask/cigarette/cigar/cohiba
|
||||
head = /obj/item/clothing/head/centhat
|
||||
gloves = /obj/item/clothing/gloves/combat
|
||||
gloves = /obj/item/clothing/gloves/tackler/combat
|
||||
shoes = /obj/item/clothing/shoes/combat/swat
|
||||
r_pocket = /obj/item/lighter
|
||||
id = /obj/item/card/id
|
||||
@@ -507,7 +507,7 @@
|
||||
uniform = /obj/item/clothing/under/rank/security/officer
|
||||
suit = /obj/item/clothing/suit/armor/vest
|
||||
shoes = /obj/item/clothing/shoes/combat
|
||||
gloves = /obj/item/clothing/gloves/combat
|
||||
gloves = /obj/item/clothing/gloves/tackler/combat
|
||||
mask = /obj/item/clothing/mask/gas/sechailer/swat
|
||||
head = /obj/item/clothing/head/helmet/swat/nanotrasen
|
||||
back = /obj/item/storage/backpack/security
|
||||
|
||||
@@ -1,15 +1,19 @@
|
||||
// How much "space" we give the edge of the map
|
||||
GLOBAL_LIST_INIT(potentialRandomZlevels, generateMapList(filename = "[global.config.directory]/awaymissionconfig.txt"))
|
||||
|
||||
/proc/createRandomZlevel()
|
||||
if(GLOB.awaydestinations.len) //crude, but it saves another var!
|
||||
/proc/createRandomZlevel(name = AWAY_MISSION_NAME, list/traits = list(ZTRAIT_AWAY = TRUE), list/potential_levels = GLOB.potential_away_levels)
|
||||
if(GLOB.random_zlevels_generated[name])
|
||||
stack_trace("[name] level already generated.")
|
||||
return
|
||||
if(!length(potential_levels))
|
||||
stack_trace("No potential [name] level to load has been found.")
|
||||
return
|
||||
|
||||
if(GLOB.potentialRandomZlevels && GLOB.potentialRandomZlevels.len)
|
||||
to_chat(world, "<span class='boldannounce'>Loading away mission...</span>")
|
||||
var/map = pick(GLOB.potentialRandomZlevels)
|
||||
load_new_z_level(map, "Away Mission")
|
||||
to_chat(world, "<span class='boldannounce'>Away mission loaded.</span>")
|
||||
var/start_time = REALTIMEOFDAY
|
||||
var/map = pick(potential_levels)
|
||||
if(!load_new_z_level(map, name, traits))
|
||||
INIT_ANNOUNCE("Failed to load [name]! map filepath: [map]!")
|
||||
return
|
||||
INIT_ANNOUNCE("Loaded [name] in [(REALTIMEOFDAY - start_time)/10]s!")
|
||||
GLOB.random_zlevels_generated[name] = TRUE
|
||||
|
||||
/proc/reset_gateway_spawns(reset = FALSE)
|
||||
for(var/obj/machinery/gateway/G in world)
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
var/matrix/mat = matrix()
|
||||
mat.Translate(0, 16)
|
||||
mat.Scale(1, sqrt((x_offset * x_offset) + (y_offset * y_offset)) / 32)
|
||||
mat.Turn(90 - ATAN2(x_offset, y_offset)) // So... You pass coords in order x,y to this version of atan2. It should be called acsc2.
|
||||
mat.Turn(90 - arctan(x_offset, y_offset)) // So... You pass coords in order x,y to this version of atan2. It should be called acsc2.
|
||||
mat.Translate(atom_a.pixel_x, atom_a.pixel_y)
|
||||
|
||||
transform = mat
|
||||
|
||||
@@ -23,6 +23,6 @@
|
||||
DuplicateObject(stored, perfectcopy=1, sameloc=0,newloc=T)
|
||||
log_admin("Build Mode: [key_name(c)] copied [stored] to [AREACOORD(object)]")
|
||||
else if(right_click)
|
||||
if(ismovableatom(object)) // No copying turfs for now.
|
||||
if(ismovable(object)) // No copying turfs for now.
|
||||
to_chat(c, "<span class='notice'>[object] set as template.</span>")
|
||||
stored = object
|
||||
|
||||
@@ -309,7 +309,7 @@
|
||||
/datum/export/gear/combatgloves
|
||||
cost = 80
|
||||
unit_name = "combat gloves"
|
||||
export_types = list(/obj/item/clothing/gloves/combat, /obj/item/clothing/gloves/fingerless/pugilist/rapid, /obj/item/clothing/gloves/krav_maga)
|
||||
export_types = list(/obj/item/clothing/gloves/tackler/combat, /obj/item/clothing/gloves/tackler/dolphin, /obj/item/clothing/gloves/fingerless/pugilist/rapid, /obj/item/clothing/gloves/krav_maga)
|
||||
include_subtypes = TRUE
|
||||
|
||||
/datum/export/gear/bonegloves
|
||||
@@ -797,4 +797,4 @@ datum/export/gear/glasses //glasses are not worth selling
|
||||
export_types = list(/obj/item/clothing/head/chameleon, /obj/item/clothing/mask/chameleon, /obj/item/clothing/under/chameleon, /obj/item/clothing/suit/chameleon, /obj/item/clothing/glasses/chameleon,\
|
||||
/obj/item/clothing/gloves/chameleon, /obj/item/clothing/head/chameleon, /obj/item/clothing/shoes/chameleon, /obj/item/storage/backpack/chameleon, \
|
||||
/obj/item/storage/belt/chameleon, /obj/item/radio/headset/chameleon, /obj/item/pda/chameleon, /obj/item/stamp/chameleon, /obj/item/clothing/neck/cloak/chameleon)
|
||||
include_subtypes = TRUE
|
||||
include_subtypes = TRUE
|
||||
|
||||
@@ -175,7 +175,7 @@
|
||||
/obj/item/clothing/suit/armor/vest/russian,
|
||||
/obj/item/clothing/head/helmet/rus_helmet,
|
||||
/obj/item/clothing/shoes/russian,
|
||||
/obj/item/clothing/gloves/combat,
|
||||
/obj/item/clothing/gloves/tackler/combat/insulated,
|
||||
/obj/item/clothing/under/syndicate/rus_army,
|
||||
/obj/item/clothing/under/costume/soviet,
|
||||
/obj/item/clothing/mask/russian_balaclava,
|
||||
@@ -201,8 +201,8 @@
|
||||
/obj/item/clothing/mask/gas/sechailer/swat,
|
||||
/obj/item/storage/belt/military/assault,
|
||||
/obj/item/storage/belt/military/assault,
|
||||
/obj/item/clothing/gloves/combat,
|
||||
/obj/item/clothing/gloves/combat)
|
||||
/obj/item/clothing/gloves/tackler/combat/insulated,
|
||||
/obj/item/clothing/gloves/tackler/combat/insulated)
|
||||
crate_name = "swat crate"
|
||||
|
||||
/datum/supply_pack/security/armory/wt550
|
||||
|
||||
@@ -205,7 +205,7 @@
|
||||
desc = "Need some meat? With this do-it-yourself kit you'll be swimming in it! Contains a monkey cube, an IV drip, and some cryoxadone!"
|
||||
cost = 2150
|
||||
contraband = TRUE
|
||||
contains = list(/obj/item/reagent_containers/food/snacks/monkeycube,
|
||||
contains = list(/obj/item/reagent_containers/food/snacks/cube/monkey,
|
||||
/obj/item/restraints/handcuffs/cable,
|
||||
/obj/machinery/iv_drip,
|
||||
/obj/item/reagent_containers/glass/beaker/cryoxadone,
|
||||
|
||||
@@ -91,8 +91,8 @@
|
||||
/obj/item/clothing/suit/armor/bulletproof,
|
||||
/obj/item/clothing/head/helmet/alt,
|
||||
/obj/item/clothing/head/helmet/alt,
|
||||
/obj/item/clothing/gloves/combat,
|
||||
/obj/item/clothing/gloves/combat,
|
||||
/obj/item/clothing/gloves/tackler/combat/insulated,
|
||||
/obj/item/clothing/gloves/tackler/combat/insulated,
|
||||
/obj/item/clothing/mask/gas,
|
||||
/obj/item/clothing/mask/gas)
|
||||
crate_name = "surplus russian clothing"
|
||||
@@ -109,7 +109,7 @@
|
||||
/obj/item/clothing/head/ushanka,
|
||||
/obj/item/clothing/suit/armor/bulletproof,
|
||||
/obj/item/clothing/head/helmet/alt,
|
||||
/obj/item/clothing/gloves/combat,
|
||||
/obj/item/clothing/gloves/tackler/combat/insulated,
|
||||
/obj/item/clothing/mask/gas,
|
||||
/obj/item/gun/ballistic/shotgun/boltaction,
|
||||
/obj/item/ammo_box/a762)
|
||||
|
||||
@@ -888,8 +888,8 @@ GLOBAL_LIST_EMPTY(external_rsc_urls)
|
||||
var/viewscale = getviewsize(view)
|
||||
var/x = viewscale[1]
|
||||
var/y = viewscale[2]
|
||||
x = CLAMP(x+change, min, max)
|
||||
y = CLAMP(y+change, min,max)
|
||||
x = clamp(x+change, min, max)
|
||||
y = clamp(y+change, min,max)
|
||||
change_view("[x]x[y]")
|
||||
|
||||
/client/proc/change_view(new_size)
|
||||
|
||||
@@ -208,6 +208,8 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
|
||||
var/show_mismatched_markings = FALSE //determines whether or not the markings lists should show markings that don't match the currently selected species. Intentionally left unsaved.
|
||||
|
||||
var/no_tetris_storage = FALSE
|
||||
|
||||
/datum/preferences/New(client/C)
|
||||
parent = C
|
||||
|
||||
@@ -863,6 +865,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
dat += "<b>Widescreen:</b> <a href='?_src_=prefs;preference=widescreenpref'>[widescreenpref ? "Enabled ([CONFIG_GET(string/default_view)])" : "Disabled (15x15)"]</a><br>"
|
||||
dat += "<b>Auto stand:</b> <a href='?_src_=prefs;preference=autostand'>[autostand ? "Enabled" : "Disabled"]</a><br>"
|
||||
dat += "<b>Auto OOC:</b> <a href='?_src_=prefs;preference=auto_ooc'>[auto_ooc ? "Enabled" : "Disabled"]</a><br>"
|
||||
dat += "<b>Force Slot Storage HUD:</b> <a href='?_src_=prefs;preference=no_tetris_storage'>[no_tetris_storage ? "Enabled" : "Disabled"]</a><br>"
|
||||
dat += "<b>Screen Shake:</b> <a href='?_src_=prefs;preference=screenshake'>[(screenshake==100) ? "Full" : ((screenshake==0) ? "None" : "[screenshake]")]</a><br>"
|
||||
if (user && user.client && !user.client.prefs.screenshake==0)
|
||||
dat += "<b>Damage Screen Shake:</b> <a href='?_src_=prefs;preference=damagescreenshake'>[(damagescreenshake==1) ? "On" : ((damagescreenshake==0) ? "Off" : "Only when down")]</a><br>"
|
||||
@@ -1834,7 +1837,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
|
||||
if("s_tone")
|
||||
var/list/choices = GLOB.skin_tones - GLOB.nonstandard_skin_tones
|
||||
if(CONFIG_GET(number/allow_custom_skintones))
|
||||
if(CONFIG_GET(flag/allow_custom_skintones))
|
||||
choices += "custom"
|
||||
var/new_s_tone = input(user, "Choose your character's skin tone:", "Character Preference") as null|anything in choices
|
||||
if(new_s_tone)
|
||||
@@ -1963,7 +1966,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
var/max_D = CONFIG_GET(number/penis_max_inches_prefs)
|
||||
var/new_length = input(user, "Penis length in inches:\n([min_D]-[max_D])", "Character Preference") as num|null
|
||||
if(new_length)
|
||||
features["cock_length"] = CLAMP(round(new_length), min_D, max_D)
|
||||
features["cock_length"] = clamp(round(new_length), min_D, max_D)
|
||||
|
||||
if("cock_shape")
|
||||
var/new_shape
|
||||
@@ -2160,7 +2163,7 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
var/danger = CONFIG_GET(number/threshold_body_size_slowdown)
|
||||
var/new_body_size = input(user, "Choose your desired sprite size:\n([min*100]%-[max*100]%), Warning: May make your character look distorted[danger > min ? ", and an exponential slowdown will occur for those smaller than [danger*100]%!" : "!"]", "Character Preference", features["body_size"]*100) as num|null
|
||||
if (new_body_size)
|
||||
new_body_size = CLAMP(new_body_size * 0.01, min, max)
|
||||
new_body_size = clamp(new_body_size * 0.01, min, max)
|
||||
var/dorfy
|
||||
if(danger > new_body_size)
|
||||
dorfy = alert(user, "The chosen size appears to be smaller than the threshold of [danger*100]%, which will lead to an added exponential slowdown. Are you sure about that?", "Dwarfism Alert", "Yes", "Move it to the threshold", "No")
|
||||
@@ -2201,6 +2204,8 @@ GLOBAL_LIST_EMPTY(preferences_datums)
|
||||
autostand = !autostand
|
||||
if("auto_ooc")
|
||||
auto_ooc = !auto_ooc
|
||||
if("no_tetris_storage")
|
||||
no_tetris_storage = !no_tetris_storage
|
||||
if ("screenshake")
|
||||
var/desiredshake = input(user, "Set the amount of screenshake you want. \n(0 = disabled, 100 = full, 200 = maximum.)", "Character Preference", screenshake) as null|num
|
||||
if (!isnull(desiredshake))
|
||||
|
||||
@@ -253,7 +253,8 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
S["autostand"] >> autostand
|
||||
S["cit_toggles"] >> cit_toggles
|
||||
S["preferred_chaos"] >> preferred_chaos
|
||||
S["auto_ooc"] >> auto_ooc
|
||||
S["auto_ooc"] >> auto_ooc
|
||||
S["no_tetris_storage"] >> no_tetris_storage
|
||||
|
||||
|
||||
//try to fix any outdated data if necessary
|
||||
@@ -290,10 +291,11 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
pda_skin = sanitize_inlist(pda_skin, GLOB.pda_reskins, PDA_SKIN_ALT)
|
||||
screenshake = sanitize_integer(screenshake, 0, 800, initial(screenshake))
|
||||
damagescreenshake = sanitize_integer(damagescreenshake, 0, 2, initial(damagescreenshake))
|
||||
widescreenpref = sanitize_integer(widescreenpref, 0, 1, initial(widescreenpref))
|
||||
widescreenpref = sanitize_integer(widescreenpref, 0, 1, initial(widescreenpref))
|
||||
autostand = sanitize_integer(autostand, 0, 1, initial(autostand))
|
||||
cit_toggles = sanitize_integer(cit_toggles, 0, 65535, initial(cit_toggles))
|
||||
auto_ooc = sanitize_integer(auto_ooc, 0, 1, initial(auto_ooc))
|
||||
no_tetris_storage = sanitize_integer(no_tetris_storage, 0, 1, initial(no_tetris_storage))
|
||||
|
||||
return 1
|
||||
|
||||
@@ -358,6 +360,7 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
WRITE_FILE(S["cit_toggles"], cit_toggles)
|
||||
WRITE_FILE(S["preferred_chaos"], preferred_chaos)
|
||||
WRITE_FILE(S["auto_ooc"], auto_ooc)
|
||||
WRITE_FILE(S["no_tetris_storage"], no_tetris_storage)
|
||||
|
||||
return 1
|
||||
|
||||
@@ -568,11 +571,16 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
hair_color = sanitize_hexcolor(hair_color, 3, 0)
|
||||
facial_hair_color = sanitize_hexcolor(facial_hair_color, 3, 0)
|
||||
eye_color = sanitize_hexcolor(eye_color, 3, 0)
|
||||
use_custom_skin_tone = sanitize_integer(use_custom_skin_tone, FALSE, TRUE, initial(use_custom_skin_tone))
|
||||
if(use_custom_skin_tone && CONFIG_GET(number/allow_custom_skintones))
|
||||
|
||||
var/static/allow_custom_skintones
|
||||
if(isnull(allow_custom_skintones))
|
||||
allow_custom_skintones = CONFIG_GET(flag/allow_custom_skintones)
|
||||
use_custom_skin_tone = allow_custom_skintones ? sanitize_integer(use_custom_skin_tone, FALSE, TRUE, initial(use_custom_skin_tone)) : FALSE
|
||||
if(use_custom_skin_tone)
|
||||
skin_tone = sanitize_hexcolor(skin_tone, 6, TRUE, "#FFFFFF")
|
||||
else
|
||||
skin_tone = sanitize_inlist(skin_tone, GLOB.skin_tones - GLOB.nonstandard_skin_tones, initial(skin_tone))
|
||||
|
||||
horn_color = sanitize_hexcolor(horn_color, 3, FALSE)
|
||||
wing_color = sanitize_hexcolor(wing_color, 3, FALSE, "#FFFFFF")
|
||||
backbag = sanitize_inlist(backbag, GLOB.backbaglist, initial(backbag))
|
||||
@@ -599,7 +607,7 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
|
||||
var/static/size_max
|
||||
if(!size_max)
|
||||
size_max = CONFIG_GET(number/body_size_max)
|
||||
features["body_size"] = sanitize_integer(features["body_size"], size_min, size_max, RESIZE_DEFAULT_SIZE)
|
||||
features["body_size"] = sanitize_num_clamp(features["body_size"], size_min, size_max, RESIZE_DEFAULT_SIZE, 0.01)
|
||||
|
||||
var/static/list/B_sizes
|
||||
if(!B_sizes)
|
||||
|
||||
@@ -262,7 +262,15 @@
|
||||
return
|
||||
random_look(owner)
|
||||
|
||||
/obj/item/clothing/under/chameleon
|
||||
// Forgive me for my sins...
|
||||
#define CHAMELEON_CLOTHING_DEFINE(path) \
|
||||
##path/syndicate/Initialize(mapload){\
|
||||
. = ..();\
|
||||
AddComponent(/datum/component/identification/syndicate, ID_COMPONENT_DEL_ON_IDENTIFY, ID_COMPONENT_EFFECT_NO_ACTIONS, ID_COMPONENT_IDENTIFY_WITH_DECONSTRUCTOR);\
|
||||
}\
|
||||
##path
|
||||
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/clothing/under/chameleon)
|
||||
//starts off as black
|
||||
name = "black jumpsuit"
|
||||
icon_state = "black"
|
||||
@@ -300,7 +308,7 @@
|
||||
. = ..()
|
||||
chameleon_action.emp_randomise(INFINITY)
|
||||
|
||||
/obj/item/clothing/suit/chameleon
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/clothing/suit/chameleon)
|
||||
name = "armor"
|
||||
desc = "A slim armored vest that protects against most types of damage."
|
||||
icon_state = "armor"
|
||||
@@ -329,7 +337,7 @@
|
||||
. = ..()
|
||||
chameleon_action.emp_randomise(INFINITY)
|
||||
|
||||
/obj/item/clothing/glasses/chameleon
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/clothing/glasses/chameleon)
|
||||
name = "Optical Meson Scanner"
|
||||
desc = "Used by engineering and mining staff to see basic structural and terrain layouts through walls, regardless of lighting condition."
|
||||
icon_state = "meson"
|
||||
@@ -357,7 +365,7 @@
|
||||
. = ..()
|
||||
chameleon_action.emp_randomise(INFINITY)
|
||||
|
||||
/obj/item/clothing/gloves/chameleon
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/clothing/gloves/chameleon)
|
||||
desc = "These gloves will protect the wearer from electric shock."
|
||||
name = "insulated gloves"
|
||||
icon_state = "yellow"
|
||||
@@ -368,6 +376,9 @@
|
||||
|
||||
var/datum/action/item_action/chameleon/change/chameleon_action
|
||||
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/clothing/gloves/chameleon/insulated)
|
||||
siemens_coefficient = 0
|
||||
|
||||
/obj/item/clothing/gloves/chameleon/Initialize()
|
||||
. = ..()
|
||||
chameleon_action = new(src)
|
||||
@@ -386,7 +397,7 @@
|
||||
. = ..()
|
||||
chameleon_action.emp_randomise(INFINITY)
|
||||
|
||||
/obj/item/clothing/head/chameleon
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/clothing/head/chameleon)
|
||||
name = "grey cap"
|
||||
desc = "It's a baseball hat in a tasteful grey colour."
|
||||
icon_state = "greysoft"
|
||||
@@ -429,7 +440,7 @@
|
||||
var/datum/action/item_action/chameleon/drone/randomise/randomise_action = new(src)
|
||||
randomise_action.UpdateButtonIcon()
|
||||
|
||||
/obj/item/clothing/mask/chameleon
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/clothing/mask/chameleon)
|
||||
name = "gas mask"
|
||||
desc = "A face-covering mask that can be connected to an air supply. While good for concealing your identity, it isn't good for blocking gas flow." //More accurate
|
||||
icon_state = "gas_alt"
|
||||
@@ -486,7 +497,7 @@
|
||||
/obj/item/clothing/mask/chameleon/drone/attack_self(mob/user)
|
||||
to_chat(user, "<span class='notice'>[src] does not have a voice changer.</span>")
|
||||
|
||||
/obj/item/clothing/shoes/chameleon
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/clothing/shoes/chameleon)
|
||||
name = "black shoes"
|
||||
icon_state = "black"
|
||||
desc = "A pair of black shoes."
|
||||
@@ -511,7 +522,7 @@
|
||||
return
|
||||
chameleon_action.emp_randomise()
|
||||
|
||||
/obj/item/clothing/shoes/chameleon/noslip
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/clothing/shoes/chameleon/noslip)
|
||||
name = "black shoes"
|
||||
icon_state = "black"
|
||||
desc = "A pair of black shoes."
|
||||
@@ -521,7 +532,7 @@
|
||||
. = ..()
|
||||
chameleon_action.emp_randomise(INFINITY)
|
||||
|
||||
/obj/item/storage/backpack/chameleon
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/storage/backpack/chameleon)
|
||||
name = "backpack"
|
||||
var/datum/action/item_action/chameleon/change/chameleon_action
|
||||
|
||||
@@ -542,7 +553,7 @@
|
||||
. = ..()
|
||||
chameleon_action.emp_randomise(INFINITY)
|
||||
|
||||
/obj/item/storage/belt/chameleon
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/storage/belt/chameleon)
|
||||
name = "toolbelt"
|
||||
desc = "Holds tools."
|
||||
var/datum/action/item_action/chameleon/change/chameleon_action
|
||||
@@ -570,7 +581,7 @@
|
||||
. = ..()
|
||||
chameleon_action.emp_randomise(INFINITY)
|
||||
|
||||
/obj/item/radio/headset/chameleon
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/radio/headset/chameleon)
|
||||
name = "radio headset"
|
||||
var/datum/action/item_action/chameleon/change/chameleon_action
|
||||
|
||||
@@ -591,7 +602,7 @@
|
||||
. = ..()
|
||||
chameleon_action.emp_randomise(INFINITY)
|
||||
|
||||
/obj/item/pda/chameleon
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/pda/chameleon)
|
||||
name = "PDA"
|
||||
var/datum/action/item_action/chameleon/change/pda/chameleon_action
|
||||
|
||||
@@ -613,7 +624,7 @@
|
||||
. = ..()
|
||||
chameleon_action.emp_randomise(INFINITY)
|
||||
|
||||
/obj/item/stamp/chameleon
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/stamp/chameleon)
|
||||
var/datum/action/item_action/chameleon/change/chameleon_action
|
||||
|
||||
/obj/item/stamp/chameleon/Initialize()
|
||||
@@ -627,7 +638,7 @@
|
||||
. = ..()
|
||||
chameleon_action.emp_randomise(INFINITY)
|
||||
|
||||
/obj/item/clothing/neck/cloak/chameleon
|
||||
CHAMELEON_CLOTHING_DEFINE(/obj/item/clothing/neck/cloak/chameleon)
|
||||
name = "black tie"
|
||||
desc = "A neosilk clip-on tie."
|
||||
icon = 'icons/obj/clothing/neck.dmi'
|
||||
|
||||
@@ -0,0 +1,97 @@
|
||||
/obj/item/clothing/gloves/tackler
|
||||
name = "gripper gloves"
|
||||
desc = "Special gloves that manipulate the blood vessels in the wearer's hands, granting them the ability to launch headfirst into walls."
|
||||
icon_state = "tackle"
|
||||
item_state = "tackle"
|
||||
transfer_prints = TRUE
|
||||
cold_protection = HANDS
|
||||
min_cold_protection_temperature = GLOVES_MIN_TEMP_PROTECT
|
||||
resistance_flags = NONE
|
||||
//custom_premium_price = 350
|
||||
/// For storing our tackler datum so we can remove it after
|
||||
var/datum/component/tackler
|
||||
/// See: [/datum/component/tackler/var/stamina_cost]
|
||||
var/tackle_stam_cost = 25
|
||||
/// See: [/datum/component/tackler/var/base_knockdown]
|
||||
var/base_knockdown = 1 SECONDS
|
||||
/// See: [/datum/component/tackler/var/range]
|
||||
var/tackle_range = 4
|
||||
/// See: [/datum/component/tackler/var/min_distance]
|
||||
var/min_distance = 0
|
||||
/// See: [/datum/component/tackler/var/speed]
|
||||
var/tackle_speed = 1
|
||||
/// See: [/datum/component/tackler/var/skill_mod]
|
||||
var/skill_mod = 1
|
||||
|
||||
/obj/item/clothing/gloves/tackler/equipped(mob/user, slot)
|
||||
. = ..()
|
||||
if(!ishuman(user))
|
||||
return
|
||||
if(slot == ITEM_SLOT_GLOVES)
|
||||
var/mob/living/carbon/human/H = user
|
||||
tackler = H.AddComponent(/datum/component/tackler, stamina_cost=tackle_stam_cost, base_knockdown = base_knockdown, range = tackle_range, speed = tackle_speed, skill_mod = skill_mod, min_distance = min_distance)
|
||||
|
||||
/obj/item/clothing/gloves/tackler/dropped(mob/user)
|
||||
. = ..()
|
||||
if(tackler)
|
||||
qdel(tackler)
|
||||
|
||||
/obj/item/clothing/gloves/tackler/dolphin
|
||||
name = "dolphin gloves"
|
||||
desc = "Sleek, aerodynamic gripper gloves that are less effective at actually performing takedowns, but more effective at letting the user sail through the hallways and cause accidents."
|
||||
icon_state = "tackledolphin"
|
||||
item_state = "tackledolphin"
|
||||
|
||||
tackle_stam_cost = 15
|
||||
base_knockdown = 0.5 SECONDS
|
||||
tackle_range = 5
|
||||
tackle_speed = 2
|
||||
min_distance = 2
|
||||
skill_mod = -2
|
||||
|
||||
/obj/item/clothing/gloves/tackler/combat
|
||||
name = "gorilla gloves"
|
||||
desc = "Premium quality combative gloves, heavily reinforced to give the user an edge in close combat tackles, though they are more taxing to use than normal gripper gloves. Fireproof to boot!"
|
||||
icon_state = "combat"
|
||||
item_state = "blackgloves"
|
||||
|
||||
tackle_stam_cost = 35
|
||||
base_knockdown = 1.5 SECONDS
|
||||
tackle_range = 5
|
||||
skill_mod = 3
|
||||
|
||||
cold_protection = HANDS
|
||||
min_cold_protection_temperature = GLOVES_MIN_TEMP_PROTECT
|
||||
heat_protection = HANDS
|
||||
max_heat_protection_temperature = GLOVES_MAX_TEMP_PROTECT
|
||||
resistance_flags = NONE
|
||||
|
||||
/obj/item/clothing/gloves/tackler/combat/insulated
|
||||
name = "guerrilla gloves"
|
||||
desc = "Superior quality combative gloves, good for performing tackle takedowns as well as absorbing electrical shocks."
|
||||
siemens_coefficient = 0
|
||||
permeability_coefficient = 0.05
|
||||
|
||||
/obj/item/clothing/gloves/tackler/rocket
|
||||
name = "rocket gloves"
|
||||
desc = "The ultimate in high risk, high reward, perfect for when you need to stop a criminal from fifty feet away or die trying. Banned in most Spinward gridiron football and rugby leagues."
|
||||
icon_state = "tacklerocket"
|
||||
item_state = "tacklerocket"
|
||||
|
||||
tackle_stam_cost = 50
|
||||
base_knockdown = 2 SECONDS
|
||||
tackle_range = 10
|
||||
min_distance = 7
|
||||
tackle_speed = 6
|
||||
skill_mod = 7
|
||||
|
||||
/obj/item/clothing/gloves/tackler/offbrand
|
||||
name = "improvised gripper gloves"
|
||||
desc = "Ratty looking fingerless gloves wrapped with sticky tape. Beware anyone wearing these, for they clearly have no shame and nothing to lose."
|
||||
icon_state = "fingerless"
|
||||
item_state = "fingerless"
|
||||
|
||||
tackle_stam_cost = 30
|
||||
base_knockdown = 1.75 SECONDS
|
||||
min_distance = 2
|
||||
skill_mod = -1
|
||||
@@ -3,7 +3,7 @@
|
||||
|
||||
uniform = /obj/item/clothing/under/rank/centcom/officer
|
||||
shoes = /obj/item/clothing/shoes/combat/swat
|
||||
gloves = /obj/item/clothing/gloves/combat
|
||||
gloves = /obj/item/clothing/gloves/tackler/combat/insulated
|
||||
ears = /obj/item/radio/headset/headset_cent/alt
|
||||
|
||||
/datum/outfit/ert/post_equip(mob/living/carbon/human/H, visualsOnly = FALSE, client/preference_source)
|
||||
@@ -69,8 +69,8 @@
|
||||
id = /obj/item/card/id/ert/Security
|
||||
suit = /obj/item/clothing/suit/space/hardsuit/ert/sec
|
||||
glasses = /obj/item/clothing/glasses/hud/security/sunglasses
|
||||
back = /obj/item/storage/backpack/security
|
||||
belt = /obj/item/storage/belt/security/full
|
||||
back = /obj/item/storage/backpack/security
|
||||
backpack_contents = list(/obj/item/storage/box/engineer=1,\
|
||||
/obj/item/storage/box/handcuffs=1,\
|
||||
/obj/item/clothing/mask/gas/sechailer=1,\
|
||||
|
||||
@@ -205,7 +205,7 @@
|
||||
uniform = /obj/item/clothing/under/rank/centcom/commander
|
||||
suit = /obj/item/clothing/suit/armor/bulletproof
|
||||
shoes = /obj/item/clothing/shoes/combat/swat
|
||||
gloves = /obj/item/clothing/gloves/combat
|
||||
gloves = /obj/item/clothing/gloves/tackler/combat/insulated
|
||||
ears = /obj/item/radio/headset/headset_cent/commander
|
||||
glasses = /obj/item/clothing/glasses/eyepatch
|
||||
mask = /obj/item/clothing/mask/cigarette/cigar/cohiba
|
||||
@@ -234,7 +234,7 @@
|
||||
uniform = /obj/item/clothing/under/syndicate
|
||||
suit = /obj/item/clothing/suit/space/officer
|
||||
shoes = /obj/item/clothing/shoes/combat/swat
|
||||
gloves = /obj/item/clothing/gloves/combat
|
||||
gloves = /obj/item/clothing/gloves/tackler/combat/insulated
|
||||
glasses = /obj/item/clothing/glasses/thermal/eyepatch
|
||||
ears = /obj/item/radio/headset/headset_cent/commander
|
||||
mask = /obj/item/clothing/mask/cigarette/cigar/havana
|
||||
@@ -316,7 +316,7 @@
|
||||
uniform = /obj/item/clothing/under/costume/soviet
|
||||
head = /obj/item/clothing/head/pirate/captain
|
||||
shoes = /obj/item/clothing/shoes/combat
|
||||
gloves = /obj/item/clothing/gloves/combat
|
||||
gloves = /obj/item/clothing/gloves/tackler/combat/insulated
|
||||
ears = /obj/item/radio/headset/headset_cent
|
||||
glasses = /obj/item/clothing/glasses/thermal/eyepatch
|
||||
suit = /obj/item/clothing/suit/pirate/captain
|
||||
@@ -372,7 +372,7 @@
|
||||
uniform = /obj/item/clothing/under/color/green
|
||||
suit = /obj/item/clothing/suit/space/hardsuit/deathsquad
|
||||
shoes = /obj/item/clothing/shoes/combat/swat
|
||||
gloves = /obj/item/clothing/gloves/combat
|
||||
gloves = /obj/item/clothing/gloves/tackler/combat/insulated
|
||||
mask = /obj/item/clothing/mask/gas/sechailer/swat
|
||||
glasses = /obj/item/clothing/glasses/hud/toggle/thermal
|
||||
back = /obj/item/storage/backpack/security
|
||||
@@ -431,7 +431,7 @@
|
||||
glasses = /obj/item/clothing/glasses/debug
|
||||
ears = /obj/item/radio/headset/headset_cent/commander
|
||||
mask = /obj/item/clothing/mask/gas/welding/up
|
||||
gloves = /obj/item/clothing/gloves/combat
|
||||
gloves = /obj/item/clothing/gloves/tackler/combat/insulated
|
||||
belt = /obj/item/storage/belt/utility/chief/full
|
||||
l_pocket = /obj/item/gun/magic/wand/resurrection/debug
|
||||
r_pocket = /obj/item/gun/magic/wand/death/debug
|
||||
|
||||
@@ -17,7 +17,7 @@
|
||||
name = "Syndicate VR Operative - Basic"
|
||||
uniform = /obj/item/clothing/under/syndicate
|
||||
shoes = /obj/item/clothing/shoes/combat
|
||||
gloves = /obj/item/clothing/gloves/combat
|
||||
gloves = /obj/item/clothing/gloves/tackler/combat/insulated
|
||||
back = /obj/item/storage/backpack
|
||||
id = /obj/item/card/id/syndicate
|
||||
belt = /obj/item/gun/ballistic/automatic/pistol
|
||||
|
||||
@@ -408,7 +408,6 @@
|
||||
helmettype = /obj/item/clothing/head/helmet/space/hardsuit/syndi/owl
|
||||
mutantrace_variation = STYLE_DIGITIGRADE
|
||||
|
||||
|
||||
//Wizard hardsuit
|
||||
/obj/item/clothing/head/helmet/space/hardsuit/wizard
|
||||
name = "gem-encrusted hardsuit helmet"
|
||||
@@ -473,6 +472,7 @@
|
||||
name = "medical hardsuit"
|
||||
desc = "A special suit that protects against hazardous, low pressure environments. Built with lightweight materials for easier movement."
|
||||
item_state = "medical_hardsuit"
|
||||
slowdown = 0.8
|
||||
allowed = list(/obj/item/flashlight, /obj/item/tank/internals, /obj/item/storage/firstaid, /obj/item/healthanalyzer, /obj/item/stack/medical)
|
||||
armor = list("melee" = 30, "bullet" = 5, "laser" = 10, "energy" = 5, "bomb" = 10, "bio" = 100, "rad" = 60, "fire" = 60, "acid" = 75)
|
||||
helmettype = /obj/item/clothing/head/helmet/space/hardsuit/medical
|
||||
@@ -748,63 +748,20 @@
|
||||
allowed = null
|
||||
armor = list("melee" = 30, "bullet" = 15, "laser" = 30, "energy" = 10, "bomb" = 10, "bio" = 100, "rad" = 50, "fire" = 100, "acid" = 100)
|
||||
resistance_flags = FIRE_PROOF | ACID_PROOF
|
||||
var/current_charges = 3
|
||||
var/max_charges = 3 //How many charges total the shielding has
|
||||
var/current_charges //if null, will default to max_chargs
|
||||
var/recharge_delay = 200 //How long after we've been shot before we can start recharging. 20 seconds here
|
||||
var/recharge_cooldown = 0 //Time since we've last been shot
|
||||
var/recharge_rate = 1 //How quickly the shield recharges once it starts charging
|
||||
var/shield_state = "shield-old"
|
||||
var/shield_on = "shield-old"
|
||||
|
||||
/obj/item/clothing/suit/space/hardsuit/shielded/Initialize()
|
||||
. = ..()
|
||||
if(!allowed)
|
||||
allowed = GLOB.advanced_hardsuit_allowed
|
||||
|
||||
/obj/item/clothing/suit/space/hardsuit/shielded/check_block(mob/living/owner, atom/object, damage, attack_text, attack_type, armour_penetration, mob/attacker, def_zone, final_block_chance, list/block_return)
|
||||
if(current_charges > 0)
|
||||
block_return[BLOCK_RETURN_NORMAL_BLOCK_CHANCE] = 100
|
||||
block_return[BLOCK_RETURN_BLOCK_CAPACITY] = (block_return[BLOCK_RETURN_BLOCK_CAPACITY] || 0) + current_charges
|
||||
return ..()
|
||||
|
||||
/obj/item/clothing/suit/space/hardsuit/shielded/run_block(mob/living/owner, atom/object, damage, attack_text, attack_type, armour_penetration, mob/attacker, def_zone, final_block_chance, list/block_return)
|
||||
recharge_cooldown = world.time + recharge_delay
|
||||
if(current_charges > 0)
|
||||
var/datum/effect_system/spark_spread/s = new
|
||||
s.set_up(2, 1, src)
|
||||
s.start()
|
||||
owner.visible_message("<span class='danger'>[owner]'s shields deflect [attack_text] in a shower of sparks!</span>")
|
||||
current_charges--
|
||||
if(recharge_rate)
|
||||
START_PROCESSING(SSobj, src)
|
||||
if(current_charges <= 0)
|
||||
owner.visible_message("[owner]'s shield overloads!")
|
||||
shield_state = "broken"
|
||||
owner.update_inv_wear_suit()
|
||||
return BLOCK_SUCCESS | BLOCK_PHYSICAL_EXTERNAL
|
||||
return BLOCK_NONE
|
||||
|
||||
/obj/item/clothing/suit/space/hardsuit/shielded/Destroy()
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
return ..()
|
||||
|
||||
/obj/item/clothing/suit/space/hardsuit/shielded/process()
|
||||
if(world.time > recharge_cooldown && current_charges < max_charges)
|
||||
current_charges = CLAMP((current_charges + recharge_rate), 0, max_charges)
|
||||
playsound(loc, 'sound/magic/charge.ogg', 50, 1)
|
||||
if(current_charges == max_charges)
|
||||
playsound(loc, 'sound/machines/ding.ogg', 50, 1)
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
shield_state = "[shield_on]"
|
||||
if(ishuman(loc))
|
||||
var/mob/living/carbon/human/C = loc
|
||||
C.update_inv_wear_suit()
|
||||
|
||||
/obj/item/clothing/suit/space/hardsuit/shielded/worn_overlays(isinhands, icon_file, used_state, style_flags = NONE)
|
||||
/obj/item/clothing/suit/space/hardsuit/shielded/ComponentInitialize()
|
||||
. = ..()
|
||||
if(!isinhands)
|
||||
var/file2use = style_flags & STYLE_ALL_TAURIC ? 'modular_citadel/icons/mob/64x32_effects.dmi' : 'icons/effects/effects.dmi'
|
||||
. += mutable_appearance(file2use, shield_state, MOB_LAYER + 0.01)
|
||||
AddComponent(/datum/component/shielded, current_charges, max_charges, recharge_delay, recharge_rate, ITEM_SLOT_OCLOTHING, shield_state)
|
||||
|
||||
/obj/item/clothing/head/helmet/space/hardsuit/shielded
|
||||
resistance_flags = FIRE_PROOF | ACID_PROOF
|
||||
@@ -833,7 +790,6 @@
|
||||
hardsuit_type = "ert_security"
|
||||
helmettype = /obj/item/clothing/head/helmet/space/hardsuit/shielded/ctf/red
|
||||
shield_state = "shield-red"
|
||||
shield_on = "shield-red"
|
||||
|
||||
/obj/item/clothing/suit/space/hardsuit/shielded/ctf/blue
|
||||
name = "blue shielded hardsuit"
|
||||
@@ -896,7 +852,6 @@
|
||||
item_state = "swat_suit"
|
||||
hardsuit_type = "syndi"
|
||||
max_charges = 4
|
||||
current_charges = 4
|
||||
recharge_delay = 15
|
||||
armor = list("melee" = 80, "bullet" = 80, "laser" = 50, "energy" = 50, "bomb" = 100, "bio" = 100, "rad" = 100, "fire" = 100, "acid" = 100)
|
||||
strip_delay = 130
|
||||
|
||||
@@ -199,10 +199,9 @@
|
||||
icon_state = "battlemage"
|
||||
item_state = "battlemage"
|
||||
recharge_rate = 0
|
||||
max_charges = INFINITY
|
||||
current_charges = 15
|
||||
recharge_cooldown = INFINITY
|
||||
shield_state = "shield-red"
|
||||
shield_on = "shield-red"
|
||||
min_cold_protection_temperature = ARMOR_MIN_TEMP_PROTECT
|
||||
max_heat_protection_temperature = ARMOR_MAX_TEMP_PROTECT
|
||||
helmettype = /obj/item/clothing/head/helmet/space/hardsuit/shielded/wizard
|
||||
@@ -243,6 +242,7 @@
|
||||
if(!istype(W))
|
||||
to_chat(user, "<span class='warning'>The rune can only be used on battlemage armour!</span>")
|
||||
return
|
||||
W.current_charges += 8
|
||||
to_chat(user, "<span class='notice'>You charge \the [W]. It can now absorb [W.current_charges] hits.</span>")
|
||||
var/datum/component/shielded/S = GetComponent(/datum/component/shielded)
|
||||
S.adjust_charges(8)
|
||||
to_chat(user, "<span class='notice'>You charge \the [W]. It can now absorb [S.charges] hits.</span>")
|
||||
qdel(src)
|
||||
|
||||
@@ -26,6 +26,8 @@
|
||||
. += mutable_appearance('icons/effects/item_damage.dmi', "damageduniform")
|
||||
if(blood_DNA)
|
||||
. += mutable_appearance('icons/effects/blood.dmi', "uniformblood", color = blood_DNA_to_color())
|
||||
if(accessory_overlay)
|
||||
. += accessory_overlay
|
||||
|
||||
/obj/item/clothing/under/attackby(obj/item/I, mob/user, params)
|
||||
if((has_sensor == BROKEN_SENSORS) && istype(I, /obj/item/stack/cable_coil))
|
||||
@@ -99,8 +101,7 @@
|
||||
if((flags_inv & HIDEACCESSORY) || (A.flags_inv & HIDEACCESSORY))
|
||||
return TRUE
|
||||
|
||||
var/accessory_color = attached_accessory.icon_state
|
||||
accessory_overlay = mutable_appearance('icons/mob/clothing/accessories.dmi', "[accessory_color]")
|
||||
accessory_overlay = mutable_appearance('icons/mob/clothing/accessories.dmi', "attached_accessory.icon_state")
|
||||
accessory_overlay.alpha = attached_accessory.alpha
|
||||
accessory_overlay.color = attached_accessory.color
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
/obj/item/clothing/under/dress/skirt
|
||||
/obj/item/clothing/under/dress
|
||||
mutantrace_variation = STYLE_DIGITIGRADE|STYLE_NO_ANTHRO_ICON
|
||||
|
||||
/obj/item/clothing/under/dress/skirt
|
||||
@@ -182,7 +182,6 @@
|
||||
icon_state = "bride_white"
|
||||
item_state = "bride_white"
|
||||
can_adjust = FALSE
|
||||
mutantrace_variation = NONE
|
||||
|
||||
/obj/item/clothing/under/dress/wedding/orange
|
||||
name = "orange wedding dress"
|
||||
@@ -213,7 +212,6 @@
|
||||
desc = "A fancy skirt made with polychromic threads."
|
||||
icon_state = "polyskirt"
|
||||
item_state = "rainbow"
|
||||
mutantrace_variation = NONE
|
||||
var/list/poly_colors = list("#FFFFFF", "#F08080", "#808080")
|
||||
|
||||
/obj/item/clothing/under/dress/skirt/polychromic/ComponentInitialize()
|
||||
@@ -226,5 +224,4 @@
|
||||
icon_state = "polypleat"
|
||||
item_state = "rainbow"
|
||||
body_parts_covered = CHEST|GROIN|ARMS
|
||||
mutantrace_variation = NONE
|
||||
poly_colors = list("#8CC6FF", "#808080", "#FF3535")
|
||||
|
||||
@@ -57,8 +57,7 @@
|
||||
icon_state = "tactifool"
|
||||
item_state = "bl_suit"
|
||||
has_sensor = TRUE
|
||||
mutantrace_variation = NONE
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0, fire = 0, acid = 0)
|
||||
armor = list("melee" = 0, "bullet" = 0, "laser" = 0,"energy" = 0, "bomb" = 0, "bio" = 0, "rad" = 0, "fire" = 0, "acid" = 0)
|
||||
|
||||
/obj/item/clothing/under/syndicate/sniper
|
||||
name = "Tactical turtleneck suit"
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
|
||||
if(turfs.len) //Pick a turf to spawn at if we can
|
||||
var/turf/T = pick(turfs)
|
||||
new /datum/spacevine_controller(T) //spawn a controller at turf
|
||||
new /datum/spacevine_controller(T, pick(subtypesof(/datum/spacevine_mutation)), rand(30,100), rand(5,10), src) //spawn a controller at turf with randomized stats and a single random mutation
|
||||
|
||||
|
||||
/datum/spacevine_mutation
|
||||
@@ -227,13 +227,13 @@
|
||||
quality = NEGATIVE
|
||||
|
||||
/datum/spacevine_mutation/thorns/on_cross(obj/structure/spacevine/holder, mob/living/crosser)
|
||||
if(prob(severity) && istype(crosser) && !isvineimmune(holder))
|
||||
if(prob(severity) && istype(crosser) && !isvineimmune(crosser))
|
||||
var/mob/living/M = crosser
|
||||
M.adjustBruteLoss(5)
|
||||
to_chat(M, "<span class='alert'>You cut yourself on the thorny vines.</span>")
|
||||
|
||||
/datum/spacevine_mutation/thorns/on_hit(obj/structure/spacevine/holder, mob/living/hitter, obj/item/I, expected_damage)
|
||||
if(prob(severity) && istype(hitter) && !isvineimmune(holder))
|
||||
if(prob(severity) && istype(hitter) && !isvineimmune(hitter))
|
||||
var/mob/living/M = hitter
|
||||
M.adjustBruteLoss(5)
|
||||
to_chat(M, "<span class='alert'>You cut yourself on the thorny vines.</span>")
|
||||
@@ -251,7 +251,7 @@
|
||||
holder.obj_integrity = holder.max_integrity
|
||||
|
||||
/datum/spacevine_mutation/woodening/on_hit(obj/structure/spacevine/holder, mob/living/hitter, obj/item/I, expected_damage)
|
||||
if(I.get_sharpness())
|
||||
if(I?.get_sharpness())
|
||||
. = expected_damage * 0.5
|
||||
else
|
||||
. = expected_damage
|
||||
@@ -344,16 +344,17 @@
|
||||
switch(damage_type)
|
||||
if(BRUTE)
|
||||
if(damage_amount)
|
||||
playsound(src, 'sound/weapons/slash.ogg', 50, 1)
|
||||
playsound(src, 'sound/weapons/slash.ogg', 50, TRUE)
|
||||
else
|
||||
playsound(src, 'sound/weapons/tap.ogg', 50, 1)
|
||||
playsound(src, 'sound/weapons/tap.ogg', 50, TRUE)
|
||||
if(BURN)
|
||||
playsound(src.loc, 'sound/items/welder.ogg', 100, 1)
|
||||
playsound(src.loc, 'sound/items/welder.ogg', 100, TRUE)
|
||||
|
||||
/obj/structure/spacevine/Crossed(mob/crosser)
|
||||
if(isliving(crosser))
|
||||
for(var/datum/spacevine_mutation/SM in mutations)
|
||||
SM.on_cross(src, crosser)
|
||||
/obj/structure/spacevine/Crossed(atom/movable/AM)
|
||||
if(!isliving(AM))
|
||||
return
|
||||
for(var/datum/spacevine_mutation/SM in mutations)
|
||||
SM.on_cross(src, AM)
|
||||
|
||||
//ATTACK HAND IGNORING PARENT RETURN VALUE
|
||||
/obj/structure/spacevine/attack_hand(mob/user)
|
||||
@@ -378,10 +379,9 @@
|
||||
var/list/vine_mutations_list
|
||||
var/mutativeness = 1
|
||||
|
||||
/datum/spacevine_controller/New(turf/location, list/muts, potency, production)
|
||||
/datum/spacevine_controller/New(turf/location, list/muts, potency, production, datum/round_event/event = null)
|
||||
vines = list()
|
||||
growth_queue = list()
|
||||
spawn_spacevine_piece(location, null, muts)
|
||||
START_PROCESSING(SSobj, src)
|
||||
vine_mutations_list = list()
|
||||
init_subtypes(/datum/spacevine_mutation/, vine_mutations_list)
|
||||
@@ -428,6 +428,7 @@
|
||||
for(var/datum/spacevine_mutation/SM in SV.mutations)
|
||||
SM.on_birth(SV)
|
||||
location.Entered(SV)
|
||||
return SV
|
||||
|
||||
/datum/spacevine_controller/proc/VineDestroyed(obj/structure/spacevine/S)
|
||||
S.master = null
|
||||
@@ -531,14 +532,13 @@
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/spacevine/CanPass(atom/movable/mover, turf/target)
|
||||
. = ..()
|
||||
if(isvineimmune(mover))
|
||||
. = TRUE
|
||||
else
|
||||
. = ..()
|
||||
return TRUE
|
||||
|
||||
/proc/isvineimmune(atom/A)
|
||||
. = FALSE
|
||||
if(isliving(A))
|
||||
var/mob/living/M = A
|
||||
if(("vines" in M.faction) || ("plants" in M.faction))
|
||||
. = TRUE
|
||||
return TRUE
|
||||
return FALSE
|
||||
@@ -23,6 +23,9 @@
|
||||
/datum/round_event/wormholes/start()
|
||||
for(var/turf/open/floor/T in world)
|
||||
if(is_station_level(T.z))
|
||||
var/area/A = get_area(T)
|
||||
if(A.outdoors)
|
||||
continue
|
||||
pick_turfs += T
|
||||
|
||||
for(var/i = 1, i <= number_of_wormholes, i++)
|
||||
@@ -57,7 +60,7 @@
|
||||
if(!(ismecha(M) && mech_sized))
|
||||
return
|
||||
|
||||
if(ismovableatom(M))
|
||||
if(ismovable(M))
|
||||
if(GLOB.portals.len)
|
||||
var/obj/effect/portal/P = pick(GLOB.portals)
|
||||
if(P && isturf(P.loc))
|
||||
|
||||
@@ -396,6 +396,16 @@
|
||||
list_reagents = list(/datum/reagent/consumable/orangejuice = 100)
|
||||
foodtype = FRUIT| BREAKFAST
|
||||
|
||||
/obj/item/reagent_containers/food/drinks/bottle/bio_carton
|
||||
name = "small carton box"
|
||||
desc = "A small biodegradable carton box made from plant biomatter."
|
||||
icon_state = "eco_box"
|
||||
item_state = "carton"
|
||||
lefthand_file = 'icons/mob/inhands/equipment/kitchen_lefthand.dmi'
|
||||
righthand_file = 'icons/mob/inhands/equipment/kitchen_righthand.dmi'
|
||||
volume = 50
|
||||
isGlass = FALSE
|
||||
|
||||
/obj/item/reagent_containers/food/drinks/bottle/cream
|
||||
name = "milk cream"
|
||||
desc = "It's cream. Made from milk. What else did you think you'd find in there?"
|
||||
|
||||
@@ -16,6 +16,7 @@
|
||||
resistance_flags = FLAMMABLE
|
||||
var/foodtype = NONE
|
||||
var/last_check_time
|
||||
var/food_quality = 50
|
||||
|
||||
/obj/item/reagent_containers/food/Initialize(mapload)
|
||||
. = ..()
|
||||
@@ -23,6 +24,9 @@
|
||||
pixel_x = rand(-5, 5)
|
||||
pixel_y = rand(-5, 5)
|
||||
|
||||
/obj/item/reagent_containers/food/proc/adjust_food_quality(new_quality)
|
||||
food_quality = clamp(new_quality,0,100)
|
||||
|
||||
/obj/item/reagent_containers/food/proc/checkLiked(var/fraction, mob/M)
|
||||
if(last_check_time + 50 < world.time)
|
||||
if(ishuman(M))
|
||||
@@ -32,13 +36,13 @@
|
||||
to_chat(H,"<span class='warning'>What the hell was that thing?!</span>")
|
||||
H.adjust_disgust(25 + 30 * fraction)
|
||||
SEND_SIGNAL(H, COMSIG_ADD_MOOD_EVENT, "toxic_food", /datum/mood_event/disgusting_food)
|
||||
else if(foodtype & H.dna.species.disliked_food)
|
||||
else if((foodtype & H.dna.species.disliked_food) || food_quality <= 30)
|
||||
to_chat(H,"<span class='notice'>That didn't taste very good...</span>")
|
||||
H.adjust_disgust(11 + 15 * fraction)
|
||||
SEND_SIGNAL(H, COMSIG_ADD_MOOD_EVENT, "gross_food", /datum/mood_event/gross_food)
|
||||
else if(foodtype & H.dna.species.liked_food)
|
||||
else if(((foodtype & H.dna.species.liked_food) && food_quality >= 50) || food_quality >= 70) //you like food of high quality, and food of regular quality you have a preference for
|
||||
to_chat(H,"<span class='notice'>I love this taste!</span>")
|
||||
H.adjust_disgust(-5 + -2.5 * fraction)
|
||||
H.adjust_disgust(-5 + (-2.5 * food_quality/50) + -2.5 * fraction)
|
||||
SEND_SIGNAL(H, COMSIG_ADD_MOOD_EVENT, "fav_food", /datum/mood_event/favorite_food)
|
||||
else
|
||||
if(foodtype & H.dna.species.toxic_food)
|
||||
@@ -48,4 +52,4 @@
|
||||
SEND_SIGNAL(H, COMSIG_ADD_MOOD_EVENT, "breakfast", /datum/mood_event/breakfast)
|
||||
last_check_time = world.time
|
||||
|
||||
#undef STOP_SERVING_BREAKFAST
|
||||
#undef STOP_SERVING_BREAKFAST
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
var/list/ingredients = list()
|
||||
var/ingredients_placement = INGREDIENTS_FILL
|
||||
var/customname = "custom"
|
||||
var/total_quality = 0 //quality of all ingredients added together
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/customizable/examine(mob/user)
|
||||
. = ..()
|
||||
@@ -56,6 +57,9 @@
|
||||
S.reagents.trans_to(src,min(S.reagents.total_volume, 15)) //limit of 15, we don't want our custom food to be completely filled by just one ingredient with large reagent volume.
|
||||
foodtype |= S.foodtype
|
||||
update_snack_overlays(S)
|
||||
//quality of customised food is average of the ingredient's qualities
|
||||
total_quality += S.food_quality
|
||||
food_quality = total_quality / length(ingredients)
|
||||
to_chat(user, "<span class='notice'>You add the [I.name] to the [name].</span>")
|
||||
update_name(S)
|
||||
else
|
||||
|
||||
@@ -153,6 +153,12 @@ All foods are distributed among various categories. Use common sense.
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/examine(mob/user)
|
||||
. = ..()
|
||||
if(food_quality >= 70)
|
||||
. += "It is of a high quality."
|
||||
else
|
||||
if(food_quality <= 30)
|
||||
. += "It is of a low quality."
|
||||
|
||||
if(bitecount == 0)
|
||||
return
|
||||
else if(bitecount == 1)
|
||||
@@ -296,6 +302,10 @@ All foods are distributed among various categories. Use common sense.
|
||||
var/obj/item/result
|
||||
if(cooked_type)
|
||||
result = new cooked_type(T)
|
||||
//if the result is food, set its food quality to the original food item's quality
|
||||
if(isfood(result))
|
||||
var/obj/item/reagent_containers/food/food_output = result
|
||||
food_output.adjust_food_quality(food_quality + M.quality_increase)
|
||||
if(istype(M))
|
||||
initialize_cooked_food(result, M.efficiency)
|
||||
else
|
||||
|
||||
@@ -197,6 +197,7 @@
|
||||
icon = 'icons/obj/food/food.dmi'
|
||||
icon_state = ""
|
||||
bitesize = 2
|
||||
var/fried_garbage = FALSE //did you really fry a fire extinguisher?
|
||||
|
||||
GLOBAL_VAR_INIT(frying_hardmode, TRUE)
|
||||
GLOBAL_VAR_INIT(frying_bad_chem_add_volume, TRUE)
|
||||
@@ -227,21 +228,13 @@ GLOBAL_LIST_INIT(frying_bad_chems, list(
|
||||
item_flags = fried.item_flags
|
||||
obj_flags = fried.obj_flags
|
||||
|
||||
if(istype(fried, /obj/item/reagent_containers/food/snacks))
|
||||
if(isfood(fried))
|
||||
fried.reagents.trans_to(src, fried.reagents.total_volume)
|
||||
qdel(fried)
|
||||
else
|
||||
fried.forceMove(src)
|
||||
trash = fried
|
||||
if(!istype(fried, /obj/item/reagent_containers/food) && GLOB.frying_hardmode && GLOB.frying_bad_chems.len)
|
||||
var/R = rand(1, GLOB.frying_bad_chems.len)
|
||||
var/bad_chem = GLOB.frying_bad_chems[R]
|
||||
var/bad_chem_amount = GLOB.frying_bad_chems[bad_chem]
|
||||
if(GLOB.frying_bad_chem_add_volume)
|
||||
reagents.maximum_volume += bad_chem_amount + 2 //Added room for condensed cooking oil
|
||||
reagents.add_reagent(bad_chem, bad_chem_amount)
|
||||
//All fried inedible items also get condensed cooking oil added, which induces minor vomiting and heart damage
|
||||
reagents.add_reagent(/datum/reagent/toxin/condensed_cooking_oil, 2)
|
||||
fried_garbage = TRUE
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/deepfryholder/Destroy()
|
||||
if(trash)
|
||||
@@ -249,6 +242,13 @@ GLOBAL_LIST_INIT(frying_bad_chems, list(
|
||||
. = ..()
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/deepfryholder/On_Consume(mob/living/eater)
|
||||
if(fried_garbage && GLOB.frying_hardmode && GLOB.frying_bad_chems.len)
|
||||
var/R = rand(1, GLOB.frying_bad_chems.len)
|
||||
var/bad_chem = GLOB.frying_bad_chems[R]
|
||||
var/bad_chem_amount = GLOB.frying_bad_chems[bad_chem]
|
||||
eater.reagents.add_reagent(bad_chem, bad_chem_amount)
|
||||
//All fried inedible items also get condensed cooking oil added, which induces minor vomiting and heart damage
|
||||
eater.reagents.add_reagent(/datum/reagent/toxin/condensed_cooking_oil, 2)
|
||||
if(trash)
|
||||
QDEL_NULL(trash)
|
||||
..()
|
||||
@@ -259,18 +259,22 @@ GLOBAL_LIST_INIT(frying_bad_chems, list(
|
||||
add_atom_colour(rgb(166,103,54), FIXED_COLOUR_PRIORITY)
|
||||
name = "lightly-fried [name]"
|
||||
desc = "[desc] It's been lightly fried in a deep fryer."
|
||||
adjust_food_quality(food_quality - 5)
|
||||
if(16 to 49)
|
||||
add_atom_colour(rgb(103,63,24), FIXED_COLOUR_PRIORITY)
|
||||
name = "fried [name]"
|
||||
desc = "[desc] It's been fried, increasing its tastiness value by [rand(1, 75)]%."
|
||||
adjust_food_quality(food_quality - 10)
|
||||
if(50 to 59)
|
||||
add_atom_colour(rgb(63,23,4), FIXED_COLOUR_PRIORITY)
|
||||
name = "deep-fried [name]"
|
||||
desc = "[desc] Deep-fried to perfection."
|
||||
adjust_food_quality(food_quality) //we shouldn't punish perfection in the fried arts
|
||||
if(60 to INFINITY)
|
||||
add_atom_colour(rgb(33,19,9), FIXED_COLOUR_PRIORITY)
|
||||
name = "the physical manifestation of the very concept of fried foods"
|
||||
desc = "A heavily-fried...something. Who can tell anymore?"
|
||||
adjust_food_quality(0) //good job, you're truly the best cook.
|
||||
filling_color = color
|
||||
foodtype |= FRIED
|
||||
|
||||
|
||||
@@ -222,36 +222,6 @@
|
||||
tastes = list("meat" = 1, "onions" = 1, "garlic" = 1)
|
||||
foodtype = MEAT
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/monkeycube
|
||||
name = "monkey cube"
|
||||
desc = "Just add water!"
|
||||
icon_state = "monkeycube"
|
||||
bitesize = 12
|
||||
list_reagents = list(/datum/reagent/consumable/nutriment = 2)
|
||||
filling_color = "#CD853F"
|
||||
tastes = list("the jungle" = 1, "bananas" = 1)
|
||||
foodtype = MEAT | SUGAR
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/monkeycube/On_Consume(mob/living/carbon/M)
|
||||
if(iscarbon(M))
|
||||
M.visible_message("[src] bursts out of [M]!</span>")
|
||||
M.emote("scream")
|
||||
M.DefaultCombatKnockdown(40)
|
||||
M.adjustBruteLoss(60)
|
||||
Expand()
|
||||
return TRUE
|
||||
return ..()
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/monkeycube/proc/Expand()
|
||||
var/mob/spammer = get_mob_by_key(fingerprintslast)
|
||||
var/mob/living/carbon/monkey/bananas = new(drop_location(), TRUE, spammer)
|
||||
if (!QDELETED(bananas))
|
||||
visible_message("<span class='notice'>[src] expands!</span>")
|
||||
bananas.log_message("Spawned via [src] at [AREACOORD(src)], Last attached mob: [key_name(spammer)].", LOG_ATTACK)
|
||||
else if (!spammer) // Visible message in case there are no fingerprints
|
||||
visible_message("<span class='notice'>[src] fails to expand!</span>")
|
||||
qdel(src)
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/enchiladas
|
||||
name = "enchiladas"
|
||||
desc = "Viva La Mexico!"
|
||||
@@ -372,3 +342,70 @@
|
||||
bonus_reagents = list(/datum/reagent/consumable/nutriment = 1, /datum/reagent/consumable/nutriment/vitamin = 1)
|
||||
tastes = list("meat" = 3, "smokey sauce" = 1)
|
||||
foodtype = MEAT
|
||||
|
||||
////////////// Cubes //////////
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/cube
|
||||
name = "debug cube"
|
||||
desc = "Just add water!"
|
||||
icon_state = "monkeycube"
|
||||
bitesize = 12
|
||||
list_reagents = list(/datum/reagent/consumable/nutriment = 2)
|
||||
filling_color = "#CD853F"
|
||||
tastes = list("broken" = 1, "code" = 1)
|
||||
foodtype = MEAT | SUGAR
|
||||
var/dried_being = /mob/living/carbon/monkey //What the cube will spawn mob wise
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/cube/On_Consume(mob/living/carbon/M)
|
||||
if(iscarbon(M))
|
||||
M.visible_message("[src] bursts out of [M]!</span>")
|
||||
M.emote("scream")
|
||||
M.DefaultCombatKnockdown(40)
|
||||
M.adjustBruteLoss(60)
|
||||
Expand()
|
||||
return TRUE
|
||||
return ..()
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/cube/proc/Expand()
|
||||
var/mob/spammer = get_mob_by_key(fingerprintslast)
|
||||
var/mob/living/water = new dried_being(drop_location(), TRUE, spammer)
|
||||
if (!QDELETED(water))
|
||||
visible_message("<span class='notice'>[src] expands!</span>")
|
||||
water.log_message("Spawned via [src] at [AREACOORD(src)], Last attached mob: [key_name(spammer)].", LOG_ATTACK)
|
||||
else if (!spammer) // Visible message in case there are no fingerprints
|
||||
visible_message("<span class='notice'>[src] fails to expand!</span>")
|
||||
qdel(src)
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/cube/monkey
|
||||
name = "monkey cube"
|
||||
desc = "Just add water!"
|
||||
tastes = list("the jungle" = 1, "bananas" = 1)
|
||||
dried_being = /mob/living/carbon/monkey
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/cube/beno
|
||||
name = "alien drone cube"
|
||||
desc = "Just add water and run!"
|
||||
tastes = list("the jungle" = 1, "acid" = 1)
|
||||
dried_being = /mob/living/carbon/alien/humanoid/drone
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/cube/goat
|
||||
name = "goat cube"
|
||||
tastes = list("grass" = 1)
|
||||
dried_being = /mob/living/simple_animal/hostile/retaliate/goat
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/cube/cow
|
||||
name = "cow cube"
|
||||
tastes = list("milk" = 1, "beef" = 1)
|
||||
dried_being = /mob/living/simple_animal/cow
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/cube/egg
|
||||
//Well eggs normally are able to hatch into small birds, this one does not.
|
||||
//Also in order to have a normal egg hatch you need a hen to lay the egg that is able to hatch, meaning this one is for on-demand hen needs.
|
||||
name = "egg cube thing"
|
||||
desc = "Just add water, hey wait a second..."
|
||||
icon_state = "egg"
|
||||
filling_color = "#F0E68C"
|
||||
cooked_type = /obj/item/reagent_containers/food/snacks/boiledegg
|
||||
list_reagents = list(/datum/reagent/consumable/eggyolk = 5)
|
||||
tastes = list("dried eggs" = 1, "confusion" = 1)
|
||||
dried_being = /mob/living/simple_animal/chicken
|
||||
|
||||
@@ -104,6 +104,12 @@ God bless America.
|
||||
else if(!frying && user.transferItemToLoc(I, src))
|
||||
to_chat(user, "<span class='notice'>You put [I] into [src].</span>")
|
||||
frying = new/obj/item/reagent_containers/food/snacks/deepfryholder(src, I)
|
||||
//setup food quality for item depending on if it's edible or not
|
||||
if(isfood(I))
|
||||
var/obj/item/reagent_containers/food/original_food = I
|
||||
frying.adjust_food_quality(original_food.food_quality) //food quality remains unchanged until degree of frying is calculated
|
||||
else
|
||||
frying.adjust_food_quality(10) //inedible fried item has low quality
|
||||
icon_state = "fryer_on"
|
||||
fry_loop.start()
|
||||
|
||||
|
||||
@@ -118,7 +118,7 @@
|
||||
break
|
||||
|
||||
if(href_list["portion"])
|
||||
portion = CLAMP(input("How much drink do you want to dispense per glass?") as num, 0, 50)
|
||||
portion = clamp(input("How much drink do you want to dispense per glass?") as num, 0, 50)
|
||||
|
||||
if(href_list["pour"] || href_list["m_pour"])
|
||||
if(glasses-- <= 0)
|
||||
|
||||
@@ -14,6 +14,7 @@
|
||||
var/gibtime = 40 // Time from starting until meat appears
|
||||
var/meat_produced = 0
|
||||
var/ignore_clothing = FALSE
|
||||
var/meat_quality = 35 //food_quality of meat produced
|
||||
|
||||
|
||||
/obj/machinery/gibber/Initialize()
|
||||
@@ -23,8 +24,10 @@
|
||||
/obj/machinery/gibber/RefreshParts()
|
||||
gibtime = 40
|
||||
meat_produced = 0
|
||||
meat_quality = 35 // unupgraded this means quality is 50, and max upgraded it is 95
|
||||
for(var/obj/item/stock_parts/matter_bin/B in component_parts)
|
||||
meat_produced += B.rating
|
||||
meat_quality += B.rating * 15
|
||||
for(var/obj/item/stock_parts/manipulator/M in component_parts)
|
||||
gibtime -= 5 * M.rating
|
||||
if(M.rating >= 2)
|
||||
@@ -181,6 +184,7 @@
|
||||
|
||||
for (var/i=1 to meat_produced)
|
||||
var/obj/item/reagent_containers/food/snacks/meat/slab/newmeat = new typeofmeat
|
||||
newmeat.adjust_food_quality(meat_quality)
|
||||
newmeat.name = "[sourcename] [newmeat.name]"
|
||||
if(istype(newmeat))
|
||||
newmeat.subjectname = sourcename
|
||||
|
||||
@@ -19,6 +19,7 @@
|
||||
var/broken = 0 // 0, 1 or 2 // How broken is it???
|
||||
var/max_n_of_items = 10
|
||||
var/efficiency = 0
|
||||
var/quality_increase = 5 // how much do we increase the quality of microwaved items
|
||||
var/productivity = 0
|
||||
var/datum/looping_sound/microwave/soundloop
|
||||
var/list/ingredients = list() // may only contain /atom/movables
|
||||
@@ -51,7 +52,10 @@
|
||||
efficiency += M.rating * 0.4
|
||||
productivity += M.rating
|
||||
for(var/obj/item/stock_parts/matter_bin/M in component_parts)
|
||||
max_n_of_items += M.rating * 5
|
||||
|
||||
max_n_of_items = 10 * M.rating
|
||||
quality_increase = M.rating * 5
|
||||
break
|
||||
|
||||
/obj/machinery/microwave/examine(mob/user)
|
||||
. = ..()
|
||||
|
||||
@@ -78,7 +78,7 @@
|
||||
playsound(src.loc, 'sound/machines/hiss.ogg', 50, 1)
|
||||
grinded -= required_grind
|
||||
for(var/i = 0, i < cube_production, i++)
|
||||
new /obj/item/reagent_containers/food/snacks/monkeycube(src.loc)
|
||||
new /obj/item/reagent_containers/food/snacks/cube/monkey(src.loc)
|
||||
to_chat(user, "<span class='notice'>The machine's display flashes that it has [grinded] monkeys worth of material left.</span>")
|
||||
else
|
||||
to_chat(user, "<span class='danger'>The machine needs at least [required_grind] monkey(s) worth of material to produce a monkey cube. It only has [grinded].</span>")
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user