Merge branch 'master' into upstream-merge-31737
This commit is contained in:
@@ -6,7 +6,7 @@
|
||||
if(!SSdbcore.Connect())
|
||||
to_chat(src, "<span class='danger'>Failed to establish database connection.</span>")
|
||||
return
|
||||
var/polltype = input("Choose poll type.","Poll Type") in list("Single Option","Text Reply","Rating","Multiple Choice", "Instant Runoff Voting")|null
|
||||
var/polltype = input("Choose poll type.","Poll Type") as null|anything in list("Single Option","Text Reply","Rating","Multiple Choice", "Instant Runoff Voting")
|
||||
var/choice_amount = 0
|
||||
switch(polltype)
|
||||
if("Single Option")
|
||||
@@ -18,10 +18,14 @@
|
||||
if("Multiple Choice")
|
||||
polltype = POLLTYPE_MULTI
|
||||
choice_amount = input("How many choices should be allowed?","Select choice amount") as num|null
|
||||
if(choice_amount == 0)
|
||||
to_chat(src, "Multiple choice poll must have at least one choice allowed.")
|
||||
else if (choice_amount == null)
|
||||
return
|
||||
switch(choice_amount)
|
||||
if(0)
|
||||
to_chat(src, "Multiple choice poll must have at least one choice allowed.")
|
||||
return
|
||||
if(1)
|
||||
polltype = POLLTYPE_OPTION
|
||||
if(null)
|
||||
return
|
||||
if ("Instant Runoff Voting")
|
||||
polltype = POLLTYPE_IRV
|
||||
else
|
||||
|
||||
@@ -441,7 +441,7 @@
|
||||
dat += "<tr><td><a href='?_src_=vars;[HrefToken()];Vars=\ref[N]'>[N.name]([N.key])</a><i>Head body destroyed!</i></td>"
|
||||
dat += "<td><A href='?priv_msg=[N.key]'>PM</A></td></tr>"
|
||||
dat += "</table>"
|
||||
|
||||
|
||||
if(SSticker.mode.changelings.len > 0)
|
||||
dat += "<br><table cellspacing=5><tr><td><B>Changelings</B></td><td></td><td></td></tr>"
|
||||
for(var/datum/mind/changeling in SSticker.mode.changelings)
|
||||
@@ -593,20 +593,15 @@
|
||||
var/list/blob_minds = list()
|
||||
for(var/mob/camera/blob/B in GLOB.mob_list)
|
||||
blob_minds |= B.mind
|
||||
|
||||
if(istype(SSticker.mode, /datum/game_mode/blob) || blob_minds.len)
|
||||
dat += "<br><table cellspacing=5><tr><td><B>Blob</B></td><td></td><td></td></tr>"
|
||||
if(istype(SSticker.mode, /datum/game_mode/blob))
|
||||
var/datum/game_mode/blob/mode = SSticker.mode
|
||||
blob_minds |= mode.blob_overminds
|
||||
dat += "<tr><td><i>Progress: [GLOB.blobs_legit.len]/[mode.blobwincount]</i></td></tr>"
|
||||
|
||||
if(blob_minds.len)
|
||||
dat += "<br><table cellspacing=5><tr><td><B>Blob</B></td><td></td><td></td></tr>"
|
||||
for(var/datum/mind/blob in blob_minds)
|
||||
var/mob/M = blob.current
|
||||
var/mob/camera/blob/M = blob.current
|
||||
if(M)
|
||||
dat += "<tr><td><a href='?_src_=holder;[HrefToken()];adminplayeropts=\ref[M]'>[M.real_name]</a>[M.client ? "" : " <i>(No Client)</i>"][M.stat == DEAD ? " <b><font color=red>(DEAD)</font></b>" : ""]</td>"
|
||||
dat += "<td><A href='?priv_msg=[M.ckey]'>PM</A></td>"
|
||||
dat += "<td><A href='?_src_=holder;[HrefToken()];adminplayerobservefollow=\ref[M]'>FLW</a></td></tr>"
|
||||
dat += "<tr><td><i>Progress: [M.blobs_legit.len]/[M.blobwincount]</i></td></tr>"
|
||||
else
|
||||
dat += "<tr><td><a href='?_src_=vars;[HrefToken()];Vars=\ref[blob]'>[blob.name]([blob.key])</a><i>Blob not found!</i></td>"
|
||||
dat += "<td><A href='?priv_msg=[blob.key]'>PM</A></td></tr>"
|
||||
|
||||
@@ -340,14 +340,13 @@
|
||||
continue
|
||||
if(is_special_character(H))
|
||||
continue
|
||||
H.mind.add_antag_datum(ANTAG_DATUM_TRAITOR_CUSTOM)
|
||||
var/datum/antagonist/traitor/traitordatum = H.mind.has_antag_datum(ANTAG_DATUM_TRAITOR) //original datum self deletes
|
||||
var/datum/antagonist/traitor/human/T = new(H.mind)
|
||||
T.give_objectives = FALSE
|
||||
var/datum/objective/new_objective = new
|
||||
new_objective.owner = H
|
||||
new_objective.explanation_text = objective
|
||||
traitordatum.add_objective(new_objective)
|
||||
traitordatum.equip(FALSE)
|
||||
traitordatum.greet()
|
||||
T.add_objective(new_objective)
|
||||
H.mind.add_antag_datum(T)
|
||||
message_admins("<span class='adminnotice'>[key_name_admin(usr)] used everyone is a traitor secret. Objective is [objective]</span>")
|
||||
log_admin("[key_name(usr)] used everyone is a traitor secret. Objective is [objective]")
|
||||
|
||||
|
||||
@@ -165,6 +165,7 @@
|
||||
return
|
||||
var/datum/round_event_control/E = locate(href_list["forceevent"]) in SSevents.control
|
||||
if(E)
|
||||
E.admin_setup(usr)
|
||||
var/datum/round_event/event = E.runEvent()
|
||||
if(event.announceWhen>0)
|
||||
event.processing = FALSE
|
||||
|
||||
@@ -237,6 +237,7 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new)
|
||||
. += " (<A HREF='?_src_=holder;[HrefToken(TRUE)];ahelp=[ref_src];ahelp_action=icissue'>IC</A>)"
|
||||
. += " (<A HREF='?_src_=holder;[HrefToken(TRUE)];ahelp=[ref_src];ahelp_action=close'>CLOSE</A>)"
|
||||
. += " (<A HREF='?_src_=holder;[HrefToken(TRUE)];ahelp=[ref_src];ahelp_action=resolve'>RSLVE</A>)"
|
||||
. += " (<A HREF='?_src_=holder;[HrefToken(TRUE)];ahelp=[ref_src];ahelp_action=handleissue'>HANDLE</A>)"
|
||||
|
||||
//private
|
||||
/datum/admin_help/proc/LinkedReplyName(ref_src)
|
||||
@@ -382,6 +383,22 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new)
|
||||
AddInteraction("Marked as IC issue by [key_name]")
|
||||
Resolve(silent = TRUE)
|
||||
|
||||
//Let the initiator know their ahelp is being handled
|
||||
/datum/admin_help/proc/HandleIssue(key_name = key_name_admin(usr))
|
||||
if(state != AHELP_ACTIVE)
|
||||
return
|
||||
|
||||
var/msg = "<span class ='adminhelp'>Your ticket is now being handled by an admin. Please be patient.</span>"
|
||||
|
||||
if(initiator)
|
||||
to_chat(initiator, msg)
|
||||
|
||||
SSblackbox.inc("ahelp_handleissue")
|
||||
msg = "Ticket [TicketHref("#[id]")] is being handled by [key_name]"
|
||||
message_admins(msg)
|
||||
log_admin_private(msg)
|
||||
AddInteraction("Being handled by [key_name]")
|
||||
|
||||
//Show the ticket panel
|
||||
/datum/admin_help/proc/TicketPanel()
|
||||
var/list/dat = list("<html><head><title>Ticket #[id]</title></head>")
|
||||
@@ -442,6 +459,8 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new)
|
||||
Close()
|
||||
if("resolve")
|
||||
Resolve()
|
||||
if("handleissue")
|
||||
HandleIssue()
|
||||
if("reopen")
|
||||
Reopen()
|
||||
|
||||
@@ -489,9 +508,9 @@ GLOBAL_DATUM_INIT(ahelp_tickets, /datum/admin_help_tickets, new)
|
||||
return
|
||||
if(handle_spam_prevention(msg,MUTE_ADMINHELP))
|
||||
return
|
||||
|
||||
|
||||
msg = trim(msg)
|
||||
|
||||
|
||||
if(!msg)
|
||||
return
|
||||
|
||||
|
||||
@@ -262,10 +262,7 @@ GLOBAL_PROTECT(LastAdminCalledProc)
|
||||
if(ishuman(M))
|
||||
log_admin("[key_name(src)] has blobized [M.key].")
|
||||
var/mob/living/carbon/human/H = M
|
||||
spawn(0)
|
||||
var/mob/camera/blob/B = H.become_overmind(FALSE)
|
||||
B.place_blob_core(B.base_point_rate, -1) //place them wherever they are
|
||||
|
||||
H.become_overmind()
|
||||
else
|
||||
alert("Invalid mob")
|
||||
|
||||
|
||||
@@ -14,10 +14,10 @@
|
||||
|
||||
var/oxy = air_contents.gases[/datum/gas/oxygen] ? air_contents.gases[/datum/gas/oxygen][MOLES] : 0
|
||||
var/tox = air_contents.gases[/datum/gas/plasma] ? air_contents.gases[/datum/gas/plasma][MOLES] : 0
|
||||
|
||||
var/trit = air_contents.gases[/datum/gas/tritium] ? air_contents.gases[/datum/gas/tritium][MOLES] : 0
|
||||
if(active_hotspot)
|
||||
if(soh)
|
||||
if(tox > 0.5 && oxy > 0.5)
|
||||
if((tox > 0.5 || trit > 0.5) && oxy > 0.5)
|
||||
if(active_hotspot.temperature < exposed_temperature)
|
||||
active_hotspot.temperature = exposed_temperature
|
||||
if(active_hotspot.volume < exposed_volume)
|
||||
@@ -26,11 +26,11 @@
|
||||
|
||||
var/igniting = 0
|
||||
|
||||
if((exposed_temperature > PLASMA_MINIMUM_BURN_TEMPERATURE) && tox > 0.5)
|
||||
if((exposed_temperature > PLASMA_MINIMUM_BURN_TEMPERATURE) && (tox > 0.5 || trit > 0.5))
|
||||
igniting = 1
|
||||
|
||||
if(igniting)
|
||||
if(oxy < 0.5 || tox < 0.5)
|
||||
if(oxy < 0.5)
|
||||
return 0
|
||||
|
||||
active_hotspot = new /obj/effect/hotspot(src)
|
||||
@@ -112,7 +112,7 @@
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
if(!(location.air) || !location.air.gases[/datum/gas/plasma] || !location.air.gases[/datum/gas/oxygen] || location.air.gases[/datum/gas/plasma][MOLES] < 0.5 || location.air.gases[/datum/gas/oxygen][MOLES] < 0.5)
|
||||
if(!(location.air) || !(location.air.gases[/datum/gas/plasma] || location.air.gases[/datum/gas/tritium]) || !location.air.gases[/datum/gas/oxygen] || (location.air.gases[/datum/gas/plasma][MOLES] < 0.5 && location.air.gases[/datum/gas/tritium][MOLES] < 0.5) || location.air.gases[/datum/gas/oxygen][MOLES] < 0.5)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
|
||||
@@ -6,7 +6,6 @@ What are the archived variables for?
|
||||
#define MINIMUM_HEAT_CAPACITY 0.0003
|
||||
#define QUANTIZE(variable) (round(variable,0.0000001))/*I feel the need to document what happens here. Basically this is used to catch most rounding errors, however it's previous value made it so that
|
||||
once gases got hot enough, most procedures wouldnt occur due to the fact that the mole counts would get rounded away. Thus, we lowered it a few orders of magnititude */
|
||||
|
||||
GLOBAL_LIST_INIT(meta_gas_info, meta_gas_list()) //see ATMOSPHERICS/gas_types.dm
|
||||
GLOBAL_LIST_INIT(gaslist_cache, init_gaslist_cache())
|
||||
|
||||
@@ -401,6 +400,7 @@ GLOBAL_LIST_INIT(gaslist_cache, init_gaslist_cache())
|
||||
|
||||
/datum/gas_mixture/react(turf/open/dump_location)
|
||||
. = 0
|
||||
|
||||
reaction_results = new
|
||||
|
||||
var/list/cached_gases = gases
|
||||
@@ -438,6 +438,9 @@ GLOBAL_LIST_INIT(gaslist_cache, init_gaslist_cache())
|
||||
*/
|
||||
|
||||
. |= reaction.react(src, dump_location)
|
||||
//to_chat(world,reaction.name)
|
||||
if (. & STOP_REACTIONS)
|
||||
break
|
||||
if(.)
|
||||
garbage_collect()
|
||||
if(temperature < TCMB) //just for safety
|
||||
|
||||
@@ -58,7 +58,7 @@ GLOBAL_LIST_INIT(hardcoded_gases, list(/datum/gas/oxygen, /datum/gas/nitrogen, /
|
||||
specific_heat = 200
|
||||
name = "Plasma"
|
||||
gas_overlay = "plasma"
|
||||
moles_visible = MOLES_PLASMA_VISIBLE
|
||||
moles_visible = MOLES_GAS_VISIBLE
|
||||
dangerous = TRUE
|
||||
|
||||
/datum/gas/water_vapor
|
||||
@@ -66,14 +66,14 @@ GLOBAL_LIST_INIT(hardcoded_gases, list(/datum/gas/oxygen, /datum/gas/nitrogen, /
|
||||
specific_heat = 40
|
||||
name = "Water Vapor"
|
||||
gas_overlay = "water_vapor"
|
||||
moles_visible = MOLES_PLASMA_VISIBLE
|
||||
moles_visible = MOLES_GAS_VISIBLE
|
||||
|
||||
/datum/gas/freon
|
||||
id = "freon"
|
||||
/datum/gas/hypernoblium
|
||||
id = "nob"
|
||||
specific_heat = 2000
|
||||
name = "Freon"
|
||||
name = "Hyper-noblium"
|
||||
gas_overlay = "freon"
|
||||
moles_visible = MOLES_PLASMA_VISIBLE
|
||||
moles_visible = MOLES_GAS_VISIBLE
|
||||
dangerous = TRUE
|
||||
|
||||
/datum/gas/nitrous_oxide
|
||||
@@ -84,15 +84,21 @@ GLOBAL_LIST_INIT(hardcoded_gases, list(/datum/gas/oxygen, /datum/gas/nitrogen, /
|
||||
moles_visible = 1
|
||||
dangerous = TRUE
|
||||
|
||||
/datum/gas/oxygen_agent_b
|
||||
id = "agent_b"
|
||||
specific_heat = 300
|
||||
name = "Oxygen Agent B"
|
||||
/datum/gas/brown_gas //This is nitric oxide, but given generic name to avoid confusion with nitrous oxide(N20 vs. NO2)
|
||||
id = "browns"
|
||||
specific_heat = 20
|
||||
name = "Brown Gas"
|
||||
gas_overlay = "browns"
|
||||
moles_visible = MOLES_GAS_VISIBLE
|
||||
dangerous = TRUE
|
||||
|
||||
/datum/gas/volatile_fuel
|
||||
id = "v_fuel"
|
||||
specific_heat = 30
|
||||
name = "Volatile Fuel"
|
||||
/datum/gas/tritium
|
||||
id = "tritium"
|
||||
specific_heat = 10
|
||||
name = "Tritium"
|
||||
gas_overlay = "tritium"
|
||||
moles_visible = MOLES_GAS_VISIBLE
|
||||
dangerous = TRUE
|
||||
|
||||
/datum/gas/bz
|
||||
id = "bz"
|
||||
@@ -100,6 +106,16 @@ GLOBAL_LIST_INIT(hardcoded_gases, list(/datum/gas/oxygen, /datum/gas/nitrogen, /
|
||||
name = "BZ"
|
||||
dangerous = TRUE
|
||||
|
||||
/datum/gas/stimulum
|
||||
id = "stim"
|
||||
specific_heat = 5
|
||||
name = "Stimulum"
|
||||
|
||||
/datum/gas/pluoxium
|
||||
id = "pluox"
|
||||
specific_heat = 80
|
||||
name = "Pluoxium"
|
||||
|
||||
/obj/effect/overlay/gas
|
||||
icon = 'icons/effects/tile_effects.dmi'
|
||||
mouse_opacity = MOUSE_OPACITY_TRANSPARENT
|
||||
|
||||
@@ -1,6 +1,33 @@
|
||||
#define NO_REACTION 0
|
||||
#define REACTING 1
|
||||
|
||||
//Plasma fire properties
|
||||
#define OXYGEN_BURN_RATE_BASE 1.4
|
||||
#define PLASMA_BURN_RATE_DELTA 9
|
||||
#define PLASMA_UPPER_TEMPERATURE 1370+T0C
|
||||
#define PLASMA_MINIMUM_OXYGEN_NEEDED 2
|
||||
#define PLASMA_MINIMUM_OXYGEN_PLASMA_RATIO 30
|
||||
#define PLASMA_OXYGEN_FULLBURN 10
|
||||
#define FIRE_CARBON_ENERGY_RELEASED 100000 //Amount of heat released per mole of burnt carbon into the tile
|
||||
#define FIRE_PLASMA_ENERGY_RELEASED 3000000 //Amount of heat released per mole of burnt plasma into the tile
|
||||
//General assmos defines.
|
||||
#define WATER_VAPOR_FREEZE 200
|
||||
#define BROWNS_FORMATION_ENERGY 100000
|
||||
#define TRITIUM_BURN_OXY_FACTOR 100
|
||||
#define TRITIUM_BURN_TRIT_FACTOR 10
|
||||
#define SUPER_SATURATION_THRESHOLD 96
|
||||
#define STIMULUM_HEAT_SCALE 100000
|
||||
#define STIMULUM_FIRST_RISE 0.65
|
||||
#define STIMULUM_FIRST_DROP 0.065
|
||||
#define STIMULUM_SECOND_RISE 0.0009
|
||||
#define STIMULUM_ABSOLUTE_DROP 0.00000335
|
||||
#define REACTION_OPPRESSION_THRESHOLD 5
|
||||
//Plasma fusion properties
|
||||
#define PLASMA_BINDING_ENERGY 3000000
|
||||
#define MAX_CATALYST_EFFICENCY 9
|
||||
#define PLASMA_FUSED_COEFFICENT 0.08
|
||||
#define CATALYST_COEFFICENT 0.01
|
||||
#define FUSION_PURITY_THRESHOLD 0.9
|
||||
#define FUSION_HEAT_DROPOFF 20000+T0C
|
||||
/datum/controller/subsystem/air/var/list/gas_reactions //this is our singleton of all reactions
|
||||
|
||||
/proc/init_gas_reactions()
|
||||
@@ -35,48 +62,15 @@
|
||||
/datum/gas_reaction/proc/react(datum/gas_mixture/air, atom/location)
|
||||
return NO_REACTION
|
||||
|
||||
//agent b: converts hot co2 and agent b to oxygen. requires plasma as a catalyst. endothermic
|
||||
/datum/gas_reaction/agent_b
|
||||
priority = 2
|
||||
name = "Agent B"
|
||||
id = "agent_b"
|
||||
/datum/gas_reaction/nobliumsupression
|
||||
priority = INFINITY
|
||||
name = "Hyper-Noblium Reaction Supression"
|
||||
id = "nobstop"
|
||||
/datum/gas_reaction/nobliumsupression/init_reqs()
|
||||
min_requirements = list(/datum/gas/hypernoblium = REACTION_OPPRESSION_THRESHOLD)
|
||||
|
||||
/datum/gas_reaction/agent_b/init_reqs()
|
||||
min_requirements = list(
|
||||
"TEMP" = 900,
|
||||
/datum/gas/oxygen_agent_b = MINIMUM_HEAT_CAPACITY,
|
||||
/datum/gas/plasma = MINIMUM_HEAT_CAPACITY,
|
||||
/datum/gas/carbon_dioxide = MINIMUM_HEAT_CAPACITY
|
||||
)
|
||||
|
||||
|
||||
/datum/gas_reaction/agent_b/react(datum/gas_mixture/air)
|
||||
var/list/cached_gases = air.gases
|
||||
var/reaction_rate = min(cached_gases[/datum/gas/carbon_dioxide][MOLES]*0.75, cached_gases[/datum/gas/plasma][MOLES]*0.25, cached_gases[/datum/gas/oxygen_agent_b][MOLES]*0.05)
|
||||
|
||||
cached_gases[/datum/gas/carbon_dioxide][MOLES] -= reaction_rate
|
||||
cached_gases[/datum/gas/oxygen_agent_b][MOLES] -= reaction_rate*0.05
|
||||
|
||||
ASSERT_GAS(/datum/gas/oxygen, air) //only need to assert oxygen, as this reaction doesn't occur without the other gases existing
|
||||
cached_gases[/datum/gas/oxygen][MOLES] += reaction_rate
|
||||
|
||||
air.temperature -= (reaction_rate*20000)/air.heat_capacity()
|
||||
|
||||
return REACTING
|
||||
|
||||
//freon: does a freezy thing?
|
||||
/datum/gas_reaction/freon
|
||||
priority = 1
|
||||
name = "Freon"
|
||||
id = "freon"
|
||||
|
||||
/datum/gas_reaction/freon/init_reqs()
|
||||
min_requirements = list(/datum/gas/freon = MOLES_PLASMA_VISIBLE)
|
||||
|
||||
/datum/gas_reaction/freon/react(datum/gas_mixture/air, turf/open/location)
|
||||
. = NO_REACTION
|
||||
if(location && location.freon_gas_act())
|
||||
. = REACTING
|
||||
/datum/gas_reaction/nobliumsupression/react()
|
||||
return STOP_REACTIONS
|
||||
|
||||
//water vapor: puts out fires?
|
||||
/datum/gas_reaction/water_vapor
|
||||
@@ -85,12 +79,15 @@
|
||||
id = "vapor"
|
||||
|
||||
/datum/gas_reaction/water_vapor/init_reqs()
|
||||
min_requirements = list(/datum/gas/water_vapor = MOLES_PLASMA_VISIBLE)
|
||||
min_requirements = list(/datum/gas/water_vapor = MOLES_GAS_VISIBLE)
|
||||
|
||||
/datum/gas_reaction/water_vapor/react(datum/gas_mixture/air, turf/open/location)
|
||||
. = NO_REACTION
|
||||
if(location && location.water_vapor_gas_act())
|
||||
air.gases[/datum/gas/water_vapor][MOLES] -= MOLES_PLASMA_VISIBLE
|
||||
if (air.temperature <= WATER_VAPOR_FREEZE)
|
||||
if(location && location.freon_gas_act())
|
||||
. = REACTING
|
||||
else if(location && location.water_vapor_gas_act())
|
||||
air.gases[/datum/gas/water_vapor][MOLES] -= MOLES_GAS_VISIBLE
|
||||
. = REACTING
|
||||
|
||||
//fire: combustion of plasma and volatile fuel (treated as hydrocarbons). creates hotspots. exothermic
|
||||
@@ -100,7 +97,7 @@
|
||||
id = "fire"
|
||||
|
||||
/datum/gas_reaction/fire/init_reqs()
|
||||
min_requirements = list("TEMP" = FIRE_MINIMUM_TEMPERATURE_TO_EXIST) //doesn't include plasma reqs b/c of volatile fuel stuff - consider finally axing volatile fuel
|
||||
min_requirements = list("TEMP" = FIRE_MINIMUM_TEMPERATURE_TO_EXIST) //doesn't include plasma reqs b/c of other, rarer, burning gases.
|
||||
|
||||
/datum/gas_reaction/fire/react(datum/gas_mixture/air, turf/open/location)
|
||||
var/energy_released = 0
|
||||
@@ -111,23 +108,23 @@
|
||||
cached_results[id] = 0
|
||||
|
||||
//General volatile gas burn
|
||||
if(cached_gases[/datum/gas/volatile_fuel] && cached_gases[/datum/gas/volatile_fuel][MOLES])
|
||||
if(cached_gases[/datum/gas/tritium] && cached_gases[/datum/gas/tritium][MOLES])
|
||||
var/burned_fuel
|
||||
if(!cached_gases[/datum/gas/oxygen])
|
||||
burned_fuel = 0
|
||||
else if(cached_gases[/datum/gas/oxygen][MOLES] < cached_gases[/datum/gas/volatile_fuel][MOLES])
|
||||
burned_fuel = cached_gases[/datum/gas/oxygen][MOLES]
|
||||
cached_gases[/datum/gas/volatile_fuel][MOLES] -= burned_fuel
|
||||
cached_gases[/datum/gas/oxygen][MOLES] = 0
|
||||
else if(cached_gases[/datum/gas/oxygen][MOLES] < cached_gases[/datum/gas/tritium][MOLES])
|
||||
burned_fuel = cached_gases[/datum/gas/oxygen][MOLES]/TRITIUM_BURN_OXY_FACTOR
|
||||
cached_gases[/datum/gas/tritium][MOLES] -= burned_fuel
|
||||
else
|
||||
burned_fuel = cached_gases[/datum/gas/volatile_fuel][MOLES]
|
||||
cached_gases[/datum/gas/oxygen][MOLES] -= cached_gases[/datum/gas/volatile_fuel][MOLES]
|
||||
burned_fuel = cached_gases[/datum/gas/tritium][MOLES]*TRITIUM_BURN_TRIT_FACTOR
|
||||
cached_gases[/datum/gas/tritium][MOLES] -= cached_gases[/datum/gas/tritium][MOLES]/TRITIUM_BURN_TRIT_FACTOR
|
||||
cached_gases[/datum/gas/oxygen][MOLES] -= cached_gases[/datum/gas/tritium][MOLES]
|
||||
|
||||
if(burned_fuel)
|
||||
energy_released += FIRE_CARBON_ENERGY_RELEASED * burned_fuel
|
||||
|
||||
ASSERT_GAS(/datum/gas/carbon_dioxide, air)
|
||||
cached_gases[/datum/gas/carbon_dioxide][MOLES] += burned_fuel
|
||||
cached_gases[/datum/gas/carbon_dioxide][MOLES] += burned_fuel/TRITIUM_BURN_OXY_FACTOR
|
||||
|
||||
cached_results[id] += burned_fuel
|
||||
|
||||
@@ -137,6 +134,7 @@
|
||||
var/oxygen_burn_rate = 0
|
||||
//more plasma released at higher temperatures
|
||||
var/temperature_scale
|
||||
var/super_saturation
|
||||
if(temperature > PLASMA_UPPER_TEMPERATURE)
|
||||
temperature_scale = 1
|
||||
else
|
||||
@@ -144,15 +142,25 @@
|
||||
if(temperature_scale > 0)
|
||||
var/o2 = cached_gases[/datum/gas/oxygen] ? cached_gases[/datum/gas/oxygen][MOLES] : 0
|
||||
oxygen_burn_rate = OXYGEN_BURN_RATE_BASE - temperature_scale
|
||||
if (o2 > cached_gases[/datum/gas/plasma][MOLES]*PLASMA_OXYGEN_FULLBURN)
|
||||
plasma_burn_rate = (cached_gases[/datum/gas/plasma][MOLES]*temperature_scale)/PLASMA_BURN_RATE_DELTA
|
||||
if(o2 / cached_gases[/datum/gas/plasma][MOLES] > SUPER_SATURATION_THRESHOLD) //supersaturation. Form Tritium.
|
||||
super_saturation = TRUE
|
||||
if(o2 > cached_gases[/datum/gas/plasma][MOLES]*PLASMA_OXYGEN_FULLBURN)
|
||||
plasma_burn_rate = (cached_gases[/datum/gas/plasma][MOLES]*temperature_scale)/PLASMA_BURN_RATE_DELTA
|
||||
else
|
||||
plasma_burn_rate = (temperature_scale*(o2/PLASMA_OXYGEN_FULLBURN))/PLASMA_BURN_RATE_DELTA
|
||||
|
||||
if(plasma_burn_rate > MINIMUM_HEAT_CAPACITY)
|
||||
ASSERT_GAS(/datum/gas/carbon_dioxide, air) //don't need to assert o2, since if it isn't present we'll never reach this point anyway
|
||||
cached_gases[/datum/gas/plasma][MOLES] = QUANTIZE(cached_gases[/datum/gas/plasma][MOLES] - plasma_burn_rate)
|
||||
cached_gases[/datum/gas/oxygen][MOLES] = QUANTIZE(cached_gases[/datum/gas/oxygen][MOLES] - (plasma_burn_rate * oxygen_burn_rate))
|
||||
cached_gases[/datum/gas/carbon_dioxide][MOLES] += plasma_burn_rate
|
||||
if (super_saturation)
|
||||
ASSERT_GAS(/datum/gas/tritium,air)
|
||||
cached_gases[/datum/gas/tritium][MOLES] += plasma_burn_rate
|
||||
else
|
||||
ASSERT_GAS(/datum/gas/carbon_dioxide,air)
|
||||
cached_gases[/datum/gas/carbon_dioxide][MOLES] += plasma_burn_rate
|
||||
|
||||
energy_released += FIRE_PLASMA_ENERGY_RELEASED * (plasma_burn_rate)
|
||||
|
||||
@@ -175,9 +183,9 @@
|
||||
|
||||
return cached_results[id] ? REACTING : NO_REACTION
|
||||
|
||||
//fusion: a terrible idea that was fun to try. turns co2 and plasma into REALLY HOT oxygen and nitrogen. super exothermic lol
|
||||
//fusion: a terrible idea that was fun but broken. Now reworked to be less broken and more interesting.
|
||||
/datum/gas_reaction/fusion
|
||||
exclude = TRUE
|
||||
exclude = FALSE
|
||||
priority = 2
|
||||
name = "Plasmic Fusion"
|
||||
id = "fusion"
|
||||
@@ -186,35 +194,37 @@
|
||||
min_requirements = list(
|
||||
"ENER" = PLASMA_BINDING_ENERGY * 10,
|
||||
/datum/gas/plasma = MINIMUM_HEAT_CAPACITY,
|
||||
/datum/gas/carbon_dioxide = MINIMUM_HEAT_CAPACITY
|
||||
/datum/gas/tritium = MINIMUM_HEAT_CAPACITY
|
||||
)
|
||||
|
||||
/datum/gas_reaction/fusion/react(datum/gas_mixture/air)
|
||||
var/list/cached_gases = air.gases
|
||||
var/temperature = air.temperature
|
||||
|
||||
if((cached_gases[/datum/gas/plasma][MOLES]+cached_gases[/datum/gas/carbon_dioxide][MOLES])/air.total_moles() < FUSION_PURITY_THRESHOLD)
|
||||
//Fusion wont occur if the level of impurities is too high.
|
||||
if(((cached_gases[/datum/gas/plasma][MOLES]+cached_gases[/datum/gas/tritium][MOLES])/air.total_moles() < FUSION_PURITY_THRESHOLD) || air.return_pressure() < 10*ONE_ATMOSPHERE)
|
||||
//Fusion wont occur if the level of impurities is too high or if there is too little pressure.
|
||||
return NO_REACTION
|
||||
|
||||
var/old_heat_capacity = air.heat_capacity()
|
||||
var/carbon_efficency = min(cached_gases[/datum/gas/plasma][MOLES]/cached_gases[/datum/gas/carbon_dioxide][MOLES],MAX_CARBON_EFFICENCY)
|
||||
var/catalyst_efficency = max(min(cached_gases[/datum/gas/plasma][MOLES]/cached_gases[/datum/gas/tritium][MOLES],MAX_CATALYST_EFFICENCY)-(temperature/FUSION_HEAT_DROPOFF),1)
|
||||
var/reaction_energy = THERMAL_ENERGY(air)
|
||||
var/moles_impurities = air.total_moles()-(cached_gases[/datum/gas/plasma][MOLES]+cached_gases[/datum/gas/carbon_dioxide][MOLES])
|
||||
var/moles_impurities = air.total_moles()-(cached_gases[/datum/gas/plasma][MOLES]+cached_gases[/datum/gas/tritium][MOLES])
|
||||
|
||||
var/plasma_fused = (PLASMA_FUSED_COEFFICENT*carbon_efficency)*(temperature/PLASMA_BINDING_ENERGY)
|
||||
var/carbon_catalyzed = (CARBON_CATALYST_COEFFICENT*carbon_efficency)*(temperature/PLASMA_BINDING_ENERGY)
|
||||
var/oxygen_added = carbon_catalyzed
|
||||
var/nitrogen_added = (plasma_fused-oxygen_added)-(THERMAL_ENERGY(air)/PLASMA_BINDING_ENERGY)
|
||||
var/plasma_fused = (PLASMA_FUSED_COEFFICENT*catalyst_efficency)*(temperature/PLASMA_BINDING_ENERGY)*4
|
||||
var/tritium_catalyzed = (CATALYST_COEFFICENT*catalyst_efficency)*(temperature/PLASMA_BINDING_ENERGY)
|
||||
var/oxygen_added = tritium_catalyzed
|
||||
var/waste_added = (plasma_fused-oxygen_added)-((air.total_moles()*air.heat_capacity())/PLASMA_BINDING_ENERGY)
|
||||
reaction_energy = max(reaction_energy+((catalyst_efficency*cached_gases[/datum/gas/plasma][MOLES])/((moles_impurities/catalyst_efficency)+2)*10)+((plasma_fused/((moles_impurities/catalyst_efficency)))*PLASMA_BINDING_ENERGY),0)
|
||||
|
||||
reaction_energy = max(reaction_energy+((carbon_efficency*cached_gases[/datum/gas/plasma][MOLES])/((moles_impurities/carbon_efficency)+2)*10)+((plasma_fused/(moles_impurities/carbon_efficency))*PLASMA_BINDING_ENERGY),0)
|
||||
|
||||
air.assert_gases(/datum/gas/oxygen, /datum/gas/nitrogen)
|
||||
|
||||
cached_gases[/datum/gas/plasma][MOLES] -= plasma_fused
|
||||
cached_gases[/datum/gas/carbon_dioxide][MOLES] -= carbon_catalyzed
|
||||
air.assert_gases(/datum/gas/oxygen, /datum/gas/nitrogen, /datum/gas/water_vapor, /datum/gas/nitrous_oxide, /datum/gas/brown_gas)
|
||||
//Fusion produces an absurd amount of waste products now, requiring active filtration.
|
||||
cached_gases[/datum/gas/plasma][MOLES] = max(cached_gases[/datum/gas/plasma][MOLES] - plasma_fused,0)
|
||||
cached_gases[/datum/gas/tritium][MOLES] = max(cached_gases[/datum/gas/tritium][MOLES] - tritium_catalyzed,0)
|
||||
cached_gases[/datum/gas/oxygen][MOLES] += oxygen_added
|
||||
cached_gases[/datum/gas/nitrogen][MOLES] += nitrogen_added
|
||||
cached_gases[/datum/gas/nitrogen][MOLES] += waste_added
|
||||
cached_gases[/datum/gas/water_vapor][MOLES] += waste_added
|
||||
cached_gases[/datum/gas/nitrous_oxide][MOLES] += waste_added
|
||||
cached_gases[/datum/gas/brown_gas][MOLES] += waste_added
|
||||
|
||||
if(reaction_energy > 0)
|
||||
var/new_heat_capacity = air.heat_capacity()
|
||||
@@ -223,5 +233,152 @@
|
||||
//Prevents whatever mechanism is causing it to hit negative temperatures.
|
||||
return REACTING
|
||||
|
||||
/datum/gas_reaction/brownsformation //The formation of brown gas. Endothermic. Requires N2O as a catalyst.
|
||||
priority = 3
|
||||
name = "Brown Gas formation"
|
||||
id = "brownsformation"
|
||||
|
||||
/datum/gas_reaction/brownsformation/init_reqs()
|
||||
min_requirements = list(
|
||||
/datum/gas/oxygen = 20,
|
||||
/datum/gas/nitrogen = 20,
|
||||
/datum/gas/nitrous_oxide = 5,
|
||||
"TEMP" = FIRE_MINIMUM_TEMPERATURE_TO_EXIST*400
|
||||
)
|
||||
|
||||
/datum/gas_reaction/brownsformation/react(datum/gas_mixture/air)
|
||||
var/list/cached_gases = air.gases
|
||||
var/temperature = air.temperature
|
||||
|
||||
var/old_heat_capacity = air.heat_capacity()
|
||||
var/heat_efficency = temperature/(FIRE_MINIMUM_TEMPERATURE_TO_EXIST*100)
|
||||
var/energy_used = heat_efficency*BROWNS_FORMATION_ENERGY
|
||||
ASSERT_GAS(/datum/gas/brown_gas,air)
|
||||
|
||||
cached_gases[/datum/gas/oxygen][MOLES] -= heat_efficency
|
||||
cached_gases[/datum/gas/nitrogen][MOLES] -= heat_efficency
|
||||
cached_gases[/datum/gas/brown_gas][MOLES] += heat_efficency*2
|
||||
|
||||
if(energy_used > 0)
|
||||
var/new_heat_capacity = air.heat_capacity()
|
||||
if(new_heat_capacity > MINIMUM_HEAT_CAPACITY)
|
||||
air.temperature = max(((temperature*old_heat_capacity - energy_used)/new_heat_capacity),TCMB)
|
||||
return REACTING
|
||||
|
||||
/datum/gas_reaction/bzformation //Formation of BZ by combining plasma and tritium at low pressures. Exothermic.
|
||||
priority = 4
|
||||
name = "BZ Gas formation"
|
||||
id = "bzformation"
|
||||
|
||||
/datum/gas_reaction/bzformation/init_reqs()
|
||||
min_requirements = list(
|
||||
/datum/gas/tritium = 10,
|
||||
/datum/gas/plasma = 10
|
||||
)
|
||||
|
||||
|
||||
/datum/gas_reaction/bzformation/react(datum/gas_mixture/air)
|
||||
var/list/cached_gases = air.gases
|
||||
var/temperature = air.temperature
|
||||
var/pressure = air.return_pressure()
|
||||
|
||||
var/old_heat_capacity = air.heat_capacity()
|
||||
var/reaction_efficency = 1/((pressure/(0.1*ONE_ATMOSPHERE))*(max(cached_gases[/datum/gas/plasma][MOLES]/cached_gases[/datum/gas/tritium][MOLES],1)))
|
||||
var/energy_released = 2*reaction_efficency*FIRE_CARBON_ENERGY_RELEASED
|
||||
|
||||
ASSERT_GAS(/datum/gas/bz,air)
|
||||
cached_gases[/datum/gas/bz][MOLES]+= reaction_efficency
|
||||
cached_gases[/datum/gas/tritium][MOLES] = max(cached_gases[/datum/gas/tritium][MOLES]- 2*reaction_efficency,0)
|
||||
cached_gases[/datum/gas/plasma][MOLES] = max(cached_gases[/datum/gas/plasma][MOLES] - reaction_efficency,0)
|
||||
|
||||
|
||||
if(energy_released > 0)
|
||||
var/new_heat_capacity = air.heat_capacity()
|
||||
if(new_heat_capacity > MINIMUM_HEAT_CAPACITY)
|
||||
air.temperature = max(((temperature*old_heat_capacity + energy_released)/new_heat_capacity),TCMB)
|
||||
return REACTING
|
||||
|
||||
/datum/gas_reaction/stimformation //Stimulum formation follows a strange pattern of how effective it will be at a given temperature, having some multiple peaks and some large dropoffs. Exo and endo thermic.
|
||||
priority = 5
|
||||
name = "Stimulum formation"
|
||||
id = "stimformation"
|
||||
/datum/gas_reaction/stimformation/init_reqs()
|
||||
min_requirements = list(
|
||||
/datum/gas/tritium = 30,
|
||||
/datum/gas/plasma = 10,
|
||||
/datum/gas/bz = 20,
|
||||
/datum/gas/brown_gas = 30,
|
||||
"TEMP" = STIMULUM_HEAT_SCALE/2)
|
||||
|
||||
/datum/gas_reaction/stimformation/react(datum/gas_mixture/air)
|
||||
var/list/cached_gases = air.gases
|
||||
|
||||
var/old_heat_capacity = air.heat_capacity()
|
||||
var/heat_scale = air.temperature/STIMULUM_HEAT_SCALE
|
||||
var/stim_energy_change
|
||||
stim_energy_change =heat_scale + (STIMULUM_FIRST_RISE(heat_scale**2)) - (STIMULUM_FIRST_DROP(heat_scale**3)) + (STIMULUM_SECOND_RISE(heat_scale**4)) - (STIMULUM_ABSOLUTE_DROP(heat_scale**5))
|
||||
|
||||
ASSERT_GAS(/datum/gas/stimulum,air)
|
||||
cached_gases[/datum/gas/stimulum][MOLES]+= heat_scale/10
|
||||
cached_gases[/datum/gas/tritium][MOLES] = max(cached_gases[/datum/gas/tritium][MOLES]- heat_scale,0)
|
||||
cached_gases[/datum/gas/plasma][MOLES] = max(cached_gases[/datum/gas/plasma][MOLES]- heat_scale,0)
|
||||
cached_gases[/datum/gas/brown_gas][MOLES] = max(cached_gases[/datum/gas/brown_gas][MOLES]- heat_scale,0)
|
||||
|
||||
if(stim_energy_change)
|
||||
var/new_heat_capacity = air.heat_capacity()
|
||||
if(new_heat_capacity > MINIMUM_HEAT_CAPACITY)
|
||||
air.temperature = max(((air.temperature*old_heat_capacity + stim_energy_change)/new_heat_capacity),TCMB)
|
||||
return REACTING
|
||||
|
||||
/datum/gas_reaction/nobliumformation //Hyper-Nobelium formation is extrememly endothermic, but requires high temperatures to start. Due to its high mass, hyper-nobelium uses large amounts of nitrogen and tritium. BZ can be used as a catalyst to make it less endothermic.
|
||||
priority = 6
|
||||
name = "Hyper-Noblium condensation"
|
||||
id = "nobformation"
|
||||
|
||||
/datum/gas_reaction/nobliumformation/init_reqs()
|
||||
min_requirements = list(
|
||||
/datum/gas/nitrogen = 10,
|
||||
/datum/gas/tritium = 5,
|
||||
"TEMP" = 5000000)
|
||||
|
||||
/datum/gas_reaction/nobliumformation/react(datum/gas_mixture/air)
|
||||
var/list/cached_gases = air.gases
|
||||
air.assert_gases(/datum/gas/hypernoblium,/datum/gas/bz)
|
||||
var/old_heat_capacity = air.heat_capacity()
|
||||
var/nob_formed = (cached_gases[/datum/gas/nitrogen][MOLES]*cached_gases[/datum/gas/tritium][MOLES])/100
|
||||
var/energy_taken = nob_formed*(10000000/(max(cached_gases[/datum/gas/bz][MOLES],1)))
|
||||
cached_gases[/datum/gas/tritium][MOLES] = max(cached_gases[/datum/gas/tritium][MOLES]- 10*nob_formed,0)
|
||||
cached_gases[/datum/gas/nitrogen][MOLES] = max(cached_gases[/datum/gas/nitrogen][MOLES]- 20*nob_formed,0)
|
||||
cached_gases[/datum/gas/hypernoblium][MOLES]+= nob_formed
|
||||
|
||||
|
||||
if (nob_formed)
|
||||
var/new_heat_capacity = air.heat_capacity()
|
||||
if(new_heat_capacity > MINIMUM_HEAT_CAPACITY)
|
||||
air.temperature = max(((air.temperature*old_heat_capacity - energy_taken)/new_heat_capacity),TCMB)
|
||||
#undef REACTING
|
||||
#undef NO_REACTION
|
||||
#undef OXYGEN_BURN_RATE_BASE
|
||||
#undef PLASMA_BURN_RATE_DELTA
|
||||
#undef PLASMA_UPPER_TEMPERATURE
|
||||
#undef PLASMA_MINIMUM_OXYGEN_NEEDED
|
||||
#undef PLASMA_MINIMUM_OXYGEN_PLASMA_RATIO
|
||||
#undef PLASMA_OXYGEN_FULLBURN
|
||||
#undef FIRE_CARBON_ENERGY_RELEASED
|
||||
#undef FIRE_PLASMA_ENERGY_RELEASED
|
||||
#undef WATER_VAPOR_FREEZE
|
||||
#undef BROWNS_FORMATION_ENERGY
|
||||
#undef TRITIUM_BURN_OXY_FACTOR
|
||||
#undef SUPER_SATURATION_THRESHOLD
|
||||
#undef STIMULUM_HEAT_SCALE
|
||||
#undef STIMULUM_FIRST_RISE
|
||||
#undef STIMULUM_FIRST_DROP
|
||||
#undef STIMULUM_SECOND_RISE
|
||||
#undef STIMULUM_ABSOLUTE_DROP
|
||||
#undef REACTION_OPPRESSION_THRESHOLD
|
||||
#undef PLASMA_BINDING_ENERGY
|
||||
#undef MAX_CATALYST_EFFICENCY
|
||||
#undef PLASMA_FUSED_COEFFICENT
|
||||
#undef CATALYST_COEFFICENT
|
||||
#undef FUSION_PURITY_THRESHOLD
|
||||
#undef FUSION_HEAT_DROPOFF
|
||||
@@ -5,10 +5,10 @@
|
||||
var/max2
|
||||
|
||||
/datum/tlv/New(min2 as num, min1 as num, max1 as num, max2 as num)
|
||||
src.min2 = min2
|
||||
src.min1 = min1
|
||||
src.max1 = max1
|
||||
src.max2 = max2
|
||||
if(min2) src.min2 = min2
|
||||
if(min1) src.min1 = min1
|
||||
if(max1) src.max1 = max1
|
||||
if(max2) src.max2 = max2
|
||||
|
||||
/datum/tlv/proc/get_danger_level(val as num)
|
||||
if(max2 != -1 && val >= max2)
|
||||
@@ -21,6 +21,18 @@
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/datum/tlv/no_checks
|
||||
min2 = -1
|
||||
min1 = -1
|
||||
max1 = -1
|
||||
max2 = -1
|
||||
|
||||
/datum/tlv/dangerous
|
||||
min2 = -1
|
||||
min1 = -1
|
||||
max1 = 0.2
|
||||
max2 = 0.5
|
||||
|
||||
/obj/item/electronics/airalarm
|
||||
name = "air alarm electronics"
|
||||
icon_state = "airalarm_electronics"
|
||||
@@ -78,25 +90,33 @@
|
||||
/datum/gas/oxygen = new/datum/tlv(16, 19, 135, 140), // Partial pressure, kpa
|
||||
/datum/gas/nitrogen = new/datum/tlv(-1, -1, 1000, 1000), // Partial pressure, kpa
|
||||
/datum/gas/carbon_dioxide = new/datum/tlv(-1, -1, 5, 10), // Partial pressure, kpa
|
||||
/datum/gas/plasma = new/datum/tlv(-1, -1, 0.2, 0.5), // Partial pressure, kpa
|
||||
/datum/gas/nitrous_oxide = new/datum/tlv(-1, -1, 0.2, 0.5), // Partial pressure, kpa
|
||||
/datum/gas/bz = new/datum/tlv(-1, -1, 0.2, 0.5),
|
||||
/datum/gas/freon = new/datum/tlv(-1, -1, 0.2, 0.5),
|
||||
/datum/gas/water_vapor = new/datum/tlv(-1, -1, 0.2, 0.5)
|
||||
/datum/gas/plasma = new/datum/tlv/dangerous, // Partial pressure, kpa
|
||||
/datum/gas/nitrous_oxide = new/datum/tlv/dangerous, // Partial pressure, kpa
|
||||
/datum/gas/bz = new/datum/tlv/dangerous,
|
||||
/datum/gas/hypernoblium = new/datum/tlv/dangerous,
|
||||
/datum/gas/water_vapor = new/datum/tlv/dangerous,
|
||||
/datum/gas/tritium = new/datum/tlv/dangerous,
|
||||
/datum/gas/stimulum = new/datum/tlv/dangerous,
|
||||
/datum/gas/brown_gas = new/datum/tlv/dangerous,
|
||||
/datum/gas/pluoxium = new/datum/tlv/dangerous
|
||||
)
|
||||
|
||||
/obj/machinery/airalarm/server // No checks here.
|
||||
TLV = list(
|
||||
"pressure" = new/datum/tlv(-1, -1, -1, -1),
|
||||
"temperature" = new/datum/tlv(-1, -1, -1, -1),
|
||||
/datum/gas/oxygen = new/datum/tlv(-1, -1, -1, -1),
|
||||
/datum/gas/nitrogen = new/datum/tlv(-1, -1, -1, -1),
|
||||
/datum/gas/carbon_dioxide = new/datum/tlv(-1, -1, -1, -1),
|
||||
/datum/gas/plasma = new/datum/tlv(-1, -1, -1, -1),
|
||||
/datum/gas/nitrous_oxide = new/datum/tlv(-1, -1, -1, -1),
|
||||
/datum/gas/bz = new/datum/tlv(-1, -1, -1, -1),
|
||||
/datum/gas/freon = new/datum/tlv(-1, -1, -1, -1),
|
||||
/datum/gas/water_vapor = new/datum/tlv(-1, -1, -1, -1)
|
||||
"pressure" = new/datum/tlv/no_checks,
|
||||
"temperature" = new/datum/tlv/no_checks,
|
||||
/datum/gas/oxygen = new/datum/tlv/no_checks,
|
||||
/datum/gas/nitrogen = new/datum/tlv/no_checks,
|
||||
/datum/gas/carbon_dioxide = new/datum/tlv/no_checks,
|
||||
/datum/gas/plasma = new/datum/tlv/no_checks,
|
||||
/datum/gas/nitrous_oxide = new/datum/tlv/no_checks,
|
||||
/datum/gas/bz = new/datum/tlv/no_checks,
|
||||
/datum/gas/hypernoblium = new/datum/tlv/no_checks,
|
||||
/datum/gas/water_vapor = new/datum/tlv/no_checks,
|
||||
/datum/gas/tritium = new/datum/tlv/no_checks,
|
||||
/datum/gas/stimulum = new/datum/tlv/no_checks,
|
||||
/datum/gas/brown_gas = new/datum/tlv/no_checks,
|
||||
/datum/gas/pluoxium = new/datum/tlv/no_checks
|
||||
)
|
||||
|
||||
/obj/machinery/airalarm/kitchen_cold_room // Copypasta: to check temperatures.
|
||||
@@ -106,11 +126,15 @@
|
||||
/datum/gas/oxygen = new/datum/tlv(16, 19, 135, 140), // Partial pressure, kpa
|
||||
/datum/gas/nitrogen = new/datum/tlv(-1, -1, 1000, 1000), // Partial pressure, kpa
|
||||
/datum/gas/carbon_dioxide = new/datum/tlv(-1, -1, 5, 10), // Partial pressure, kpa
|
||||
/datum/gas/plasma = new/datum/tlv(-1, -1, 0.2, 0.5), // Partial pressure, kpa
|
||||
/datum/gas/nitrous_oxide = new/datum/tlv(-1, -1, 0.2, 0.5), // Partial pressure, kpa
|
||||
/datum/gas/bz = new/datum/tlv(-1, -1, 0.2, 0.5),
|
||||
/datum/gas/freon = new/datum/tlv(-1, -1, 0.2, 0.5),
|
||||
/datum/gas/water_vapor = new/datum/tlv(-1, -1, 0.2, 0.5)
|
||||
/datum/gas/plasma = new/datum/tlv/dangerous, // Partial pressure, kpa
|
||||
/datum/gas/nitrous_oxide = new/datum/tlv/dangerous, // Partial pressure, kpa
|
||||
/datum/gas/bz = new/datum/tlv/dangerous,
|
||||
/datum/gas/hypernoblium = new/datum/tlv/dangerous,
|
||||
/datum/gas/water_vapor = new/datum/tlv/dangerous,
|
||||
/datum/gas/tritium = new/datum/tlv/dangerous,
|
||||
/datum/gas/stimulum = new/datum/tlv/dangerous,
|
||||
/datum/gas/brown_gas = new/datum/tlv/dangerous,
|
||||
/datum/gas/pluoxium = new/datum/tlv/dangerous
|
||||
)
|
||||
|
||||
/obj/machinery/airalarm/engine
|
||||
@@ -256,8 +280,7 @@
|
||||
"filter_co2" = info["filter_co2"],
|
||||
"filter_toxins" = info["filter_toxins"],
|
||||
"filter_n2o" = info["filter_n2o"],
|
||||
"filter_bz" = info["filter_bz"],
|
||||
"filter_freon" = info["filter_freon"],
|
||||
"filter_rare" = info["filter_rare"],
|
||||
"filter_water_vapor" = info["filter_water_vapor"]
|
||||
))
|
||||
data["mode"] = mode
|
||||
@@ -314,7 +337,7 @@
|
||||
if(usr.has_unlimited_silicon_privilege && !wires.is_cut(WIRE_IDSCAN))
|
||||
locked = !locked
|
||||
. = TRUE
|
||||
if("power", "co2_scrub", "tox_scrub", "n2o_scrub", "bz_scrub", "freon_scrub","water_vapor_scrub", "widenet", "scrubbing")
|
||||
if("power", "co2_scrub", "tox_scrub", "n2o_scrub", "rare_scrub","water_vapor_scrub", "widenet", "scrubbing")
|
||||
send_signal(device_id, list("[action]" = text2num(params["val"])))
|
||||
. = TRUE
|
||||
if("excheck")
|
||||
@@ -433,8 +456,7 @@
|
||||
"co2_scrub" = 1,
|
||||
"tox_scrub" = 0,
|
||||
"n2o_scrub" = 0,
|
||||
"bz_scrub" = 0,
|
||||
"freon_scrub"= 0,
|
||||
"rare_scrub"= 0,
|
||||
"water_vapor_scrub"= 0,
|
||||
"scrubbing" = 1,
|
||||
"widenet" = 0,
|
||||
@@ -452,8 +474,7 @@
|
||||
"co2_scrub" = 1,
|
||||
"tox_scrub" = 1,
|
||||
"n2o_scrub" = 1,
|
||||
"bz_scrub" = 1,
|
||||
"freon_scrub"= 1,
|
||||
"rare_scrub"= 1,
|
||||
"water_vapor_scrub"= 1,
|
||||
"scrubbing" = 1,
|
||||
"widenet" = 1,
|
||||
@@ -484,8 +505,7 @@
|
||||
"co2_scrub" = 1,
|
||||
"tox_scrub" = 0,
|
||||
"n2o_scrub" = 0,
|
||||
"bz_scrub" = 0,
|
||||
"freon_scrub"= 0,
|
||||
"rare_scrub"= 0,
|
||||
"water_vapor_scrub"= 0,
|
||||
"scrubbing" = 1,
|
||||
"widenet" = 0,
|
||||
|
||||
@@ -36,6 +36,9 @@ Pipelines + Other Objects -> Pipe network
|
||||
var/device_type = 0
|
||||
var/list/obj/machinery/atmospherics/nodes
|
||||
|
||||
var/construction_type
|
||||
var/pipe_state //icon_state as a pipe item
|
||||
|
||||
/obj/machinery/atmospherics/examine(mob/user)
|
||||
..()
|
||||
if(is_type_in_list(src, GLOB.ventcrawl_machinery) && isliving(user))
|
||||
@@ -239,7 +242,7 @@ Pipelines + Other Objects -> Pipe network
|
||||
/obj/machinery/atmospherics/deconstruct(disassembled = TRUE)
|
||||
if(!(flags_1 & NODECONSTRUCT_1))
|
||||
if(can_unwrench)
|
||||
var/obj/item/pipe/stored = new(loc, piping_layer, dir, src)
|
||||
var/obj/item/pipe/stored = new construction_type(loc, null, dir, src)
|
||||
stored.setPipingLayer(piping_layer)
|
||||
if(!disassembled)
|
||||
stored.obj_integrity = stored.max_integrity * 0.5
|
||||
@@ -271,7 +274,7 @@ Pipelines + Other Objects -> Pipe network
|
||||
if(unconnected & direction)
|
||||
underlays += getpipeimage('icons/obj/atmospherics/components/binary_devices.dmi', "pipe_exposed", direction)
|
||||
|
||||
/obj/machinery/atmospherics/on_construction(pipe_type, obj_color, set_layer)
|
||||
/obj/machinery/atmospherics/on_construction(obj_color, set_layer)
|
||||
if(can_unwrench)
|
||||
add_atom_colour(obj_color, FIXED_COLOUR_PRIORITY)
|
||||
pipe_color = obj_color
|
||||
|
||||
@@ -21,6 +21,9 @@ Passive gate is similar to the regular pump except:
|
||||
var/id = null
|
||||
var/datum/radio_frequency/radio_connection
|
||||
|
||||
construction_type = /obj/item/pipe/directional
|
||||
pipe_state = "passivegate"
|
||||
|
||||
/obj/machinery/atmospherics/components/binary/passive_gate/Destroy()
|
||||
SSradio.remove_object(src,frequency)
|
||||
return ..()
|
||||
@@ -167,4 +170,3 @@ Passive gate is similar to the regular pump except:
|
||||
if(. && on)
|
||||
to_chat(user, "<span class='warning'>You cannot unwrench [src], turn it off first!</span>")
|
||||
return FALSE
|
||||
|
||||
|
||||
@@ -26,6 +26,9 @@ Thus, the two variables affect pump operation are set in New():
|
||||
var/id = null
|
||||
var/datum/radio_frequency/radio_connection
|
||||
|
||||
construction_type = /obj/item/pipe/directional
|
||||
pipe_state = "pump"
|
||||
|
||||
/obj/machinery/atmospherics/components/binary/pump/on
|
||||
on = TRUE
|
||||
|
||||
|
||||
@@ -15,6 +15,9 @@ It's like a regular ol' straight pipe, but you can turn it on and off.
|
||||
var/open = FALSE
|
||||
var/valve_type = "m" //lets us have a nice, clean, OOP update_icon_nopipes()
|
||||
|
||||
construction_type = /obj/item/pipe/binary
|
||||
pipe_state = "mvalve"
|
||||
|
||||
/obj/machinery/atmospherics/components/binary/valve/open
|
||||
open = TRUE
|
||||
|
||||
@@ -65,6 +68,7 @@ It's like a regular ol' straight pipe, but you can turn it on and off.
|
||||
desc = "A digitally controlled valve."
|
||||
icon_state = "dvalve_map"
|
||||
valve_type = "d"
|
||||
pipe_state = "dvalve"
|
||||
|
||||
/obj/machinery/atmospherics/components/binary/valve/digital/attack_ai(mob/user)
|
||||
return src.attack_hand(user)
|
||||
|
||||
@@ -26,6 +26,9 @@ Thus, the two variables affect pump operation are set in New():
|
||||
var/id = null
|
||||
var/datum/radio_frequency/radio_connection
|
||||
|
||||
construction_type = /obj/item/pipe/directional
|
||||
pipe_state = "volumepump"
|
||||
|
||||
/obj/machinery/atmospherics/components/binary/volume_pump/Destroy()
|
||||
SSradio.remove_object(src,frequency)
|
||||
return ..()
|
||||
|
||||
@@ -10,6 +10,9 @@
|
||||
var/frequency = 0
|
||||
var/datum/radio_frequency/radio_connection
|
||||
|
||||
construction_type = /obj/item/pipe/trinary/flippable
|
||||
pipe_state = "filter"
|
||||
|
||||
/obj/machinery/atmospherics/components/trinary/filter/flipped
|
||||
icon_state = "filter_off_f"
|
||||
flipped = TRUE
|
||||
|
||||
@@ -12,6 +12,9 @@
|
||||
var/node1_concentration = 0.5
|
||||
var/node2_concentration = 0.5
|
||||
|
||||
construction_type = /obj/item/pipe/trinary/flippable
|
||||
pipe_state = "mixer"
|
||||
|
||||
//node 3 is the outlet, nodes 1 & 2 are intakes
|
||||
|
||||
/obj/machinery/atmospherics/components/trinary/mixer/flipped
|
||||
@@ -171,4 +174,3 @@
|
||||
if(. && on && is_operational())
|
||||
to_chat(user, "<span class='warning'>You cannot unwrench [src], turn it off first!</span>")
|
||||
return FALSE
|
||||
|
||||
|
||||
@@ -12,6 +12,8 @@
|
||||
var/obj/machinery/atmospherics/components/unary/heat_exchanger/partner = null
|
||||
var/update_cycle
|
||||
|
||||
pipe_state = "heunary"
|
||||
|
||||
/obj/machinery/atmospherics/components/unary/heat_exchanger/update_icon()
|
||||
if(NODE1)
|
||||
icon_state = "he_intact"
|
||||
|
||||
@@ -18,6 +18,8 @@
|
||||
level = 1
|
||||
layer = GAS_SCRUBBER_LAYER
|
||||
|
||||
pipe_state = "injector"
|
||||
|
||||
/obj/machinery/atmospherics/components/unary/outlet_injector/Destroy()
|
||||
SSradio.remove_object(src,frequency)
|
||||
return ..()
|
||||
@@ -188,4 +190,3 @@
|
||||
if(. && on && is_operational())
|
||||
to_chat(user, "<span class='warning'>You cannot unwrench [src], turn it off first!</span>")
|
||||
return FALSE
|
||||
|
||||
|
||||
@@ -9,6 +9,7 @@
|
||||
level = 0
|
||||
layer = GAS_FILTER_LAYER
|
||||
pipe_flags = PIPING_ONE_PER_TURF
|
||||
pipe_state = "connector"
|
||||
|
||||
/obj/machinery/atmospherics/components/unary/portables_connector/New()
|
||||
..()
|
||||
|
||||
@@ -28,9 +28,6 @@
|
||||
icon_state = "orange"
|
||||
gas_type = /datum/gas/plasma
|
||||
|
||||
/obj/machinery/atmospherics/components/unary/tank/oxygen_agent_b
|
||||
icon_state = "orange_2"
|
||||
gas_type = /datum/gas/oxygen_agent_b
|
||||
|
||||
/obj/machinery/atmospherics/components/unary/tank/oxygen
|
||||
icon_state = "blue"
|
||||
|
||||
@@ -4,6 +4,7 @@
|
||||
initialize_directions = SOUTH
|
||||
device_type = UNARY
|
||||
pipe_flags = PIPING_ONE_PER_TURF
|
||||
construction_type = /obj/item/pipe/directional
|
||||
|
||||
/obj/machinery/atmospherics/components/unary/SetInitDirections()
|
||||
initialize_directions = dir
|
||||
|
||||
@@ -31,6 +31,8 @@
|
||||
var/radio_filter_out
|
||||
var/radio_filter_in
|
||||
|
||||
pipe_state = "uvent"
|
||||
|
||||
/obj/machinery/atmospherics/components/unary/vent_pump/on
|
||||
on = TRUE
|
||||
icon_state = "vent_map_on"
|
||||
|
||||
@@ -20,8 +20,7 @@
|
||||
var/scrub_CO2 = TRUE
|
||||
var/scrub_Toxins = FALSE
|
||||
var/scrub_N2O = FALSE
|
||||
var/scrub_BZ = FALSE
|
||||
var/scrub_Freon = FALSE
|
||||
var/scrub_Rare = FALSE
|
||||
var/scrub_WaterVapor = FALSE
|
||||
|
||||
|
||||
@@ -34,6 +33,8 @@
|
||||
var/radio_filter_out
|
||||
var/radio_filter_in
|
||||
|
||||
pipe_state = "scrubber"
|
||||
|
||||
/obj/machinery/atmospherics/components/unary/vent_scrubber/New()
|
||||
..()
|
||||
if(!id_tag)
|
||||
@@ -70,9 +71,7 @@
|
||||
amount += idle_power_usage
|
||||
if(scrub_N2O)
|
||||
amount += idle_power_usage
|
||||
if(scrub_BZ)
|
||||
amount += idle_power_usage
|
||||
if(scrub_Freon)
|
||||
if(scrub_Rare)
|
||||
amount += idle_power_usage
|
||||
if(scrub_WaterVapor)
|
||||
amount += idle_power_usage
|
||||
@@ -125,8 +124,7 @@
|
||||
"filter_co2" = scrub_CO2,
|
||||
"filter_toxins" = scrub_Toxins,
|
||||
"filter_n2o" = scrub_N2O,
|
||||
"filter_bz" = scrub_BZ,
|
||||
"filter_freon" = scrub_Freon,
|
||||
"filter_rare" =scrub_Rare,
|
||||
"filter_water_vapor" = scrub_WaterVapor,
|
||||
"sigtype" = "status"
|
||||
)
|
||||
@@ -198,37 +196,52 @@
|
||||
filtered_out.temperature = removed.temperature
|
||||
|
||||
if(scrub_Toxins && removed_gases[/datum/gas/plasma])
|
||||
ADD_GAS(/datum/gas/plasma, filtered_out.gases)
|
||||
ADD_GAS(/datum/gas/plasma, filtered_gases)
|
||||
filtered_gases[/datum/gas/plasma][MOLES] = removed_gases[/datum/gas/plasma][MOLES]
|
||||
removed_gases[/datum/gas/plasma][MOLES] = 0
|
||||
|
||||
if(scrub_CO2 && removed_gases[/datum/gas/carbon_dioxide])
|
||||
ADD_GAS(/datum/gas/carbon_dioxide, filtered_out.gases)
|
||||
ADD_GAS(/datum/gas/carbon_dioxide, filtered_gases)
|
||||
filtered_gases[/datum/gas/carbon_dioxide][MOLES] = removed_gases[/datum/gas/carbon_dioxide][MOLES]
|
||||
removed_gases[/datum/gas/carbon_dioxide][MOLES] = 0
|
||||
|
||||
if(removed_gases[/datum/gas/oxygen_agent_b])
|
||||
ADD_GAS(/datum/gas/oxygen_agent_b, filtered_out.gases)
|
||||
filtered_gases[/datum/gas/oxygen_agent_b][MOLES] = removed_gases[/datum/gas/oxygen_agent_b][MOLES]
|
||||
removed_gases[/datum/gas/oxygen_agent_b][MOLES] = 0
|
||||
|
||||
if(scrub_N2O && removed_gases[/datum/gas/nitrous_oxide])
|
||||
ADD_GAS(/datum/gas/nitrous_oxide, filtered_out.gases)
|
||||
ADD_GAS(/datum/gas/nitrous_oxide, filtered_gases)
|
||||
filtered_gases[/datum/gas/nitrous_oxide][MOLES] = removed_gases[/datum/gas/nitrous_oxide][MOLES]
|
||||
removed_gases[/datum/gas/nitrous_oxide][MOLES] = 0
|
||||
|
||||
if(scrub_BZ && removed_gases[/datum/gas/bz])
|
||||
ADD_GAS(/datum/gas/bz, filtered_out.gases)
|
||||
if(scrub_Rare && removed_gases[/datum/gas/bz])
|
||||
ADD_GAS(/datum/gas/bz, filtered_gases)
|
||||
filtered_gases[/datum/gas/bz][MOLES] = removed_gases[/datum/gas/bz][MOLES]
|
||||
removed_gases[/datum/gas/bz][MOLES] = 0
|
||||
|
||||
if(scrub_Freon && removed_gases[/datum/gas/freon])
|
||||
ADD_GAS(/datum/gas/freon, filtered_out.gases)
|
||||
filtered_gases[/datum/gas/freon][MOLES] = removed_gases[/datum/gas/freon][MOLES]
|
||||
removed_gases[/datum/gas/freon][MOLES] = 0
|
||||
if(scrub_Rare && removed_gases[/datum/gas/hypernoblium])
|
||||
ADD_GAS(/datum/gas/hypernoblium, filtered_gases)
|
||||
filtered_gases[/datum/gas/hypernoblium][MOLES] = removed_gases[/datum/gas/hypernoblium][MOLES]
|
||||
removed_gases[/datum/gas/hypernoblium][MOLES] = 0
|
||||
|
||||
if(scrub_Rare && removed_gases[/datum/gas/stimulum])
|
||||
ADD_GAS(/datum/gas/stimulum, filtered_gases)
|
||||
filtered_gases[/datum/gas/stimulum][MOLES] = removed_gases[/datum/gas/stimulum][MOLES]
|
||||
removed_gases[/datum/gas/stimulum][MOLES] = 0
|
||||
|
||||
if(scrub_Rare && removed_gases[/datum/gas/pluoxium])
|
||||
ADD_GAS(/datum/gas/pluoxium, filtered_gases)
|
||||
filtered_gases[/datum/gas/pluoxium][MOLES] = removed_gases[/datum/gas/pluoxium][MOLES]
|
||||
removed_gases[/datum/gas/pluoxium][MOLES] = 0
|
||||
|
||||
if(scrub_Rare && removed_gases[/datum/gas/brown_gas])
|
||||
ADD_GAS(/datum/gas/brown_gas, filtered_gases)
|
||||
filtered_gases[/datum/gas/brown_gas][MOLES] = removed_gases[/datum/gas/brown_gas][MOLES]
|
||||
removed_gases[/datum/gas/brown_gas][MOLES] = 0
|
||||
|
||||
if(scrub_Rare && removed_gases[/datum/gas/tritium])
|
||||
ADD_GAS(/datum/gas/tritium, filtered_gases)
|
||||
filtered_gases[/datum/gas/tritium][MOLES] = removed_gases[/datum/gas/tritium][MOLES]
|
||||
removed_gases[/datum/gas/tritium][MOLES] = 0
|
||||
|
||||
if(scrub_WaterVapor && removed_gases[/datum/gas/water_vapor])
|
||||
ADD_GAS(/datum/gas/water_vapor, filtered_out.gases)
|
||||
ADD_GAS(/datum/gas/water_vapor, filtered_gases)
|
||||
filtered_gases[/datum/gas/water_vapor][MOLES] = removed_gases[/datum/gas/water_vapor][MOLES]
|
||||
removed_gases[/datum/gas/water_vapor][MOLES] = 0
|
||||
|
||||
@@ -303,15 +316,10 @@
|
||||
if("toggle_n2o_scrub" in signal.data)
|
||||
scrub_N2O = !scrub_N2O
|
||||
|
||||
if("bz_scrub" in signal.data)
|
||||
scrub_BZ = text2num(signal.data["bz_scrub"])
|
||||
if("toggle_bz_scrub" in signal.data)
|
||||
scrub_BZ = !scrub_BZ
|
||||
|
||||
if("freon_scrub" in signal.data)
|
||||
scrub_Freon = text2num(signal.data["freon_scrub"])
|
||||
if("toggle_freon_scrub" in signal.data)
|
||||
scrub_Freon = !scrub_Freon
|
||||
if("rare_scrub" in signal.data)
|
||||
scrub_Rare = text2num(signal.data["rare_scrub"])
|
||||
if("toggle_rare_scrub" in signal.data)
|
||||
scrub_Rare = !scrub_Rare
|
||||
|
||||
if("water_vapor_scrub" in signal.data)
|
||||
scrub_WaterVapor = text2num(signal.data["water_vapor_scrub"])
|
||||
|
||||
@@ -173,21 +173,6 @@
|
||||
overlay_color = "#FAFF00"
|
||||
spawn_id = /datum/gas/bz
|
||||
|
||||
/obj/machinery/atmospherics/miner/freon
|
||||
name = "\improper Freon Gas Miner"
|
||||
overlay_color = "#00FFE5"
|
||||
spawn_id = /datum/gas/freon
|
||||
|
||||
/obj/machinery/atmospherics/miner/volatile_fuel
|
||||
name = "\improper Volatile Fuel Gas Miner"
|
||||
overlay_color = "#564040"
|
||||
spawn_id = /datum/gas/volatile_fuel
|
||||
|
||||
/obj/machinery/atmospherics/miner/agent_b
|
||||
name = "\improper Agent B Gas Miner"
|
||||
overlay_color = "#E81E24"
|
||||
spawn_id = /datum/gas/oxygen_agent_b
|
||||
|
||||
/obj/machinery/atmospherics/miner/water_vapor
|
||||
name = "\improper Water Vapor Gas Miner"
|
||||
overlay_color = "#99928E"
|
||||
|
||||
@@ -13,6 +13,9 @@
|
||||
initialize_directions_he = SOUTH
|
||||
|
||||
device_type = BINARY
|
||||
|
||||
construction_type = /obj/item/pipe/directional
|
||||
pipe_state = "junction"
|
||||
|
||||
/obj/machinery/atmospherics/pipe/heat_exchanging/junction/SetInitDirections()
|
||||
switch(dir)
|
||||
@@ -43,4 +46,4 @@
|
||||
return 0
|
||||
init_dir = H.initialize_directions_he
|
||||
if(init_dir & get_dir(target,src))
|
||||
return 1
|
||||
return 1
|
||||
|
||||
@@ -10,6 +10,9 @@
|
||||
|
||||
device_type = TRINARY
|
||||
|
||||
construction_type = /obj/item/pipe/trinary
|
||||
pipe_state = "he_manifold"
|
||||
|
||||
/obj/machinery/atmospherics/pipe/heat_exchanging/manifold/SetInitDirections()
|
||||
switch(dir)
|
||||
if(NORTH)
|
||||
@@ -44,6 +47,9 @@
|
||||
|
||||
device_type = QUATERNARY
|
||||
|
||||
construction_type = /obj/item/pipe/quaternary
|
||||
pipe_state = "he_manifold4w"
|
||||
|
||||
/obj/machinery/atmospherics/pipe/heat_exchanging/manifold4w/SetInitDirections()
|
||||
initialize_directions_he = initial(initialize_directions_he)
|
||||
|
||||
@@ -57,4 +63,4 @@
|
||||
//Add non-broken pieces
|
||||
for(DEVICE_TYPE_LOOP)
|
||||
if(NODE_I)
|
||||
add_overlay(getpipeimage('icons/obj/atmospherics/pipes/heat.dmi', "manifold_intact[invis]", get_dir(src, NODE_I)))
|
||||
add_overlay(getpipeimage('icons/obj/atmospherics/pipes/heat.dmi', "manifold_intact[invis]", get_dir(src, NODE_I)))
|
||||
|
||||
@@ -9,6 +9,9 @@
|
||||
|
||||
device_type = BINARY
|
||||
|
||||
construction_type = /obj/item/pipe/binary/bendable
|
||||
pipe_state = "he"
|
||||
|
||||
/obj/machinery/atmospherics/pipe/heat_exchanging/simple/SetInitDirections()
|
||||
if(dir in GLOB.diagonals)
|
||||
initialize_directions_he = dir
|
||||
@@ -30,4 +33,4 @@
|
||||
|
||||
/obj/machinery/atmospherics/pipe/heat_exchanging/simple/update_icon()
|
||||
normalize_dir()
|
||||
..()
|
||||
..()
|
||||
|
||||
@@ -11,6 +11,8 @@
|
||||
volume = 260
|
||||
var/list/front_nodes
|
||||
var/list/back_nodes
|
||||
construction_type = /obj/item/pipe/binary
|
||||
pipe_state = "layer_manifold"
|
||||
|
||||
/obj/machinery/atmospherics/pipe/layer_manifold/Initialize()
|
||||
front_nodes = list()
|
||||
@@ -31,17 +33,7 @@
|
||||
A.build_network()
|
||||
|
||||
/obj/machinery/atmospherics/pipe/layer_manifold/proc/get_all_connected_nodes()
|
||||
var/list/obj/machinery/atmospherics/all_connected = list()
|
||||
for(var/obj/machinery/atmospherics/I in front_nodes)
|
||||
all_connected[I] = I
|
||||
for(var/obj/machinery/atmospherics/I in back_nodes)
|
||||
all_connected[I] = I
|
||||
for(var/obj/machinery/atmospherics/I in nodes)
|
||||
all_connected[I] = I
|
||||
var/list/obj/machinery/atmospherics/returnlist = list()
|
||||
for(var/obj/machinery/atmospherics/A in all_connected)
|
||||
returnlist += all_connected[A]
|
||||
return returnlist
|
||||
return front_nodes + back_nodes + nodes
|
||||
|
||||
/obj/machinery/atmospherics/pipe/layer_manifold/update_icon() //HEAVILY WIP FOR UPDATE ICONS!!
|
||||
layer = (initial(layer) + (PIPING_LAYER_MAX * PIPING_LAYER_LCHANGE)) //This is above everything else.
|
||||
|
||||
@@ -13,6 +13,9 @@
|
||||
|
||||
device_type = TRINARY
|
||||
|
||||
construction_type = /obj/item/pipe/trinary
|
||||
pipe_state = "manifold"
|
||||
|
||||
/obj/machinery/atmospherics/pipe/manifold/SetInitDirections()
|
||||
switch(dir)
|
||||
if(NORTH)
|
||||
@@ -168,4 +171,4 @@
|
||||
layer = GAS_PIPE_VISIBLE_LAYER
|
||||
|
||||
/obj/machinery/atmospherics/pipe/manifold/brown/hidden
|
||||
level = PIPE_HIDDEN_LEVEL
|
||||
level = PIPE_HIDDEN_LEVEL
|
||||
|
||||
@@ -12,6 +12,9 @@
|
||||
|
||||
device_type = QUATERNARY
|
||||
|
||||
construction_type = /obj/item/pipe/quaternary
|
||||
pipe_state = "manifold4w"
|
||||
|
||||
/obj/machinery/atmospherics/pipe/manifold4w/SetInitDirections()
|
||||
initialize_directions = initial(initialize_directions)
|
||||
|
||||
@@ -160,4 +163,4 @@
|
||||
layer = GAS_PIPE_VISIBLE_LAYER
|
||||
|
||||
/obj/machinery/atmospherics/pipe/manifold4w/brown/hidden
|
||||
level = PIPE_HIDDEN_LEVEL
|
||||
level = PIPE_HIDDEN_LEVEL
|
||||
|
||||
@@ -16,6 +16,9 @@ The regular pipe you see everywhere, including bent ones.
|
||||
|
||||
device_type = BINARY
|
||||
|
||||
construction_type = /obj/item/pipe/binary/bendable
|
||||
pipe_state = "simple"
|
||||
|
||||
/obj/machinery/atmospherics/pipe/simple/SetInitDirections()
|
||||
normalize_cardinal_directions()
|
||||
if(dir in GLOB.diagonals)
|
||||
@@ -158,4 +161,4 @@ The regular pipe you see everywhere, including bent ones.
|
||||
layer = GAS_PIPE_VISIBLE_LAYER
|
||||
|
||||
/obj/machinery/atmospherics/pipe/simple/brown/hidden
|
||||
level = PIPE_HIDDEN_LEVEL
|
||||
level = PIPE_HIDDEN_LEVEL
|
||||
|
||||
@@ -43,7 +43,6 @@
|
||||
"n2o" = /obj/machinery/portable_atmospherics/canister/nitrous_oxide,
|
||||
"bz" = /obj/machinery/portable_atmospherics/canister/bz,
|
||||
"air" = /obj/machinery/portable_atmospherics/canister/air,
|
||||
"freon" = /obj/machinery/portable_atmospherics/canister/freon,
|
||||
"water vapor" = /obj/machinery/portable_atmospherics/canister/water_vapor,
|
||||
"caution" = /obj/machinery/portable_atmospherics/canister,
|
||||
)
|
||||
@@ -79,11 +78,6 @@
|
||||
icon_state = "orange"
|
||||
gas_type = /datum/gas/plasma
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/agent_b
|
||||
name = "agent b canister"
|
||||
desc = "Oxygen Agent B. You're not quite sure what it does."
|
||||
gas_type = /datum/gas/oxygen_agent_b
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/bz
|
||||
name = "BZ canister"
|
||||
desc = "BZ, a powerful hallucinogenic nerve agent."
|
||||
@@ -101,12 +95,30 @@
|
||||
desc = "Pre-mixed air."
|
||||
icon_state = "grey"
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/freon
|
||||
name = "freon canister"
|
||||
desc = "Freon. Great for the atmosphere!"
|
||||
icon_state = "freon"
|
||||
gas_type = /datum/gas/freon
|
||||
starter_temp = 120
|
||||
/obj/machinery/portable_atmospherics/canister/tritium
|
||||
name = "tritium canister"
|
||||
desc = "Tritium. Inhalation might cause irradiation."
|
||||
gas_type = /datum/gas/tritium
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/nob
|
||||
name = "hyper-noblium canister"
|
||||
desc = "Hyper-Noblium. More noble than all other gases."
|
||||
gas_type = /datum/gas/hypernoblium
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/browns
|
||||
name = "brown gas canister"
|
||||
desc = "Browns gas. Feels great 'til the acid eats your lungs."
|
||||
gas_type = /datum/gas/brown_gas
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/stimulum
|
||||
name = "stimulum canister"
|
||||
desc = "Stimulum. High energy gas, high energy people."
|
||||
gas_type = /datum/gas/stimulum
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/pluoxium
|
||||
name = "pluoxium canister"
|
||||
desc = "Pluoxium. Like oxygen, but more bang for your buck."
|
||||
gas_type = /datum/gas/pluoxium
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/water_vapor
|
||||
name = "water vapor canister"
|
||||
@@ -115,6 +127,7 @@
|
||||
gas_type = /datum/gas/water_vapor
|
||||
filled = 1
|
||||
|
||||
|
||||
/obj/machinery/portable_atmospherics/canister/proc/get_time_left()
|
||||
if(timing)
|
||||
. = round(max(0, valve_timer - world.time) / 10, 1)
|
||||
@@ -402,7 +415,7 @@
|
||||
var/gas = air_contents.gases[id]
|
||||
if(!gas[GAS_META][META_GAS_DANGER])
|
||||
continue
|
||||
if(gas[MOLES] > (gas[GAS_META][META_GAS_MOLES_VISIBLE] || MOLES_PLASMA_VISIBLE)) //if moles_visible is undefined, default to plasma visibility
|
||||
if(gas[MOLES] > (gas[GAS_META][META_GAS_MOLES_VISIBLE] || MOLES_GAS_VISIBLE)) //if moles_visible is undefined, default to default visibility
|
||||
danger[gas[GAS_META][META_GAS_NAME]] = gas[MOLES] //ex. "plasma" = 20
|
||||
|
||||
if(danger.len)
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
var/volume_rate = 1000
|
||||
volume = 1000
|
||||
|
||||
var/list/scrubbing = list(/datum/gas/plasma, /datum/gas/carbon_dioxide, /datum/gas/nitrous_oxide, /datum/gas/oxygen_agent_b, /datum/gas/bz, /datum/gas/freon, /datum/gas/water_vapor)
|
||||
var/list/scrubbing = list(/datum/gas/plasma, /datum/gas/carbon_dioxide, /datum/gas/nitrous_oxide, /datum/gas/bz, /datum/gas/brown_gas, /datum/gas/tritium, /datum/gas/hypernoblium, /datum/gas/water_vapor)
|
||||
|
||||
/obj/machinery/portable_atmospherics/scrubber/Destroy()
|
||||
var/turf/T = get_turf(src)
|
||||
|
||||
@@ -937,23 +937,6 @@
|
||||
crate_type = /obj/structure/closet/crate/secure/science
|
||||
dangerous = TRUE
|
||||
|
||||
/datum/supply_pack/science/bz_canister
|
||||
name = "BZ Canister"
|
||||
cost = 2000
|
||||
access_any = list(ACCESS_RD, ACCESS_ATMOSPHERICS)
|
||||
contains = list(/obj/machinery/portable_atmospherics/canister/bz)
|
||||
crate_name = "bz canister crate"
|
||||
crate_type = /obj/structure/closet/crate/secure/science
|
||||
dangerous = TRUE
|
||||
|
||||
/datum/supply_pack/science/freon_canister
|
||||
name = "Freon Canister"
|
||||
cost = 6000
|
||||
access_any = list(ACCESS_RD, ACCESS_ATMOSPHERICS)
|
||||
contains = list(/obj/machinery/portable_atmospherics/canister/freon)
|
||||
crate_name = "freon canister crate"
|
||||
crate_type = /obj/structure/closet/crate/secure/science
|
||||
dangerous = TRUE
|
||||
|
||||
/datum/supply_pack/science/research
|
||||
name = "Machine Prototype Crate"
|
||||
|
||||
@@ -4,12 +4,12 @@
|
||||
set category = "OOC"
|
||||
|
||||
if(GLOB.say_disabled) //This is here to try to identify lag problems
|
||||
usr << "<span class='danger'> Speech is currently admin-disabled.</span>"
|
||||
to_chat(usr, "<span class='danger'> Speech is currently admin-disabled.</span>")
|
||||
return
|
||||
|
||||
if(!mob) return
|
||||
if(IsGuestKey(key))
|
||||
src << "Guests may not use OOC."
|
||||
to_chat(src, "Guests may not use OOC.")
|
||||
return
|
||||
|
||||
msg = copytext(sanitize(msg), 1, MAX_MESSAGE_LEN)
|
||||
@@ -17,23 +17,23 @@
|
||||
return
|
||||
|
||||
if(!(prefs.toggles & CHAT_OOC))
|
||||
src << "<span class='danger'> You have OOC muted.</span>"
|
||||
to_chat(src, "<span class='danger'> You have OOC muted.</span>")
|
||||
return
|
||||
|
||||
if(!holder)
|
||||
if(!GLOB.ooc_allowed)
|
||||
src << "<span class='danger'> OOC is globally muted</span>"
|
||||
to_chat(src, "<span class='danger'> OOC is globally muted</span>")
|
||||
return
|
||||
if(!GLOB.dooc_allowed && (mob.stat == DEAD))
|
||||
usr << "<span class='danger'> OOC for dead mobs has been turned off.</span>"
|
||||
to_chat(usr, "<span class='danger'> OOC for dead mobs has been turned off.</span>")
|
||||
return
|
||||
if(prefs.muted & MUTE_OOC)
|
||||
src << "<span class='danger'> You cannot use OOC (muted).</span>"
|
||||
to_chat(src, "<span class='danger'> You cannot use OOC (muted).</span>")
|
||||
return
|
||||
if(handle_spam_prevention(msg,MUTE_OOC))
|
||||
return
|
||||
if(findtext(msg, "byond://"))
|
||||
src << "<B>Advertising other servers is not allowed.</B>"
|
||||
to_chat(src, "<B>Advertising other servers is not allowed.</B>")
|
||||
log_admin("[key_name(src)] has attempted to advertise in LOOC: [msg]")
|
||||
return
|
||||
|
||||
|
||||
@@ -180,23 +180,7 @@
|
||||
damaged_clothes = 0
|
||||
cut_overlay(damaged_clothes_icons[index], TRUE)
|
||||
|
||||
//Glasses
|
||||
/obj/item/clothing/glasses
|
||||
name = "glasses"
|
||||
icon = 'icons/obj/clothing/glasses.dmi'
|
||||
w_class = WEIGHT_CLASS_SMALL
|
||||
flags_cover = GLASSESCOVERSEYES
|
||||
slot_flags = SLOT_EYES
|
||||
var/vision_flags = 0
|
||||
var/darkness_view = 2//Base human is 2
|
||||
var/invis_view = SEE_INVISIBLE_LIVING
|
||||
var/invis_override = 0 //Override to allow glasses to set higher than normal see_invis
|
||||
var/lighting_alpha
|
||||
var/list/icon/current = list() //the current hud icons
|
||||
var/vision_correction = 0 //does wearing these glasses correct some of our vision defects?
|
||||
strip_delay = 20
|
||||
equip_delay_other = 25
|
||||
resistance_flags = 0
|
||||
|
||||
/*
|
||||
SEE_SELF // can see self, no matter what
|
||||
SEE_MOBS // can see all mobs, no matter what
|
||||
@@ -207,455 +191,6 @@ SEE_PIXELS// if an object is located on an unlit area, but some of its pixels ar
|
||||
BLIND // can't see anything
|
||||
*/
|
||||
|
||||
|
||||
//Gloves
|
||||
/obj/item/clothing/gloves
|
||||
name = "gloves"
|
||||
gender = PLURAL //Carn: for grammarically correct text-parsing
|
||||
w_class = WEIGHT_CLASS_SMALL
|
||||
icon = 'icons/obj/clothing/gloves.dmi'
|
||||
siemens_coefficient = 0.5
|
||||
body_parts_covered = HANDS
|
||||
slot_flags = SLOT_GLOVES
|
||||
attack_verb = list("challenged")
|
||||
var/transfer_prints = FALSE
|
||||
strip_delay = 20
|
||||
equip_delay_other = 40
|
||||
|
||||
|
||||
/obj/item/clothing/gloves/worn_overlays(isinhands = FALSE)
|
||||
. = list()
|
||||
if(!isinhands)
|
||||
if(damaged_clothes)
|
||||
. += mutable_appearance('icons/effects/item_damage.dmi', "damagedgloves")
|
||||
if(blood_DNA)
|
||||
. += mutable_appearance('icons/effects/blood.dmi', "bloodyhands")
|
||||
|
||||
/obj/item/clothing/gloves/update_clothes_damaged_state(damaging = TRUE)
|
||||
..()
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_gloves()
|
||||
|
||||
// Called just before an attack_hand(), in mob/UnarmedAttack()
|
||||
/obj/item/clothing/gloves/proc/Touch(atom/A, proximity)
|
||||
return 0 // return 1 to cancel attack_hand()
|
||||
|
||||
//Head
|
||||
/obj/item/clothing/head
|
||||
name = "head"
|
||||
icon = 'icons/obj/clothing/hats.dmi'
|
||||
icon_state = "top_hat"
|
||||
item_state = "that"
|
||||
body_parts_covered = HEAD
|
||||
slot_flags = SLOT_HEAD
|
||||
var/blockTracking = 0 //For AI tracking
|
||||
var/can_toggle = null
|
||||
dynamic_hair_suffix = "+generic"
|
||||
|
||||
/obj/item/clothing/head/Initialize()
|
||||
. = ..()
|
||||
if(ishuman(loc) && dynamic_hair_suffix)
|
||||
var/mob/living/carbon/human/H = loc
|
||||
H.update_hair()
|
||||
|
||||
/obj/item/clothing/head/worn_overlays(isinhands = FALSE)
|
||||
. = list()
|
||||
if(!isinhands)
|
||||
if(damaged_clothes)
|
||||
. += mutable_appearance('icons/effects/item_damage.dmi', "damagedhelmet")
|
||||
if(blood_DNA)
|
||||
. += mutable_appearance('icons/effects/blood.dmi', "helmetblood")
|
||||
|
||||
/obj/item/clothing/head/update_clothes_damaged_state(damaging = TRUE)
|
||||
..()
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_head()
|
||||
|
||||
//Neck
|
||||
/obj/item/clothing/neck
|
||||
name = "necklace"
|
||||
icon = 'icons/obj/clothing/neck.dmi'
|
||||
body_parts_covered = NECK
|
||||
slot_flags = SLOT_NECK
|
||||
strip_delay = 40
|
||||
equip_delay_other = 40
|
||||
|
||||
/obj/item/clothing/neck/worn_overlays(isinhands = FALSE)
|
||||
. = list()
|
||||
if(!isinhands)
|
||||
if(body_parts_covered & HEAD)
|
||||
if(damaged_clothes)
|
||||
. += mutable_appearance('icons/effects/item_damage.dmi', "damagedmask")
|
||||
if(blood_DNA)
|
||||
. += mutable_appearance('icons/effects/blood.dmi', "maskblood")
|
||||
|
||||
|
||||
//Mask
|
||||
/obj/item/clothing/mask
|
||||
name = "mask"
|
||||
icon = 'icons/obj/clothing/masks.dmi'
|
||||
body_parts_covered = HEAD
|
||||
slot_flags = SLOT_MASK
|
||||
strip_delay = 40
|
||||
equip_delay_other = 40
|
||||
var/mask_adjusted = 0
|
||||
var/adjusted_flags = null
|
||||
|
||||
|
||||
/obj/item/clothing/mask/worn_overlays(isinhands = FALSE)
|
||||
. = list()
|
||||
if(!isinhands)
|
||||
if(body_parts_covered & HEAD)
|
||||
if(damaged_clothes)
|
||||
. += mutable_appearance('icons/effects/item_damage.dmi', "damagedmask")
|
||||
if(blood_DNA)
|
||||
. += mutable_appearance('icons/effects/blood.dmi', "maskblood")
|
||||
|
||||
/obj/item/clothing/mask/update_clothes_damaged_state(damaging = TRUE)
|
||||
..()
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_wear_mask()
|
||||
|
||||
//Proc that moves gas/breath masks out of the way, disabling them and allowing pill/food consumption
|
||||
/obj/item/clothing/mask/proc/adjustmask(mob/living/user)
|
||||
if(user && user.incapacitated())
|
||||
return
|
||||
mask_adjusted = !mask_adjusted
|
||||
if(!mask_adjusted)
|
||||
src.icon_state = initial(icon_state)
|
||||
gas_transfer_coefficient = initial(gas_transfer_coefficient)
|
||||
permeability_coefficient = initial(permeability_coefficient)
|
||||
flags_1 |= visor_flags
|
||||
flags_inv |= visor_flags_inv
|
||||
flags_cover |= visor_flags_cover
|
||||
to_chat(user, "<span class='notice'>You push \the [src] back into place.</span>")
|
||||
slot_flags = initial(slot_flags)
|
||||
else
|
||||
icon_state += "_up"
|
||||
to_chat(user, "<span class='notice'>You push \the [src] out of the way.</span>")
|
||||
gas_transfer_coefficient = null
|
||||
permeability_coefficient = null
|
||||
flags_1 &= ~visor_flags
|
||||
flags_inv &= ~visor_flags_inv
|
||||
flags_cover &= ~visor_flags_cover
|
||||
if(adjusted_flags)
|
||||
slot_flags = adjusted_flags
|
||||
if(user)
|
||||
user.wear_mask_update(src, toggle_off = mask_adjusted)
|
||||
user.update_action_buttons_icon() //when mask is adjusted out, we update all buttons icon so the user's potential internal tank correctly shows as off.
|
||||
|
||||
|
||||
|
||||
|
||||
//Shoes
|
||||
/obj/item/clothing/shoes
|
||||
name = "shoes"
|
||||
icon = 'icons/obj/clothing/shoes.dmi'
|
||||
desc = "Comfortable-looking shoes."
|
||||
gender = PLURAL //Carn: for grammarically correct text-parsing
|
||||
var/chained = 0
|
||||
|
||||
body_parts_covered = FEET
|
||||
slot_flags = SLOT_FEET
|
||||
|
||||
permeability_coefficient = 0.5
|
||||
slowdown = SHOES_SLOWDOWN
|
||||
var/blood_state = BLOOD_STATE_NOT_BLOODY
|
||||
var/list/bloody_shoes = list(BLOOD_STATE_HUMAN = 0,BLOOD_STATE_XENO = 0, BLOOD_STATE_OIL = 0, BLOOD_STATE_NOT_BLOODY = 0)
|
||||
var/offset = 0
|
||||
var/equipped_before_drop = FALSE
|
||||
|
||||
/obj/item/clothing/shoes/worn_overlays(isinhands = FALSE)
|
||||
. = list()
|
||||
if(!isinhands)
|
||||
var/bloody = 0
|
||||
if(blood_DNA)
|
||||
bloody = 1
|
||||
else
|
||||
bloody = bloody_shoes[BLOOD_STATE_HUMAN]
|
||||
|
||||
if(damaged_clothes)
|
||||
. += mutable_appearance('icons/effects/item_damage.dmi', "damagedshoe")
|
||||
if(bloody)
|
||||
. += mutable_appearance('icons/effects/blood.dmi', "shoeblood")
|
||||
|
||||
/obj/item/clothing/shoes/equipped(mob/user, slot)
|
||||
. = ..()
|
||||
if(offset && slot_flags & slotdefine2slotbit(slot))
|
||||
user.pixel_y += offset
|
||||
worn_y_dimension -= (offset * 2)
|
||||
user.update_inv_shoes()
|
||||
equipped_before_drop = TRUE
|
||||
|
||||
/obj/item/clothing/shoes/proc/restore_offsets(mob/user)
|
||||
equipped_before_drop = FALSE
|
||||
user.pixel_y -= offset
|
||||
worn_y_dimension = world.icon_size
|
||||
|
||||
/obj/item/clothing/shoes/dropped(mob/user)
|
||||
if(offset && equipped_before_drop)
|
||||
restore_offsets(user)
|
||||
. = ..()
|
||||
|
||||
/obj/item/clothing/shoes/update_clothes_damaged_state(damaging = TRUE)
|
||||
..()
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_shoes()
|
||||
|
||||
/obj/item/clothing/shoes/clean_blood()
|
||||
..()
|
||||
bloody_shoes = list(BLOOD_STATE_HUMAN = 0,BLOOD_STATE_XENO = 0, BLOOD_STATE_OIL = 0, BLOOD_STATE_NOT_BLOODY = 0)
|
||||
blood_state = BLOOD_STATE_NOT_BLOODY
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_shoes()
|
||||
|
||||
/obj/item/proc/negates_gravity()
|
||||
return 0
|
||||
|
||||
//Suit
|
||||
/obj/item/clothing/suit
|
||||
icon = 'icons/obj/clothing/suits.dmi'
|
||||
name = "suit"
|
||||
var/fire_resist = T0C+100
|
||||
allowed = list(/obj/item/tank/internals/emergency_oxygen)
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0, fire = 0, acid = 0)
|
||||
slot_flags = SLOT_OCLOTHING
|
||||
var/blood_overlay_type = "suit"
|
||||
var/togglename = null
|
||||
|
||||
|
||||
/obj/item/clothing/suit/worn_overlays(isinhands = FALSE)
|
||||
. = list()
|
||||
if(!isinhands)
|
||||
if(damaged_clothes)
|
||||
. += mutable_appearance('icons/effects/item_damage.dmi', "damaged[blood_overlay_type]")
|
||||
if(blood_DNA)
|
||||
. += mutable_appearance('icons/effects/blood.dmi', "[blood_overlay_type]blood")
|
||||
var/mob/living/carbon/human/M = loc
|
||||
if(ishuman(M) && M.w_uniform)
|
||||
var/obj/item/clothing/under/U = M.w_uniform
|
||||
if(istype(U) && U.attached_accessory)
|
||||
var/obj/item/clothing/accessory/A = U.attached_accessory
|
||||
if(A.above_suit)
|
||||
. += U.accessory_overlay
|
||||
|
||||
/obj/item/clothing/suit/update_clothes_damaged_state(damaging = TRUE)
|
||||
..()
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_wear_suit()
|
||||
|
||||
//Spacesuit
|
||||
//Note: Everything in modules/clothing/spacesuits should have the entire suit grouped together.
|
||||
// Meaning the the suit is defined directly after the corrisponding helmet. Just like below!
|
||||
/obj/item/clothing/head/helmet/space
|
||||
name = "space helmet"
|
||||
icon_state = "spaceold"
|
||||
desc = "A special helmet with solar UV shielding to protect your eyes from harmful rays."
|
||||
flags_1 = STOPSPRESSUREDMAGE_1 | THICKMATERIAL_1
|
||||
item_state = "spaceold"
|
||||
permeability_coefficient = 0.01
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 100, rad = 50, fire = 80, acid = 70)
|
||||
flags_inv = HIDEMASK|HIDEEARS|HIDEEYES|HIDEFACE|HIDEHAIR|HIDEFACIALHAIR
|
||||
dynamic_hair_suffix = ""
|
||||
dynamic_fhair_suffix = ""
|
||||
cold_protection = HEAD
|
||||
min_cold_protection_temperature = SPACE_HELM_MIN_TEMP_PROTECT
|
||||
heat_protection = HEAD
|
||||
max_heat_protection_temperature = SPACE_HELM_MAX_TEMP_PROTECT
|
||||
flash_protect = 2
|
||||
strip_delay = 50
|
||||
equip_delay_other = 50
|
||||
flags_cover = HEADCOVERSEYES | HEADCOVERSMOUTH
|
||||
resistance_flags = 0
|
||||
dog_fashion = null
|
||||
|
||||
/obj/item/clothing/suit/space
|
||||
name = "space suit"
|
||||
desc = "A suit that protects against low pressure environments. Has a big 13 on the back."
|
||||
icon_state = "spaceold"
|
||||
item_state = "s_suit"
|
||||
w_class = WEIGHT_CLASS_BULKY
|
||||
gas_transfer_coefficient = 0.01
|
||||
permeability_coefficient = 0.02
|
||||
flags_1 = STOPSPRESSUREDMAGE_1 | THICKMATERIAL_1
|
||||
body_parts_covered = CHEST|GROIN|LEGS|FEET|ARMS|HANDS
|
||||
allowed = list(/obj/item/device/flashlight, /obj/item/tank/internals)
|
||||
slowdown = 1
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 100, rad = 50, fire = 80, acid = 70)
|
||||
flags_inv = HIDEGLOVES|HIDESHOES|HIDEJUMPSUIT
|
||||
cold_protection = CHEST | GROIN | LEGS | FEET | ARMS | HANDS
|
||||
min_cold_protection_temperature = SPACE_SUIT_MIN_TEMP_PROTECT
|
||||
heat_protection = CHEST|GROIN|LEGS|FEET|ARMS|HANDS
|
||||
max_heat_protection_temperature = SPACE_SUIT_MAX_TEMP_PROTECT
|
||||
strip_delay = 80
|
||||
equip_delay_other = 80
|
||||
resistance_flags = 0
|
||||
|
||||
//Under clothing
|
||||
|
||||
/obj/item/clothing/under
|
||||
icon = 'icons/obj/clothing/uniforms.dmi'
|
||||
name = "under"
|
||||
body_parts_covered = CHEST|GROIN|LEGS|ARMS
|
||||
permeability_coefficient = 0.9
|
||||
slot_flags = SLOT_ICLOTHING
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0, fire = 0, acid = 0)
|
||||
var/fitted = FEMALE_UNIFORM_FULL // For use in alternate clothing styles for women
|
||||
var/has_sensor = HAS_SENSORS // For the crew computer
|
||||
var/random_sensor = 1
|
||||
var/sensor_mode = NO_SENSORS
|
||||
var/can_adjust = 1
|
||||
var/adjusted = NORMAL_STYLE
|
||||
var/alt_covers_chest = 0 // for adjusted/rolled-down jumpsuits, 0 = exposes chest and arms, 1 = exposes arms only
|
||||
var/obj/item/clothing/accessory/attached_accessory
|
||||
var/mutable_appearance/accessory_overlay
|
||||
var/mutantrace_variation = NO_MUTANTRACE_VARIATION //Are there special sprites for specific situations? Don't use this unless you need to.
|
||||
|
||||
/obj/item/clothing/under/worn_overlays(isinhands = FALSE)
|
||||
. = list()
|
||||
if(!isinhands)
|
||||
|
||||
if(damaged_clothes)
|
||||
. += mutable_appearance('icons/effects/item_damage.dmi', "damageduniform")
|
||||
if(blood_DNA)
|
||||
. += mutable_appearance('icons/effects/blood.dmi', "uniformblood")
|
||||
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))
|
||||
var/obj/item/stack/cable_coil/C = I
|
||||
C.use(1)
|
||||
has_sensor = HAS_SENSORS
|
||||
to_chat(user,"<span class='notice'>You repair the suit sensors on [src] with [C].</span>")
|
||||
return 1
|
||||
if(!attach_accessory(I, user))
|
||||
return ..()
|
||||
|
||||
/obj/item/clothing/under/update_clothes_damaged_state(damaging = TRUE)
|
||||
..()
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_w_uniform()
|
||||
if(has_sensor > NO_SENSORS)
|
||||
has_sensor = BROKEN_SENSORS
|
||||
|
||||
/obj/item/clothing/under/New()
|
||||
if(random_sensor)
|
||||
//make the sensor mode favor higher levels, except coords.
|
||||
sensor_mode = pick(SENSOR_OFF, SENSOR_LIVING, SENSOR_LIVING, SENSOR_VITALS, SENSOR_VITALS, SENSOR_VITALS, SENSOR_COORDS, SENSOR_COORDS)
|
||||
adjusted = NORMAL_STYLE
|
||||
..()
|
||||
|
||||
/obj/item/clothing/under/equipped(mob/user, slot)
|
||||
..()
|
||||
if(adjusted)
|
||||
adjusted = NORMAL_STYLE
|
||||
fitted = initial(fitted)
|
||||
if(!alt_covers_chest)
|
||||
body_parts_covered |= CHEST
|
||||
|
||||
if(mutantrace_variation && ishuman(user))
|
||||
var/mob/living/carbon/human/H = user
|
||||
if(DIGITIGRADE in H.dna.species.species_traits)
|
||||
adjusted = DIGITIGRADE_STYLE
|
||||
H.update_inv_w_uniform()
|
||||
|
||||
if(attached_accessory && slot != slot_hands && ishuman(user))
|
||||
var/mob/living/carbon/human/H = user
|
||||
attached_accessory.on_uniform_equip(src, user)
|
||||
if(attached_accessory.above_suit)
|
||||
H.update_inv_wear_suit()
|
||||
|
||||
/obj/item/clothing/under/dropped(mob/user)
|
||||
if(attached_accessory)
|
||||
attached_accessory.on_uniform_dropped(src, user)
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/H = user
|
||||
if(attached_accessory.above_suit)
|
||||
H.update_inv_wear_suit()
|
||||
|
||||
..()
|
||||
|
||||
/obj/item/clothing/under/proc/attach_accessory(obj/item/I, mob/user, notifyAttach = 1)
|
||||
. = FALSE
|
||||
if(istype(I, /obj/item/clothing/accessory))
|
||||
var/obj/item/clothing/accessory/A = I
|
||||
if(attached_accessory)
|
||||
if(user)
|
||||
to_chat(user, "<span class='warning'>[src] already has an accessory.</span>")
|
||||
return
|
||||
else
|
||||
if(user && !user.temporarilyRemoveItemFromInventory(I))
|
||||
return
|
||||
if(!A.attach(src, user))
|
||||
return
|
||||
|
||||
if(user && notifyAttach)
|
||||
to_chat(user, "<span class='notice'>You attach [I] to [src].</span>")
|
||||
|
||||
var/accessory_color = attached_accessory.item_color
|
||||
if(!accessory_color)
|
||||
accessory_color = attached_accessory.icon_state
|
||||
accessory_overlay = mutable_appearance('icons/mob/accessories.dmi', "[accessory_color]")
|
||||
accessory_overlay.alpha = attached_accessory.alpha
|
||||
accessory_overlay.color = attached_accessory.color
|
||||
|
||||
if(ishuman(loc))
|
||||
var/mob/living/carbon/human/H = loc
|
||||
H.update_inv_w_uniform()
|
||||
H.update_inv_wear_suit()
|
||||
|
||||
return TRUE
|
||||
|
||||
/obj/item/clothing/under/proc/remove_accessory(mob/user)
|
||||
if(!isliving(user))
|
||||
return
|
||||
if(!can_use(user))
|
||||
return
|
||||
|
||||
if(attached_accessory)
|
||||
var/obj/item/clothing/accessory/A = attached_accessory
|
||||
attached_accessory.detach(src, user)
|
||||
if(user.put_in_hands(A))
|
||||
to_chat(user, "<span class='notice'>You detach [A] from [src].</span>")
|
||||
else
|
||||
to_chat(user, "<span class='notice'>You detach [A] from [src] and it falls on the floor.</span>")
|
||||
|
||||
if(ishuman(loc))
|
||||
var/mob/living/carbon/human/H = loc
|
||||
H.update_inv_w_uniform()
|
||||
H.update_inv_wear_suit()
|
||||
|
||||
|
||||
/obj/item/clothing/under/examine(mob/user)
|
||||
..()
|
||||
if(can_adjust)
|
||||
if(adjusted == ALT_STYLE)
|
||||
to_chat(user, "Alt-click on [src] to wear it normally.")
|
||||
else
|
||||
to_chat(user, "Alt-click on [src] to wear it casually.")
|
||||
if (has_sensor == BROKEN_SENSORS)
|
||||
to_chat(user, "Its sensors appear to be shorted out.")
|
||||
else if(has_sensor > NO_SENSORS)
|
||||
switch(sensor_mode)
|
||||
if(SENSOR_OFF)
|
||||
to_chat(user, "Its sensors appear to be disabled.")
|
||||
if(SENSOR_LIVING)
|
||||
to_chat(user, "Its binary life sensors appear to be enabled.")
|
||||
if(SENSOR_VITALS)
|
||||
to_chat(user, "Its vital tracker appears to be enabled.")
|
||||
if(SENSOR_COORDS)
|
||||
to_chat(user, "Its vital tracker and tracking beacon appear to be enabled.")
|
||||
if(attached_accessory)
|
||||
to_chat(user, "\A [attached_accessory] is attached to it.")
|
||||
|
||||
/proc/generate_female_clothing(index,t_color,icon,type)
|
||||
var/icon/female_clothing_icon = icon("icon"=icon, "icon_state"=t_color)
|
||||
var/icon/female_s = icon("icon"='icons/mob/uniform.dmi', "icon_state"="[(type == FEMALE_UNIFORM_FULL) ? "female_full" : "female_top"]")
|
||||
@@ -799,4 +334,4 @@ BLIND // can't see anything
|
||||
Shreds.desc = "The sad remains of what used to be [name]."
|
||||
deconstruct(FALSE)
|
||||
else
|
||||
..()
|
||||
..()
|
||||
+16
-1
@@ -1,7 +1,22 @@
|
||||
//Glasses
|
||||
/obj/item/clothing/glasses
|
||||
name = "glasses"
|
||||
icon = 'icons/obj/clothing/glasses.dmi'
|
||||
w_class = WEIGHT_CLASS_SMALL
|
||||
flags_cover = GLASSESCOVERSEYES
|
||||
slot_flags = SLOT_EYES
|
||||
strip_delay = 20
|
||||
equip_delay_other = 25
|
||||
resistance_flags = 0
|
||||
materials = list(MAT_GLASS = 250)
|
||||
var/glass_colour_type = null //colors your vision when worn
|
||||
var/vision_flags = 0
|
||||
var/darkness_view = 2//Base human is 2
|
||||
var/invis_view = SEE_INVISIBLE_LIVING
|
||||
var/invis_override = 0 //Override to allow glasses to set higher than normal see_invis
|
||||
var/lighting_alpha
|
||||
var/list/icon/current = list() //the current hud icons
|
||||
var/vision_correction = 0 //does wearing these glasses correct some of our vision defects?
|
||||
var/glass_colour_type //colors your vision when worn
|
||||
|
||||
/obj/item/clothing/glasses/examine(mob/user)
|
||||
..()
|
||||
@@ -0,0 +1,31 @@
|
||||
/obj/item/clothing/gloves
|
||||
name = "gloves"
|
||||
gender = PLURAL //Carn: for grammarically correct text-parsing
|
||||
w_class = WEIGHT_CLASS_SMALL
|
||||
icon = 'icons/obj/clothing/gloves.dmi'
|
||||
siemens_coefficient = 0.5
|
||||
body_parts_covered = HANDS
|
||||
slot_flags = SLOT_GLOVES
|
||||
attack_verb = list("challenged")
|
||||
var/transfer_prints = FALSE
|
||||
strip_delay = 20
|
||||
equip_delay_other = 40
|
||||
|
||||
|
||||
/obj/item/clothing/gloves/worn_overlays(isinhands = FALSE)
|
||||
. = list()
|
||||
if(!isinhands)
|
||||
if(damaged_clothes)
|
||||
. += mutable_appearance('icons/effects/item_damage.dmi', "damagedgloves")
|
||||
if(blood_DNA)
|
||||
. += mutable_appearance('icons/effects/blood.dmi', "bloodyhands")
|
||||
|
||||
/obj/item/clothing/gloves/update_clothes_damaged_state(damaging = TRUE)
|
||||
..()
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_gloves()
|
||||
|
||||
// Called just before an attack_hand(), in mob/UnarmedAttack()
|
||||
/obj/item/clothing/gloves/proc/Touch(atom/A, proximity)
|
||||
return 0 // return 1 to cancel attack_hand()
|
||||
@@ -0,0 +1,30 @@
|
||||
/obj/item/clothing/head
|
||||
name = "head"
|
||||
icon = 'icons/obj/clothing/hats.dmi'
|
||||
icon_state = "top_hat"
|
||||
item_state = "that"
|
||||
body_parts_covered = HEAD
|
||||
slot_flags = SLOT_HEAD
|
||||
var/blockTracking = 0 //For AI tracking
|
||||
var/can_toggle = null
|
||||
dynamic_hair_suffix = "+generic"
|
||||
|
||||
/obj/item/clothing/head/Initialize()
|
||||
. = ..()
|
||||
if(ishuman(loc) && dynamic_hair_suffix)
|
||||
var/mob/living/carbon/human/H = loc
|
||||
H.update_hair()
|
||||
|
||||
/obj/item/clothing/head/worn_overlays(isinhands = FALSE)
|
||||
. = list()
|
||||
if(!isinhands)
|
||||
if(damaged_clothes)
|
||||
. += mutable_appearance('icons/effects/item_damage.dmi', "damagedhelmet")
|
||||
if(blood_DNA)
|
||||
. += mutable_appearance('icons/effects/blood.dmi', "helmetblood")
|
||||
|
||||
/obj/item/clothing/head/update_clothes_damaged_state(damaging = TRUE)
|
||||
..()
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_head()
|
||||
@@ -0,0 +1,53 @@
|
||||
/obj/item/clothing/mask
|
||||
name = "mask"
|
||||
icon = 'icons/obj/clothing/masks.dmi'
|
||||
body_parts_covered = HEAD
|
||||
slot_flags = SLOT_MASK
|
||||
strip_delay = 40
|
||||
equip_delay_other = 40
|
||||
var/mask_adjusted = 0
|
||||
var/adjusted_flags = null
|
||||
|
||||
|
||||
/obj/item/clothing/mask/worn_overlays(isinhands = FALSE)
|
||||
. = list()
|
||||
if(!isinhands)
|
||||
if(body_parts_covered & HEAD)
|
||||
if(damaged_clothes)
|
||||
. += mutable_appearance('icons/effects/item_damage.dmi', "damagedmask")
|
||||
if(blood_DNA)
|
||||
. += mutable_appearance('icons/effects/blood.dmi', "maskblood")
|
||||
|
||||
/obj/item/clothing/mask/update_clothes_damaged_state(damaging = TRUE)
|
||||
..()
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_wear_mask()
|
||||
|
||||
//Proc that moves gas/breath masks out of the way, disabling them and allowing pill/food consumption
|
||||
/obj/item/clothing/mask/proc/adjustmask(mob/living/user)
|
||||
if(user && user.incapacitated())
|
||||
return
|
||||
mask_adjusted = !mask_adjusted
|
||||
if(!mask_adjusted)
|
||||
src.icon_state = initial(icon_state)
|
||||
gas_transfer_coefficient = initial(gas_transfer_coefficient)
|
||||
permeability_coefficient = initial(permeability_coefficient)
|
||||
flags_1 |= visor_flags
|
||||
flags_inv |= visor_flags_inv
|
||||
flags_cover |= visor_flags_cover
|
||||
to_chat(user, "<span class='notice'>You push \the [src] back into place.</span>")
|
||||
slot_flags = initial(slot_flags)
|
||||
else
|
||||
icon_state += "_up"
|
||||
to_chat(user, "<span class='notice'>You push \the [src] out of the way.</span>")
|
||||
gas_transfer_coefficient = null
|
||||
permeability_coefficient = null
|
||||
flags_1 &= ~visor_flags
|
||||
flags_inv &= ~visor_flags_inv
|
||||
flags_cover &= ~visor_flags_cover
|
||||
if(adjusted_flags)
|
||||
slot_flags = adjusted_flags
|
||||
if(user)
|
||||
user.wear_mask_update(src, toggle_off = mask_adjusted)
|
||||
user.update_action_buttons_icon() //when mask is adjusted out, we update all buttons icon so the user's potential internal tank correctly shows as off.
|
||||
@@ -0,0 +1,65 @@
|
||||
/obj/item/clothing/shoes
|
||||
name = "shoes"
|
||||
icon = 'icons/obj/clothing/shoes.dmi'
|
||||
desc = "Comfortable-looking shoes."
|
||||
gender = PLURAL //Carn: for grammarically correct text-parsing
|
||||
var/chained = 0
|
||||
|
||||
body_parts_covered = FEET
|
||||
slot_flags = SLOT_FEET
|
||||
|
||||
permeability_coefficient = 0.5
|
||||
slowdown = SHOES_SLOWDOWN
|
||||
var/blood_state = BLOOD_STATE_NOT_BLOODY
|
||||
var/list/bloody_shoes = list(BLOOD_STATE_HUMAN = 0,BLOOD_STATE_XENO = 0, BLOOD_STATE_OIL = 0, BLOOD_STATE_NOT_BLOODY = 0)
|
||||
var/offset = 0
|
||||
var/equipped_before_drop = FALSE
|
||||
|
||||
/obj/item/clothing/shoes/worn_overlays(isinhands = FALSE)
|
||||
. = list()
|
||||
if(!isinhands)
|
||||
var/bloody = 0
|
||||
if(blood_DNA)
|
||||
bloody = 1
|
||||
else
|
||||
bloody = bloody_shoes[BLOOD_STATE_HUMAN]
|
||||
|
||||
if(damaged_clothes)
|
||||
. += mutable_appearance('icons/effects/item_damage.dmi', "damagedshoe")
|
||||
if(bloody)
|
||||
. += mutable_appearance('icons/effects/blood.dmi', "shoeblood")
|
||||
|
||||
/obj/item/clothing/shoes/equipped(mob/user, slot)
|
||||
. = ..()
|
||||
if(offset && slot_flags & slotdefine2slotbit(slot))
|
||||
user.pixel_y += offset
|
||||
worn_y_dimension -= (offset * 2)
|
||||
user.update_inv_shoes()
|
||||
equipped_before_drop = TRUE
|
||||
|
||||
/obj/item/clothing/shoes/proc/restore_offsets(mob/user)
|
||||
equipped_before_drop = FALSE
|
||||
user.pixel_y -= offset
|
||||
worn_y_dimension = world.icon_size
|
||||
|
||||
/obj/item/clothing/shoes/dropped(mob/user)
|
||||
if(offset && equipped_before_drop)
|
||||
restore_offsets(user)
|
||||
. = ..()
|
||||
|
||||
/obj/item/clothing/shoes/update_clothes_damaged_state(damaging = TRUE)
|
||||
..()
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_shoes()
|
||||
|
||||
/obj/item/clothing/shoes/clean_blood()
|
||||
..()
|
||||
bloody_shoes = list(BLOOD_STATE_HUMAN = 0,BLOOD_STATE_XENO = 0, BLOOD_STATE_OIL = 0, BLOOD_STATE_NOT_BLOODY = 0)
|
||||
blood_state = BLOOD_STATE_NOT_BLOODY
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_shoes()
|
||||
|
||||
/obj/item/proc/negates_gravity()
|
||||
return 0
|
||||
@@ -0,0 +1,45 @@
|
||||
//Note: Everything in modules/clothing/spacesuits should have the entire suit grouped together.
|
||||
// Meaning the the suit is defined directly after the corrisponding helmet. Just like below!
|
||||
/obj/item/clothing/head/helmet/space
|
||||
name = "space helmet"
|
||||
icon_state = "spaceold"
|
||||
desc = "A special helmet with solar UV shielding to protect your eyes from harmful rays."
|
||||
flags_1 = STOPSPRESSUREDMAGE_1 | THICKMATERIAL_1
|
||||
item_state = "spaceold"
|
||||
permeability_coefficient = 0.01
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 100, rad = 50, fire = 80, acid = 70)
|
||||
flags_inv = HIDEMASK|HIDEEARS|HIDEEYES|HIDEFACE|HIDEHAIR|HIDEFACIALHAIR
|
||||
dynamic_hair_suffix = ""
|
||||
dynamic_fhair_suffix = ""
|
||||
cold_protection = HEAD
|
||||
min_cold_protection_temperature = SPACE_HELM_MIN_TEMP_PROTECT
|
||||
heat_protection = HEAD
|
||||
max_heat_protection_temperature = SPACE_HELM_MAX_TEMP_PROTECT
|
||||
flash_protect = 2
|
||||
strip_delay = 50
|
||||
equip_delay_other = 50
|
||||
flags_cover = HEADCOVERSEYES | HEADCOVERSMOUTH
|
||||
resistance_flags = 0
|
||||
dog_fashion = null
|
||||
|
||||
/obj/item/clothing/suit/space
|
||||
name = "space suit"
|
||||
desc = "A suit that protects against low pressure environments. Has a big 13 on the back."
|
||||
icon_state = "spaceold"
|
||||
item_state = "s_suit"
|
||||
w_class = WEIGHT_CLASS_BULKY
|
||||
gas_transfer_coefficient = 0.01
|
||||
permeability_coefficient = 0.02
|
||||
flags_1 = STOPSPRESSUREDMAGE_1 | THICKMATERIAL_1
|
||||
body_parts_covered = CHEST|GROIN|LEGS|FEET|ARMS|HANDS
|
||||
allowed = list(/obj/item/device/flashlight, /obj/item/tank/internals)
|
||||
slowdown = 1
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 100, rad = 50, fire = 80, acid = 70)
|
||||
flags_inv = HIDEGLOVES|HIDESHOES|HIDEJUMPSUIT
|
||||
cold_protection = CHEST | GROIN | LEGS | FEET | ARMS | HANDS
|
||||
min_cold_protection_temperature = SPACE_SUIT_MIN_TEMP_PROTECT
|
||||
heat_protection = CHEST|GROIN|LEGS|FEET|ARMS|HANDS
|
||||
max_heat_protection_temperature = SPACE_SUIT_MAX_TEMP_PROTECT
|
||||
strip_delay = 80
|
||||
equip_delay_other = 80
|
||||
resistance_flags = 0
|
||||
@@ -394,7 +394,7 @@
|
||||
item_state = "medical_helm"
|
||||
item_color = "medical"
|
||||
flash_protect = 0
|
||||
armor = list(melee = 30, bullet = 5, laser = 10, energy = 5, bomb = 10, bio = 100, rad = 50, fire = 75, acid = 75)
|
||||
armor = list(melee = 30, bullet = 5, laser = 10, energy = 5, bomb = 10, bio = 100, rad = 75, fire = 75, acid = 75)
|
||||
scan_reagents = 1
|
||||
|
||||
/obj/item/clothing/suit/space/hardsuit/medical
|
||||
@@ -403,7 +403,7 @@
|
||||
desc = "A special suit that protects against hazardous, low pressure environments. Built with lightweight materials for easier movement."
|
||||
item_state = "medical_hardsuit"
|
||||
allowed = list(/obj/item/device/flashlight, /obj/item/tank/internals, /obj/item/storage/firstaid, /obj/item/device/healthanalyzer, /obj/item/stack/medical)
|
||||
armor = list(melee = 30, bullet = 5, laser = 10, energy = 5, bomb = 10, bio = 100, rad = 50, fire = 75, acid = 75)
|
||||
armor = list(melee = 30, bullet = 5, laser = 10, energy = 5, bomb = 10, bio = 100, rad = 75, fire = 75, acid = 75)
|
||||
helmettype = /obj/item/clothing/head/helmet/space/hardsuit/medical
|
||||
|
||||
//Research Director hardsuit
|
||||
|
||||
@@ -0,0 +1,31 @@
|
||||
/obj/item/clothing/suit
|
||||
icon = 'icons/obj/clothing/suits.dmi'
|
||||
name = "suit"
|
||||
var/fire_resist = T0C+100
|
||||
allowed = list(/obj/item/tank/internals/emergency_oxygen)
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0, fire = 0, acid = 0)
|
||||
slot_flags = SLOT_OCLOTHING
|
||||
var/blood_overlay_type = "suit"
|
||||
var/togglename = null
|
||||
|
||||
|
||||
/obj/item/clothing/suit/worn_overlays(isinhands = FALSE)
|
||||
. = list()
|
||||
if(!isinhands)
|
||||
if(damaged_clothes)
|
||||
. += mutable_appearance('icons/effects/item_damage.dmi', "damaged[blood_overlay_type]")
|
||||
if(blood_DNA)
|
||||
. += mutable_appearance('icons/effects/blood.dmi', "[blood_overlay_type]blood")
|
||||
var/mob/living/carbon/human/M = loc
|
||||
if(ishuman(M) && M.w_uniform)
|
||||
var/obj/item/clothing/under/U = M.w_uniform
|
||||
if(istype(U) && U.attached_accessory)
|
||||
var/obj/item/clothing/accessory/A = U.attached_accessory
|
||||
if(A.above_suit)
|
||||
. += U.accessory_overlay
|
||||
|
||||
/obj/item/clothing/suit/update_clothes_damaged_state(damaging = TRUE)
|
||||
..()
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_wear_suit()
|
||||
@@ -5,7 +5,7 @@
|
||||
desc = "A hood that protects the head and face from biological comtaminants."
|
||||
permeability_coefficient = 0.01
|
||||
flags_1 = THICKMATERIAL_1
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 100, rad = 20, fire = 30, acid = 100)
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 100, rad = 80, fire = 30, acid = 100)
|
||||
flags_inv = HIDEMASK|HIDEEARS|HIDEEYES|HIDEHAIR|HIDEFACIALHAIR|HIDEFACE
|
||||
resistance_flags = ACID_PROOF
|
||||
flags_cover = HEADCOVERSEYES | HEADCOVERSMOUTH
|
||||
@@ -22,7 +22,7 @@
|
||||
body_parts_covered = CHEST|GROIN|LEGS|FEET|ARMS|HANDS
|
||||
slowdown = 1
|
||||
allowed = list(/obj/item/tank/internals/emergency_oxygen, /obj/item/pen, /obj/item/device/flashlight/pen, /obj/item/reagent_containers/dropper, /obj/item/reagent_containers/syringe, /obj/item/reagent_containers/hypospray)
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 100, rad = 20, fire = 30, acid = 100)
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 100, rad = 80, fire = 30, acid = 100)
|
||||
flags_inv = HIDEGLOVES|HIDESHOES|HIDEJUMPSUIT
|
||||
strip_delay = 70
|
||||
equip_delay_other = 70
|
||||
@@ -46,11 +46,11 @@
|
||||
|
||||
//Security biosuit, grey with red stripe across the chest
|
||||
/obj/item/clothing/head/bio_hood/security
|
||||
armor = list(melee = 25, bullet = 15, laser = 25, energy = 10, bomb = 25, bio = 100, rad = 20, fire = 30, acid = 100)
|
||||
armor = list(melee = 25, bullet = 15, laser = 25, energy = 10, bomb = 25, bio = 100, rad = 80, fire = 30, acid = 100)
|
||||
icon_state = "bio_security"
|
||||
|
||||
/obj/item/clothing/suit/bio_suit/security
|
||||
armor = list(melee = 25, bullet = 15, laser = 25, energy = 10, bomb = 25, bio = 100, rad = 20, fire = 30, acid = 100)
|
||||
armor = list(melee = 25, bullet = 15, laser = 25, energy = 10, bomb = 25, bio = 100, rad = 80, fire = 30, acid = 100)
|
||||
icon_state = "bio_security"
|
||||
|
||||
|
||||
|
||||
@@ -0,0 +1,156 @@
|
||||
/obj/item/clothing/under
|
||||
icon = 'icons/obj/clothing/uniforms.dmi'
|
||||
name = "under"
|
||||
body_parts_covered = CHEST|GROIN|LEGS|ARMS
|
||||
permeability_coefficient = 0.9
|
||||
slot_flags = SLOT_ICLOTHING
|
||||
armor = list(melee = 0, bullet = 0, laser = 0,energy = 0, bomb = 0, bio = 0, rad = 0, fire = 0, acid = 0)
|
||||
var/fitted = FEMALE_UNIFORM_FULL // For use in alternate clothing styles for women
|
||||
var/has_sensor = HAS_SENSORS // For the crew computer
|
||||
var/random_sensor = 1
|
||||
var/sensor_mode = NO_SENSORS
|
||||
var/can_adjust = 1
|
||||
var/adjusted = NORMAL_STYLE
|
||||
var/alt_covers_chest = 0 // for adjusted/rolled-down jumpsuits, 0 = exposes chest and arms, 1 = exposes arms only
|
||||
var/obj/item/clothing/accessory/attached_accessory
|
||||
var/mutable_appearance/accessory_overlay
|
||||
var/mutantrace_variation = NO_MUTANTRACE_VARIATION //Are there special sprites for specific situations? Don't use this unless you need to.
|
||||
|
||||
/obj/item/clothing/under/worn_overlays(isinhands = FALSE)
|
||||
. = list()
|
||||
if(!isinhands)
|
||||
|
||||
if(damaged_clothes)
|
||||
. += mutable_appearance('icons/effects/item_damage.dmi', "damageduniform")
|
||||
if(blood_DNA)
|
||||
. += mutable_appearance('icons/effects/blood.dmi', "uniformblood")
|
||||
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))
|
||||
var/obj/item/stack/cable_coil/C = I
|
||||
C.use(1)
|
||||
has_sensor = HAS_SENSORS
|
||||
to_chat(user,"<span class='notice'>You repair the suit sensors on [src] with [C].</span>")
|
||||
return 1
|
||||
if(!attach_accessory(I, user))
|
||||
return ..()
|
||||
|
||||
/obj/item/clothing/under/update_clothes_damaged_state(damaging = TRUE)
|
||||
..()
|
||||
if(ismob(loc))
|
||||
var/mob/M = loc
|
||||
M.update_inv_w_uniform()
|
||||
if(has_sensor > NO_SENSORS)
|
||||
has_sensor = BROKEN_SENSORS
|
||||
|
||||
/obj/item/clothing/under/New()
|
||||
if(random_sensor)
|
||||
//make the sensor mode favor higher levels, except coords.
|
||||
sensor_mode = pick(SENSOR_OFF, SENSOR_LIVING, SENSOR_LIVING, SENSOR_VITALS, SENSOR_VITALS, SENSOR_VITALS, SENSOR_COORDS, SENSOR_COORDS)
|
||||
adjusted = NORMAL_STYLE
|
||||
..()
|
||||
|
||||
/obj/item/clothing/under/equipped(mob/user, slot)
|
||||
..()
|
||||
if(adjusted)
|
||||
adjusted = NORMAL_STYLE
|
||||
fitted = initial(fitted)
|
||||
if(!alt_covers_chest)
|
||||
body_parts_covered |= CHEST
|
||||
|
||||
if(mutantrace_variation && ishuman(user))
|
||||
var/mob/living/carbon/human/H = user
|
||||
if(DIGITIGRADE in H.dna.species.species_traits)
|
||||
adjusted = DIGITIGRADE_STYLE
|
||||
H.update_inv_w_uniform()
|
||||
|
||||
if(attached_accessory && slot != slot_hands && ishuman(user))
|
||||
var/mob/living/carbon/human/H = user
|
||||
attached_accessory.on_uniform_equip(src, user)
|
||||
if(attached_accessory.above_suit)
|
||||
H.update_inv_wear_suit()
|
||||
|
||||
/obj/item/clothing/under/dropped(mob/user)
|
||||
if(attached_accessory)
|
||||
attached_accessory.on_uniform_dropped(src, user)
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/H = user
|
||||
if(attached_accessory.above_suit)
|
||||
H.update_inv_wear_suit()
|
||||
|
||||
..()
|
||||
|
||||
/obj/item/clothing/under/proc/attach_accessory(obj/item/I, mob/user, notifyAttach = 1)
|
||||
. = FALSE
|
||||
if(istype(I, /obj/item/clothing/accessory))
|
||||
var/obj/item/clothing/accessory/A = I
|
||||
if(attached_accessory)
|
||||
if(user)
|
||||
to_chat(user, "<span class='warning'>[src] already has an accessory.</span>")
|
||||
return
|
||||
else
|
||||
if(user && !user.temporarilyRemoveItemFromInventory(I))
|
||||
return
|
||||
if(!A.attach(src, user))
|
||||
return
|
||||
|
||||
if(user && notifyAttach)
|
||||
to_chat(user, "<span class='notice'>You attach [I] to [src].</span>")
|
||||
|
||||
var/accessory_color = attached_accessory.item_color
|
||||
if(!accessory_color)
|
||||
accessory_color = attached_accessory.icon_state
|
||||
accessory_overlay = mutable_appearance('icons/mob/accessories.dmi', "[accessory_color]")
|
||||
accessory_overlay.alpha = attached_accessory.alpha
|
||||
accessory_overlay.color = attached_accessory.color
|
||||
|
||||
if(ishuman(loc))
|
||||
var/mob/living/carbon/human/H = loc
|
||||
H.update_inv_w_uniform()
|
||||
H.update_inv_wear_suit()
|
||||
|
||||
return TRUE
|
||||
|
||||
/obj/item/clothing/under/proc/remove_accessory(mob/user)
|
||||
if(!isliving(user))
|
||||
return
|
||||
if(!can_use(user))
|
||||
return
|
||||
|
||||
if(attached_accessory)
|
||||
var/obj/item/clothing/accessory/A = attached_accessory
|
||||
attached_accessory.detach(src, user)
|
||||
if(user.put_in_hands(A))
|
||||
to_chat(user, "<span class='notice'>You detach [A] from [src].</span>")
|
||||
else
|
||||
to_chat(user, "<span class='notice'>You detach [A] from [src] and it falls on the floor.</span>")
|
||||
|
||||
if(ishuman(loc))
|
||||
var/mob/living/carbon/human/H = loc
|
||||
H.update_inv_w_uniform()
|
||||
H.update_inv_wear_suit()
|
||||
|
||||
|
||||
/obj/item/clothing/under/examine(mob/user)
|
||||
..()
|
||||
if(can_adjust)
|
||||
if(adjusted == ALT_STYLE)
|
||||
to_chat(user, "Alt-click on [src] to wear it normally.")
|
||||
else
|
||||
to_chat(user, "Alt-click on [src] to wear it casually.")
|
||||
if (has_sensor == BROKEN_SENSORS)
|
||||
to_chat(user, "Its sensors appear to be shorted out.")
|
||||
else if(has_sensor > NO_SENSORS)
|
||||
switch(sensor_mode)
|
||||
if(SENSOR_OFF)
|
||||
to_chat(user, "Its sensors appear to be disabled.")
|
||||
if(SENSOR_LIVING)
|
||||
to_chat(user, "Its binary life sensors appear to be enabled.")
|
||||
if(SENSOR_VITALS)
|
||||
to_chat(user, "Its vital tracker appears to be enabled.")
|
||||
if(SENSOR_COORDS)
|
||||
to_chat(user, "Its vital tracker and tracking beacon appear to be enabled.")
|
||||
if(attached_accessory)
|
||||
to_chat(user, "\A [attached_accessory] is attached to it.")
|
||||
@@ -99,6 +99,10 @@
|
||||
|
||||
return E
|
||||
|
||||
//Special admins setup
|
||||
/datum/round_event_control/proc/admin_setup()
|
||||
return
|
||||
|
||||
/datum/round_event //NOTE: Times are measured in master controller ticks!
|
||||
var/processing = TRUE
|
||||
var/datum/round_event_control/control
|
||||
|
||||
+29
-38
@@ -1,38 +1,29 @@
|
||||
/datum/round_event_control/blob
|
||||
name = "Blob"
|
||||
typepath = /datum/round_event/ghost_role/blob
|
||||
weight = 5
|
||||
max_occurrences = 1
|
||||
|
||||
min_players = 20
|
||||
earliest_start = 18000 //30 minutes
|
||||
|
||||
gamemode_blacklist = list("blob") //Just in case a blob survives that long
|
||||
|
||||
/datum/round_event/ghost_role/blob
|
||||
announceWhen = 12
|
||||
role_name = "blob overmind"
|
||||
var/new_rate = 2
|
||||
|
||||
/datum/round_event/ghost_role/blob/New(my_processing = TRUE, set_point_rate)
|
||||
..()
|
||||
if(set_point_rate)
|
||||
new_rate = set_point_rate
|
||||
|
||||
/datum/round_event/ghost_role/blob/announce()
|
||||
priority_announce("Confirmed outbreak of level 5 biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", 'sound/ai/outbreak5.ogg')
|
||||
|
||||
|
||||
/datum/round_event/ghost_role/blob/spawn_role()
|
||||
if(!GLOB.blobstart.len)
|
||||
return MAP_ERROR
|
||||
var/list/candidates = get_candidates("blob", null, ROLE_BLOB)
|
||||
if(!candidates.len)
|
||||
return NOT_ENOUGH_PLAYERS
|
||||
var/mob/dead/observer/new_blob = pick(candidates)
|
||||
var/obj/structure/blob/core/BC = new/obj/structure/blob/core(pick(GLOB.blobstart), new_blob.client, new_rate)
|
||||
BC.overmind.blob_points = min(20 + GLOB.player_list.len, BC.overmind.max_blob_points)
|
||||
spawned_mobs += BC.overmind
|
||||
message_admins("[key_name_admin(BC.overmind)] has been made into a blob overmind by an event.")
|
||||
log_game("[key_name(BC.overmind)] was spawned as a blob overmind by an event.")
|
||||
return SUCCESSFUL_SPAWN
|
||||
/datum/round_event_control/blob
|
||||
name = "Blob"
|
||||
typepath = /datum/round_event/ghost_role/blob
|
||||
weight = 10
|
||||
max_occurrences = 1
|
||||
|
||||
min_players = 20
|
||||
|
||||
gamemode_blacklist = list("blob") //Just in case a blob survives that long
|
||||
|
||||
/datum/round_event/ghost_role/blob
|
||||
announceWhen = -1
|
||||
role_name = "blob overmind"
|
||||
|
||||
/datum/round_event/ghost_role/blob/announce()
|
||||
priority_announce("Confirmed outbreak of level 5 biohazard aboard [station_name()]. All personnel must contain the outbreak.", "Biohazard Alert", 'sound/ai/outbreak5.ogg')
|
||||
|
||||
/datum/round_event/ghost_role/blob/spawn_role()
|
||||
if(!GLOB.blobstart.len)
|
||||
return MAP_ERROR
|
||||
var/list/candidates = get_candidates("blob", null, ROLE_BLOB)
|
||||
if(!candidates.len)
|
||||
return NOT_ENOUGH_PLAYERS
|
||||
var/mob/dead/observer/new_blob = pick(candidates)
|
||||
var/mob/camera/blob/BC = new_blob.become_overmind()
|
||||
spawned_mobs += BC
|
||||
message_admins("[key_name_admin(BC)] has been made into a blob overmind by an event.")
|
||||
log_game("[key_name(BC)] was spawned as a blob overmind by an event.")
|
||||
return SUCCESSFUL_SPAWN
|
||||
|
||||
@@ -1,37 +1,61 @@
|
||||
/datum/round_event_control/falsealarm
|
||||
name = "False Alarm"
|
||||
typepath = /datum/round_event/falsealarm
|
||||
weight = 20
|
||||
max_occurrences = 5
|
||||
|
||||
/datum/round_event_control/falsealarm/canSpawnEvent(players_amt, gamemode)
|
||||
return ..() && length(gather_false_events())
|
||||
|
||||
/datum/round_event/falsealarm
|
||||
announceWhen = 0
|
||||
endWhen = 1
|
||||
|
||||
/datum/round_event/falsealarm/announce()
|
||||
var/players_amt = get_active_player_count(alive_check = 1, afk_check = 1, human_check = 1)
|
||||
var/gamemode = SSticker.mode.config_tag
|
||||
|
||||
var/events_list = gather_false_events(players_amt, gamemode)
|
||||
var/datum/round_event_control/event_control = pick(events_list)
|
||||
if(event_control)
|
||||
var/datum/round_event/Event = new event_control.typepath()
|
||||
message_admins("False Alarm: [Event]")
|
||||
Event.kill() //do not process this event - no starts, no ticks, no ends
|
||||
Event.announce() //just announce it like it's happening
|
||||
|
||||
/proc/gather_false_events(players_amt, gamemode)
|
||||
. = list()
|
||||
for(var/datum/round_event_control/E in SSevents.control)
|
||||
/datum/round_event_control/falsealarm
|
||||
name = "False Alarm"
|
||||
typepath = /datum/round_event/falsealarm
|
||||
weight = 20
|
||||
max_occurrences = 5
|
||||
var/forced_type //Admin abuse
|
||||
|
||||
|
||||
/datum/round_event_control/falsealarm/admin_setup()
|
||||
if(!check_rights(R_FUN))
|
||||
return
|
||||
|
||||
var/list/possible_types = list()
|
||||
|
||||
for(var/datum/round_event_control/E in SSevents.control)
|
||||
if(istype(E, /datum/round_event_control/falsealarm))
|
||||
continue
|
||||
if(!E.canSpawnEvent(players_amt, gamemode))
|
||||
continue
|
||||
|
||||
var/datum/round_event/event = E.typepath
|
||||
if(initial(event.announceWhen) <= 0)
|
||||
continue
|
||||
. += E
|
||||
continue
|
||||
var/datum/round_event/event = E.typepath
|
||||
if(initial(event.announceWhen) <= 0)
|
||||
continue
|
||||
possible_types += E
|
||||
|
||||
forced_type = input(usr, "Select the scare.","False event") as null|anything in possible_types
|
||||
|
||||
/datum/round_event_control/falsealarm/canSpawnEvent(players_amt, gamemode)
|
||||
return ..() && length(gather_false_events())
|
||||
|
||||
/datum/round_event/falsealarm
|
||||
announceWhen = 0
|
||||
endWhen = 1
|
||||
|
||||
/datum/round_event/falsealarm/announce()
|
||||
var/players_amt = get_active_player_count(alive_check = 1, afk_check = 1, human_check = 1)
|
||||
var/gamemode = SSticker.mode.config_tag
|
||||
|
||||
var/events_list = gather_false_events(players_amt, gamemode)
|
||||
var/datum/round_event_control/event_control
|
||||
var/datum/round_event_control/falsealarm/C = control
|
||||
if(C.forced_type)
|
||||
event_control = C.forced_type
|
||||
C.forced_type = null
|
||||
else
|
||||
event_control = pick(events_list)
|
||||
if(event_control)
|
||||
var/datum/round_event/Event = new event_control.typepath()
|
||||
message_admins("False Alarm: [Event]")
|
||||
Event.kill() //do not process this event - no starts, no ticks, no ends
|
||||
Event.announce() //just announce it like it's happening
|
||||
|
||||
/proc/gather_false_events(players_amt, gamemode)
|
||||
. = list()
|
||||
for(var/datum/round_event_control/E in SSevents.control)
|
||||
if(istype(E, /datum/round_event_control/falsealarm))
|
||||
continue
|
||||
if(!E.canSpawnEvent(players_amt, gamemode))
|
||||
continue
|
||||
|
||||
var/datum/round_event/event = E.typepath
|
||||
if(initial(event.announceWhen) <= 0)
|
||||
continue
|
||||
. += E
|
||||
|
||||
@@ -106,7 +106,7 @@
|
||||
slowdown = 2
|
||||
|
||||
/turf/open/floor/holofloor/snow/cold
|
||||
initial_gas_mix = "freon=7500;TEMP=0"
|
||||
initial_gas_mix = "nob=7500;TEMP=2.7"
|
||||
|
||||
/turf/open/floor/holofloor/asteroid
|
||||
name = "asteroid sand"
|
||||
|
||||
@@ -44,15 +44,11 @@
|
||||
attack_verb = list("bashed", "battered", "bludgeoned", "whacked")
|
||||
var/plank_type = /obj/item/stack/sheet/mineral/wood
|
||||
var/plank_name = "wooden planks"
|
||||
var/list/accepted = list(/obj/item/reagent_containers/food/snacks/grown/tobacco,
|
||||
var/static/list/accepted = typecacheof(list(/obj/item/reagent_containers/food/snacks/grown/tobacco,
|
||||
/obj/item/reagent_containers/food/snacks/grown/tea,
|
||||
/obj/item/reagent_containers/food/snacks/grown/ambrosia/vulgaris,
|
||||
/obj/item/reagent_containers/food/snacks/grown/ambrosia/deus,
|
||||
/obj/item/reagent_containers/food/snacks/grown/wheat)
|
||||
|
||||
/obj/item/grown/log/Initialize()
|
||||
. = ..()
|
||||
accepted = typecacheof(accepted)
|
||||
/obj/item/reagent_containers/food/snacks/grown/wheat))
|
||||
|
||||
/obj/item/grown/log/attackby(obj/item/W, mob/user, params)
|
||||
if(W.sharpness)
|
||||
@@ -69,7 +65,7 @@
|
||||
to_chat(user, "<span class='notice'>You add the newly-formed [plank_name] to the stack. It now contains [plank.amount] [plank_name].</span>")
|
||||
qdel(src)
|
||||
|
||||
if(is_type_in_typecache(W,accepted))
|
||||
if(CheckAccepted(W))
|
||||
var/obj/item/reagent_containers/food/snacks/grown/leaf = W
|
||||
if(leaf.dry)
|
||||
user.show_message("<span class='notice'>You wrap \the [W] around the log, turning it into a torch!</span>")
|
||||
@@ -84,6 +80,9 @@
|
||||
else
|
||||
return ..()
|
||||
|
||||
/obj/item/grown/log/proc/CheckAccepted(obj/item/I)
|
||||
return is_type_in_typecache(I, accepted)
|
||||
|
||||
/obj/item/grown/log/tree
|
||||
seed = null
|
||||
name = "wood log"
|
||||
@@ -94,10 +93,11 @@
|
||||
name = "steel-cap log"
|
||||
desc = "It's made of metal."
|
||||
icon_state = "steellogs"
|
||||
accepted = list()
|
||||
plank_type = /obj/item/stack/rods
|
||||
plank_name = "rods"
|
||||
|
||||
/obj/item/grown/log/steel/CheckAccepted(obj/item/I)
|
||||
return FALSE
|
||||
|
||||
/////////BONFIRES//////////
|
||||
|
||||
|
||||
@@ -693,10 +693,13 @@
|
||||
var/target = myseed ? myseed.plantname : src
|
||||
var/visi_msg = ""
|
||||
var/irrigate = 0 //How am I supposed to irrigate pill contents?
|
||||
var/transfer_amount
|
||||
|
||||
if(istype(reagent_source, /obj/item/reagent_containers/food/snacks) || istype(reagent_source, /obj/item/reagent_containers/pill))
|
||||
visi_msg="[user] composts [reagent_source], spreading it through [target]"
|
||||
transfer_amount = reagent_source.reagents.total_volume
|
||||
else
|
||||
transfer_amount = reagent_source.amount_per_transfer_from_this
|
||||
if(istype(reagent_source, /obj/item/reagent_containers/syringe/))
|
||||
var/obj/item/reagent_containers/syringe/syr = reagent_source
|
||||
visi_msg="[user] injects [target] with [syr]"
|
||||
@@ -706,14 +709,14 @@
|
||||
visi_msg="[user] sprays [target] with [reagent_source]"
|
||||
playsound(loc, 'sound/effects/spray3.ogg', 50, 1, -6)
|
||||
irrigate = 1
|
||||
else if(reagent_source.amount_per_transfer_from_this) // Droppers, cans, beakers, what have you.
|
||||
else if(transfer_amount) // Droppers, cans, beakers, what have you.
|
||||
visi_msg="[user] uses [reagent_source] on [target]"
|
||||
irrigate = 1
|
||||
// Beakers, bottles, buckets, etc. Can't use is_open_container though.
|
||||
if(istype(reagent_source, /obj/item/reagent_containers/glass/))
|
||||
playsound(loc, 'sound/effects/slosh.ogg', 25, 1)
|
||||
|
||||
if(irrigate && reagent_source.amount_per_transfer_from_this > 30 && reagent_source.reagents.total_volume >= 30 && using_irrigation)
|
||||
if(irrigate && transfer_amount > 30 && reagent_source.reagents.total_volume >= 30 && using_irrigation)
|
||||
trays = FindConnected()
|
||||
if (trays.len > 1)
|
||||
visi_msg += ", setting off the irrigation system"
|
||||
@@ -721,7 +724,7 @@
|
||||
if(visi_msg)
|
||||
visible_message("<span class='notice'>[visi_msg].</span>")
|
||||
|
||||
var/split = round(reagent_source.amount_per_transfer_from_this/trays.len)
|
||||
var/split = round(transfer_amount/trays.len)
|
||||
|
||||
for(var/obj/machinery/hydroponics/H in trays)
|
||||
//cause I don't want to feel like im juggling 15 tamagotchis and I can get to my real work of ripping flooring apart in hopes of validating my life choices of becoming a space-gardener
|
||||
|
||||
@@ -56,10 +56,11 @@
|
||||
|
||||
if (top_atom)
|
||||
LAZYREMOVE(top_atom.light_sources, src)
|
||||
|
||||
|
||||
if (needs_update)
|
||||
GLOB.lighting_update_lights -= src
|
||||
|
||||
. = ..()
|
||||
if(!force)
|
||||
return QDEL_HINT_IWILLGC
|
||||
|
||||
// Yes this doesn't align correctly on anything other than 4 width tabs.
|
||||
// If you want it to go switch everybody to elastic tab stops.
|
||||
|
||||
@@ -109,7 +109,7 @@
|
||||
icon_state = "t_mushroom"
|
||||
name = "numerous mushrooms"
|
||||
desc = "A large number of mushrooms, some of which have long, fleshy stems. They're radiating light!"
|
||||
luminosity = 1
|
||||
light_range = 1
|
||||
harvested_name = "tiny mushrooms"
|
||||
harvested_desc = "A few tiny mushrooms around larger stumps. You can already see them growing back."
|
||||
harvest = /obj/item/reagent_containers/food/snacks/grown/ash_flora/mushroom_stem
|
||||
@@ -190,7 +190,7 @@
|
||||
desc = "A long mushroom stem. It's slightly glowing."
|
||||
list_reagents = list("tinlux" = 2, "vitamin" = 1, "space_drugs" = 1)
|
||||
icon_state = "mushroom_stem"
|
||||
luminosity = 1
|
||||
light_range = 1
|
||||
seed = /obj/item/seeds/lavaland/ember
|
||||
|
||||
/obj/item/reagent_containers/food/snacks/grown/ash_flora/cactus_fruit
|
||||
|
||||
@@ -194,7 +194,7 @@
|
||||
desc = "Happy to light your way."
|
||||
icon = 'icons/obj/lighting.dmi'
|
||||
icon_state = "orb"
|
||||
luminosity = 7
|
||||
light_range = 7
|
||||
layer = ABOVE_ALL_MOB_LAYER
|
||||
|
||||
//Red/Blue Cubes
|
||||
@@ -880,11 +880,7 @@
|
||||
var/create_delay = 30
|
||||
var/reset_cooldown = 50
|
||||
var/timer = 0
|
||||
var/banned_turfs
|
||||
|
||||
/obj/item/lava_staff/Initialize()
|
||||
. = ..()
|
||||
banned_turfs = typecacheof(list(/turf/open/space/transit, /turf/closed))
|
||||
var/static/list/banned_turfs = typecacheof(list(/turf/open/space/transit, /turf/closed))
|
||||
|
||||
/obj/item/lava_staff/afterattack(atom/target, mob/user, proximity_flag, click_parameters)
|
||||
..()
|
||||
|
||||
@@ -480,6 +480,8 @@
|
||||
client.prefs.copy_to(H)
|
||||
H.dna.update_dna_identity()
|
||||
if(mind)
|
||||
if(transfer_after)
|
||||
mind.late_joiner = TRUE
|
||||
mind.active = 0 //we wish to transfer the key manually
|
||||
mind.transfer_to(H) //won't transfer key since the mind is not active
|
||||
|
||||
|
||||
@@ -59,7 +59,7 @@
|
||||
if(previewJob && !nude)
|
||||
mannequin.job = previewJob.title
|
||||
previewJob.equip(mannequin, TRUE)
|
||||
mannequin.compile_overlays()
|
||||
COMPILE_OVERLAYS(mannequin)
|
||||
CHECK_TICK
|
||||
preview_icon = icon('icons/effects/effects.dmi', "nothing")
|
||||
preview_icon.Scale(48+32, 16+32)
|
||||
|
||||
File diff suppressed because it is too large
Load Diff
@@ -39,7 +39,7 @@
|
||||
name = "Bear"
|
||||
icon_state = "bear"
|
||||
icon = 'icons/mob/mam_bodyparts.dmi'
|
||||
|
||||
|
||||
/datum/sprite_accessory/tails/human/bear
|
||||
name = "Bear"
|
||||
icon_state = "bear"
|
||||
@@ -65,7 +65,7 @@
|
||||
icon_state = "cow"
|
||||
icon = 'icons/mob/mam_bodyparts.dmi'
|
||||
gender_specific = 1
|
||||
|
||||
|
||||
/datum/sprite_accessory/tails/human/cow
|
||||
name = "Cow"
|
||||
icon_state = "cow"
|
||||
@@ -175,21 +175,24 @@
|
||||
name = "Otusian"
|
||||
icon_state = "otie"
|
||||
hasinner= 1
|
||||
icon = 'icons/mob/mam_bodyparts.dmi'
|
||||
|
||||
/datum/sprite_accessory/tails/human/otie
|
||||
name = "Otusian"
|
||||
icon_state = "otie"
|
||||
icon = 'icons/mob/mam_bodyparts.dmi'
|
||||
|
||||
/datum/sprite_accessory/tails_animated/human/otie
|
||||
name = "Otusian"
|
||||
icon_state = "otie"
|
||||
icon = 'icons/mob/mam_bodyparts.dmi'
|
||||
|
||||
/datum/sprite_accessory/ears/human/rabbit
|
||||
name = "Rabbit"
|
||||
icon_state = "rabbit"
|
||||
hasinner= 1
|
||||
icon = 'icons/mob/mam_bodyparts.dmi'
|
||||
|
||||
|
||||
/datum/sprite_accessory/tails/human/rabbit
|
||||
name = "Rabbit"
|
||||
icon_state = "rabbit"
|
||||
@@ -201,10 +204,11 @@
|
||||
icon_state = "rabbit"
|
||||
color_src = 0
|
||||
icon = 'icons/mob/mam_bodyparts.dmi'
|
||||
|
||||
|
||||
/datum/sprite_accessory/ears/human/skunk
|
||||
name = "skunk"
|
||||
icon_state = "skunk"
|
||||
icon = 'icons/mob/mam_bodyparts.dmi'
|
||||
|
||||
/datum/sprite_accessory/tails/human/skunk
|
||||
name = "skunk"
|
||||
@@ -248,6 +252,7 @@
|
||||
name = "Wolf"
|
||||
icon_state = "wolf"
|
||||
hasinner = 1
|
||||
icon = 'icons/mob/mam_bodyparts.dmi'
|
||||
|
||||
/datum/sprite_accessory/tails/human/wolf
|
||||
name = "Wolf"
|
||||
@@ -341,7 +346,7 @@
|
||||
/datum/sprite_accessory/mam_ears/bear
|
||||
name = "Bear"
|
||||
icon_state = "bear"
|
||||
|
||||
|
||||
/datum/sprite_accessory/mam_tails/bear
|
||||
name = "Bear"
|
||||
icon_state = "bear"
|
||||
@@ -352,9 +357,9 @@
|
||||
|
||||
/datum/sprite_accessory/mam_ears/catbig
|
||||
name = "Cat, Big"
|
||||
icon_state = "cat"
|
||||
icon_state = "catbig"
|
||||
hasinner = 1
|
||||
|
||||
|
||||
/datum/sprite_accessory/mam_tails/catbig
|
||||
name = "Cat, Big"
|
||||
icon_state = "catbig"
|
||||
@@ -367,7 +372,7 @@
|
||||
name = "Cow"
|
||||
icon_state = "cow"
|
||||
gender_specific = 1
|
||||
|
||||
|
||||
/datum/sprite_accessory/mam_tail/cow
|
||||
name = "Cow"
|
||||
icon_state = "cow"
|
||||
@@ -522,7 +527,7 @@
|
||||
name = "Rabbit"
|
||||
icon_state = "rabbit"
|
||||
hasinner= 1
|
||||
|
||||
|
||||
/datum/sprite_accessory/mam_tails/rabbit
|
||||
name = "Rabbit"
|
||||
icon_state = "rabbit"
|
||||
|
||||
@@ -305,15 +305,6 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
/mob/dead/observer/is_active()
|
||||
return 0
|
||||
|
||||
/mob/dead/observer/Stat()
|
||||
..()
|
||||
if(statpanel("Status"))
|
||||
if(SSticker.HasRoundStarted())
|
||||
if(istype(SSticker.mode, /datum/game_mode/blob))
|
||||
var/datum/game_mode/blob/B = SSticker.mode
|
||||
if(B.message_sent)
|
||||
stat(null, "Blobs to Blob Win: [GLOB.blobs_legit.len]/[B.blobwincount]")
|
||||
|
||||
/mob/dead/observer/verb/reenter_corpse()
|
||||
set category = "Ghost"
|
||||
set name = "Re-enter Corpse"
|
||||
|
||||
@@ -45,6 +45,6 @@
|
||||
var/datum/personal_crafting/handcrafting
|
||||
can_buckle = TRUE
|
||||
buckle_lying = FALSE
|
||||
can_ride_typecache = list(/mob/living/carbon/human, /mob/living/simple_animal/slime, /mob/living/simple_animal/parrot)
|
||||
|
||||
var/creamed = FALSE //to use with creampie overlays
|
||||
var/static/list/can_ride_typecache = typecacheof(list(/mob/living/carbon/human, /mob/living/simple_animal/slime, /mob/living/simple_animal/parrot))
|
||||
|
||||
@@ -45,14 +45,15 @@
|
||||
return
|
||||
else
|
||||
//No oldFP or it's a different kind of blood
|
||||
S.bloody_shoes[S.blood_state] = max(0, S.bloody_shoes[S.blood_state]-BLOOD_LOSS_PER_STEP)
|
||||
var/obj/effect/decal/cleanable/blood/footprints/FP = new /obj/effect/decal/cleanable/blood/footprints(T)
|
||||
FP.blood_state = S.blood_state
|
||||
FP.entered_dirs |= dir
|
||||
FP.bloodiness = S.bloody_shoes[S.blood_state]
|
||||
if(S.blood_DNA && S.blood_DNA.len)
|
||||
FP.transfer_blood_dna(S.blood_DNA)
|
||||
FP.update_icon()
|
||||
S.bloody_shoes[S.blood_state] = max(0, S.bloody_shoes[S.blood_state] - BLOOD_LOSS_PER_STEP)
|
||||
if (S.bloody_shoes[S.blood_state] > BLOOD_LOSS_IN_SPREAD)
|
||||
var/obj/effect/decal/cleanable/blood/footprints/FP = new /obj/effect/decal/cleanable/blood/footprints(T)
|
||||
FP.blood_state = S.blood_state
|
||||
FP.entered_dirs |= dir
|
||||
FP.bloodiness = S.bloody_shoes[S.blood_state] - BLOOD_LOSS_IN_SPREAD
|
||||
if(S.blood_DNA && S.blood_DNA.len)
|
||||
FP.transfer_blood_dna(S.blood_DNA)
|
||||
FP.update_icon()
|
||||
update_inv_shoes()
|
||||
//End bloody footprints
|
||||
|
||||
|
||||
@@ -419,6 +419,7 @@
|
||||
if(ishuman(C))
|
||||
unstable_teleport = new
|
||||
unstable_teleport.Grant(C)
|
||||
last_teleport = world.time
|
||||
|
||||
/datum/species/golem/bluespace/on_species_loss(mob/living/carbon/C)
|
||||
if(unstable_teleport)
|
||||
@@ -479,6 +480,11 @@
|
||||
var/banana_cooldown = 100
|
||||
var/active = null
|
||||
|
||||
/datum/species/golem/bananium/on_species_gain(mob/living/carbon/C, datum/species/old_species)
|
||||
..()
|
||||
last_banana = world.time
|
||||
last_honk = world.time
|
||||
|
||||
/datum/species/golem/bananium/random_name(gender,unique,lastname)
|
||||
var/clown_name = pick(GLOB.clown_names)
|
||||
var/golem_name = "[uppertext(clown_name)]"
|
||||
@@ -553,10 +559,13 @@
|
||||
. = ..()
|
||||
C.faction |= "cult"
|
||||
phase_shift = new
|
||||
phase_shift.charge_counter = 0
|
||||
C.AddSpell(phase_shift)
|
||||
abyssal_gaze = new
|
||||
abyssal_gaze.charge_counter = 0
|
||||
C.AddSpell(abyssal_gaze)
|
||||
dominate = new
|
||||
dominate.charge_counter = 0
|
||||
C.AddSpell(dominate)
|
||||
|
||||
/datum/species/golem/runic/on_species_loss(mob/living/carbon/C)
|
||||
|
||||
@@ -1,4 +1,5 @@
|
||||
#define HEART_RESPAWN_THRESHHOLD 40
|
||||
#define HEART_SPECIAL_SHADOWIFY 2
|
||||
|
||||
/datum/species/shadow
|
||||
// Humans cursed to stay in the darkness, lest their life forces drain. They regain health in shadow and die in light.
|
||||
@@ -111,14 +112,15 @@
|
||||
|
||||
/obj/item/organ/heart/nightmare/Insert(mob/living/carbon/M, special = 0)
|
||||
..()
|
||||
blade = new/obj/item/light_eater
|
||||
M.put_in_hands(blade)
|
||||
if(special != HEART_SPECIAL_SHADOWIFY)
|
||||
blade = new/obj/item/light_eater
|
||||
M.put_in_hands(blade)
|
||||
START_PROCESSING(SSobj, src)
|
||||
|
||||
/obj/item/organ/heart/nightmare/Remove(mob/living/carbon/M, special = 0)
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
respawn_progress = 0
|
||||
if(blade)
|
||||
if(blade && special != HEART_SPECIAL_SHADOWIFY)
|
||||
QDEL_NULL(blade)
|
||||
M.visible_message("<span class='warning'>\The [blade] disintegrates!</span>")
|
||||
..()
|
||||
@@ -141,6 +143,13 @@
|
||||
playsound(owner,'sound/effects/singlebeat.ogg',40,1)
|
||||
if(respawn_progress >= HEART_RESPAWN_THRESHHOLD)
|
||||
owner.revive(full_heal = TRUE)
|
||||
if(!(owner.dna.species.id == "shadow" || owner.dna.species.id == "nightmare"))
|
||||
var/mob/living/carbon/old_owner = owner
|
||||
Remove(owner, HEART_SPECIAL_SHADOWIFY)
|
||||
old_owner.set_species(/datum/species/shadow)
|
||||
Insert(old_owner, HEART_SPECIAL_SHADOWIFY)
|
||||
to_chat(owner, "<span class='userdanger'>You feel the shadows invade your skin, leaping into the center of your chest! You're alive!</span>")
|
||||
SEND_SOUND(owner, sound('sound/effects/ghost.ogg'))
|
||||
owner.visible_message("<span class='warning'>[owner] staggers to their feet!</span>")
|
||||
playsound(owner, 'sound/hallucinations/far_noise.ogg', 50, 1)
|
||||
respawn_progress = 0
|
||||
@@ -193,4 +202,5 @@
|
||||
O.burn()
|
||||
playsound(src, 'sound/items/welder.ogg', 50, 1)
|
||||
|
||||
#undef HEART_SPECIAL_SHADOWIFY
|
||||
#undef HEART_RESPAWN_THRESHHOLD
|
||||
@@ -203,6 +203,16 @@
|
||||
hallucination += 20
|
||||
else if(bz_partialpressure > 0.01)
|
||||
hallucination += 5//Removed at 2 per tick so this will slowly build up
|
||||
//TRITIUM
|
||||
if(breath_gases[/datum/gas/tritium])
|
||||
var/tritium_partialpressure = (breath_gases[/datum/gas/tritium][MOLES]/breath.total_moles())*breath_pressure
|
||||
radiation += tritium_partialpressure/10
|
||||
//Brown Gas
|
||||
if (breath_gases[/datum/gas/brown_gas])
|
||||
var/browns_partialpressure = (breath_gases[/datum/gas/brown_gas][MOLES]/breath.total_moles())*breath_pressure
|
||||
adjustFireLoss(browns_partialpressure/4)
|
||||
|
||||
|
||||
|
||||
breath.garbage_collect()
|
||||
|
||||
|
||||
@@ -196,7 +196,7 @@
|
||||
M.pass_flags &= ~PASSMOB
|
||||
|
||||
now_pushing = 0
|
||||
|
||||
|
||||
if(!move_failed)
|
||||
return 1
|
||||
|
||||
@@ -780,16 +780,6 @@
|
||||
/mob/living/proc/get_standard_pixel_y_offset(lying = 0)
|
||||
return initial(pixel_y)
|
||||
|
||||
/mob/living/Stat()
|
||||
..()
|
||||
|
||||
if(statpanel("Status"))
|
||||
if(SSticker && SSticker.mode)
|
||||
if(istype(SSticker.mode, /datum/game_mode/blob))
|
||||
var/datum/game_mode/blob/B = SSticker.mode
|
||||
if(B.message_sent)
|
||||
stat(null, "Blobs to Blob Win: [GLOB.blobs_legit.len]/[B.blobwincount]")
|
||||
|
||||
/mob/living/cancel_camera()
|
||||
..()
|
||||
cameraFollow = null
|
||||
|
||||
@@ -338,18 +338,11 @@
|
||||
/mob/living/ratvar_act()
|
||||
if(status_flags & GODMODE)
|
||||
return
|
||||
|
||||
if(stat != DEAD && !is_servant_of_ratvar(src))
|
||||
for(var/obj/item/implant/mindshield/M in implants)
|
||||
qdel(M)
|
||||
if(!add_servant_of_ratvar(src))
|
||||
to_chat(src, "<span class='userdanger'>A blinding light boils you alive! <i>Run!</i></span>")
|
||||
adjustFireLoss(35)
|
||||
if(src)
|
||||
adjust_fire_stacks(1)
|
||||
IgniteMob()
|
||||
return FALSE
|
||||
return TRUE
|
||||
to_chat(src, "<span class='userdanger'>A blinding light boils you alive! <i>Run!</i></span>")
|
||||
adjust_fire_stacks(20)
|
||||
IgniteMob()
|
||||
return FALSE
|
||||
|
||||
|
||||
//called when the mob receives a bright flash
|
||||
|
||||
@@ -95,7 +95,7 @@
|
||||
|
||||
can_buckle = TRUE
|
||||
buckle_lying = FALSE
|
||||
can_ride_typecache = list(/mob/living/carbon/human)
|
||||
var/static/list/can_ride_typecache = typecacheof(/mob/living/carbon/human)
|
||||
|
||||
/mob/living/silicon/robot/get_cell()
|
||||
return cell
|
||||
|
||||
@@ -352,10 +352,9 @@
|
||||
/obj/item/soap/tongue,
|
||||
/obj/item/device/analyzer/nose,
|
||||
/obj/item/device/dogborg/sleeper/K9,
|
||||
/obj/item/pinpointer/crew)
|
||||
emag_modules = list(/obj/item/gun/energy/laser/cyborg,
|
||||
/obj/item/gun/energy/disabler/cyborg,
|
||||
/obj/item/pinpointer/nuke)
|
||||
/obj/item/pinpointer/crew)
|
||||
emag_modules = list(/obj/item/gun/energy/laser/cyborg)
|
||||
ratvar_modules = list(/obj/item/clockwork/slab/cyborg/security,
|
||||
/obj/item/clockwork/weapon/ratvarian_spear)
|
||||
cyborg_base_icon = "k9"
|
||||
@@ -408,7 +407,6 @@
|
||||
/obj/item/robot_module/scrubpup
|
||||
name = "Janitor"
|
||||
basic_modules = list(
|
||||
/obj/item/device/assembly/flash/cyborg,
|
||||
/obj/item/dogborg/jaws/small,
|
||||
/obj/item/device/analyzer/nose,
|
||||
/obj/item/soap/tongue/scrubpup,
|
||||
@@ -422,6 +420,7 @@
|
||||
moduleselect_icon = "scrubpup"
|
||||
feedback_key = "cyborg_scrubpup"
|
||||
hat_offset = INFINITY
|
||||
clean_on_move = TRUE
|
||||
|
||||
/obj/item/robot_module/scrubpup/respawn_consumable(mob/living/silicon/robot/R, coeff = 1)
|
||||
..()
|
||||
|
||||
@@ -47,6 +47,10 @@
|
||||
diag_hud_set_status()
|
||||
diag_hud_set_health()
|
||||
|
||||
/mob/living/silicon/ComponentInitialize()
|
||||
. = ..()
|
||||
AddComponent(/datum/component/rad_insulation, RAD_NO_INSULATION, TRUE, TRUE)
|
||||
|
||||
/mob/living/silicon/med_hud_set_health()
|
||||
return //we use a different hud
|
||||
|
||||
|
||||
@@ -5,7 +5,7 @@
|
||||
icon = 'icons/mob/aibots.dmi'
|
||||
layer = MOB_LAYER
|
||||
gender = NEUTER
|
||||
luminosity = 3
|
||||
light_range = 3
|
||||
stop_automated_movement = 1
|
||||
wander = 0
|
||||
healable = 0
|
||||
|
||||
@@ -124,6 +124,9 @@
|
||||
|
||||
if(!target) //Search for decals then.
|
||||
target = scan(/obj/effect/decal/cleanable)
|
||||
|
||||
if(!target) //Checks for remains
|
||||
target = scan(/obj/effect/decal/remains)
|
||||
|
||||
if(!target && trash) //Then for trash.
|
||||
target = scan(/obj/item/trash)
|
||||
@@ -178,7 +181,8 @@
|
||||
/obj/effect/decal/cleanable/ash,
|
||||
/obj/effect/decal/cleanable/greenglow,
|
||||
/obj/effect/decal/cleanable/dirt,
|
||||
/obj/effect/decal/cleanable/deadcockroach
|
||||
/obj/effect/decal/cleanable/deadcockroach,
|
||||
/obj/effect/decal/remains
|
||||
)
|
||||
|
||||
if(blood)
|
||||
@@ -213,9 +217,9 @@
|
||||
target = null
|
||||
mode = BOT_IDLE
|
||||
icon_state = "cleanbot[on]"
|
||||
else if(istype(A, /obj/item))
|
||||
else if(istype(A, /obj/item) || istype(A, /obj/effect/decal/remains))
|
||||
visible_message("<span class='danger'>[src] sprays hydrofluoric acid at [A]!</span>")
|
||||
playsound(src.loc, 'sound/effects/spray2.ogg', 50, 1, -6)
|
||||
playsound(src, 'sound/effects/spray2.ogg', 50, 1, -6)
|
||||
A.acid_act(75, 10)
|
||||
else if(istype(A, /mob/living/simple_animal/cockroach) || istype(A, /mob/living/simple_animal/mouse))
|
||||
var/mob/living/simple_animal/M = target
|
||||
|
||||
@@ -41,7 +41,7 @@
|
||||
|
||||
/mob/living/simple_animal/hostile/syndicate/mecha_pilot/no_mech/Initialize()
|
||||
. = ..()
|
||||
wanted_objects = typecacheof(/obj/mecha/combat, ignore_root_path=TRUE)
|
||||
wanted_objects = typecacheof(/obj/mecha/combat, TRUE)
|
||||
|
||||
/mob/living/simple_animal/hostile/syndicate/mecha_pilot/nanotrasen //nanotrasen are syndies! no it's just a weird path.
|
||||
name = "Nanotrasen Mecha Pilot"
|
||||
@@ -101,7 +101,7 @@
|
||||
targets_from = src
|
||||
|
||||
//Find a new mecha
|
||||
wanted_objects = typecacheof(/obj/mecha/combat, ignore_root_path=TRUE)
|
||||
wanted_objects = typecacheof(/obj/mecha/combat, TRUE)
|
||||
var/search_aggressiveness = 2
|
||||
for(var/obj/mecha/combat/C in range(vision_range,src))
|
||||
if(is_valid_mecha(C))
|
||||
|
||||
@@ -159,18 +159,18 @@ Difficulty: Medium
|
||||
Shoot(target)
|
||||
changeNext_move(CLICK_CD_RANGE)
|
||||
|
||||
//I'm still of the belief that this entire proc needs to be wiped from existence.
|
||||
// do not take my touching of it to be endorsement of it. ~mso
|
||||
/mob/living/simple_animal/hostile/megafauna/blood_drunk_miner/proc/quick_attack_loop()
|
||||
if(next_move <= world.time)
|
||||
stoplag(1)
|
||||
.() //retry
|
||||
return
|
||||
sleep((next_move - world.time) * 1.5)
|
||||
while(!QDELETED(target) && next_move <= world.time) //this is done this way because next_move can change to be sooner while we sleep.
|
||||
stoplag(1)
|
||||
sleep((next_move - world.time) * 1.5) //but don't ask me what the fuck this is about
|
||||
if(QDELETED(target))
|
||||
return
|
||||
if(dashing || next_move > world.time || !Adjacent(target))
|
||||
if(dashing && next_move <= world.time)
|
||||
next_move = world.time + 1
|
||||
.() //recurse
|
||||
INVOKE_ASYNC(src, .proc/quick_attack_loop) //lets try that again.
|
||||
return
|
||||
AttackingTarget()
|
||||
|
||||
|
||||
@@ -616,7 +616,7 @@ Difficulty: Very Hard
|
||||
pass_flags = PASSTABLE | PASSGRILLE | PASSMOB
|
||||
ventcrawler = VENTCRAWLER_ALWAYS
|
||||
mob_size = MOB_SIZE_TINY
|
||||
gold_core_spawnable = 0
|
||||
gold_core_spawnable = TRUE
|
||||
verb_say = "warps"
|
||||
verb_ask = "floats inquisitively"
|
||||
verb_exclaim = "zaps"
|
||||
@@ -634,7 +634,6 @@ Difficulty: Very Hard
|
||||
environment_smash = ENVIRONMENT_SMASH_NONE
|
||||
AIStatus = AI_OFF
|
||||
stop_automated_movement = 1
|
||||
gold_core_spawnable = TRUE
|
||||
var/heal_power = 5
|
||||
|
||||
/mob/living/simple_animal/hostile/lightgeist/Initialize()
|
||||
@@ -663,12 +662,7 @@ Difficulty: Very Hard
|
||||
activation_method = ACTIVATE_TOUCH
|
||||
cooldown_add = 50
|
||||
activation_sound = 'sound/magic/timeparadox2.ogg'
|
||||
var/list/banned_items_typecache = list(/obj/item/storage, /obj/item/implant, /obj/item/implanter, /obj/item/disk/nuclear, /obj/item/projectile, /obj/item/spellbook)
|
||||
|
||||
/obj/machinery/anomalous_crystal/refresher/Initialize()
|
||||
. = ..()
|
||||
banned_items_typecache = typecacheof(banned_items_typecache)
|
||||
|
||||
var/static/list/banned_items_typecache = typecacheof(list(/obj/item/storage, /obj/item/implant, /obj/item/implanter, /obj/item/disk/nuclear, /obj/item/projectile, /obj/item/spellbook))
|
||||
|
||||
/obj/machinery/anomalous_crystal/refresher/ActivationReaction(mob/user, method)
|
||||
if(..())
|
||||
|
||||
@@ -172,16 +172,9 @@ GLOBAL_LIST_INIT(AISwarmerCapsByType, list(/mob/living/simple_animal/hostile/swa
|
||||
search_objects = 1
|
||||
attack_all_objects = TRUE //attempt to nibble everything
|
||||
lose_patience_timeout = 150
|
||||
var/static/list/sharedWanted = list(/turf/closed/mineral, /turf/closed/wall) //eat rocks and walls
|
||||
var/static/list/sharedWanted = typecacheof(list(/turf/closed/mineral, /turf/closed/wall)) //eat rocks and walls
|
||||
var/static/list/sharedIgnore = list()
|
||||
|
||||
|
||||
/mob/living/simple_animal/hostile/swarmer/ai/resource/Initialize()
|
||||
. = ..()
|
||||
sharedWanted = typecacheof(sharedWanted)
|
||||
sharedIgnore = typecacheof(sharedIgnore)
|
||||
|
||||
|
||||
//This handles viable things to eat/attack
|
||||
//Place specific cases of AI derpiness here
|
||||
//Most can be left to the automatic Gain/LosePatience() system
|
||||
@@ -239,18 +232,15 @@ GLOBAL_LIST_INIT(AISwarmerCapsByType, list(/mob/living/simple_animal/hostile/swa
|
||||
|
||||
//So swarmers can learn what is and isn't food
|
||||
/mob/living/simple_animal/hostile/swarmer/ai/resource/proc/add_type_to_wanted(typepath)
|
||||
LAZYINITLIST(sharedWanted)
|
||||
if(!sharedWanted[typepath])// this and += is faster than |=
|
||||
sharedWanted += typecacheof(typepath)
|
||||
|
||||
|
||||
/mob/living/simple_animal/hostile/swarmer/ai/resource/proc/add_type_to_ignore(typepath)
|
||||
LAZYINITLIST(sharedIgnore)
|
||||
if(!sharedIgnore[typepath])
|
||||
sharedIgnore += typecacheof(typepath)
|
||||
|
||||
|
||||
|
||||
//RANGED SWARMER
|
||||
/mob/living/simple_animal/hostile/swarmer/ai/ranged_combat
|
||||
icon_state = "swarmer_ranged"
|
||||
|
||||
@@ -26,13 +26,12 @@
|
||||
else
|
||||
GLOB.living_mob_list += src
|
||||
prepare_huds()
|
||||
can_ride_typecache = typecacheof(can_ride_typecache)
|
||||
hook_vr("mob_new",list(src))
|
||||
for(var/v in GLOB.active_alternate_appearances)
|
||||
if(!v)
|
||||
continue
|
||||
var/datum/atom_hud/alternate_appearance/AA = v
|
||||
AA.onNewMob(src)
|
||||
hook_vr("mob_new",list(src))
|
||||
. = ..()
|
||||
|
||||
/atom/proc/prepare_huds()
|
||||
@@ -391,7 +390,7 @@
|
||||
pulling = null
|
||||
grab_state = 0
|
||||
update_pull_hud_icon()
|
||||
|
||||
|
||||
if(isliving(ex_pulled))
|
||||
var/mob/living/L = ex_pulled
|
||||
L.update_canmove()// mob gets up if it was lyng down in a chokehold
|
||||
|
||||
@@ -27,8 +27,9 @@
|
||||
var/damageoverlaytemp = 0
|
||||
var/computer_id = null
|
||||
var/lastattacker = null
|
||||
var/lastattacked = null
|
||||
var/list/logging = list(INDIVIDUAL_ATTACK_LOG, INDIVIDUAL_SAY_LOG, INDIVIDUAL_EMOTE_LOG, INDIVIDUAL_OOC_LOG, INDIVIDUAL_LOOC_LOG)
|
||||
var/lastattackerckey = null
|
||||
var/list/logging = list(INDIVIDUAL_ATTACK_LOG, INDIVIDUAL_SAY_LOG, INDIVIDUAL_EMOTE_LOG, INDIVIDUAL_OOC_LOG)
|
||||
|
||||
var/obj/machinery/machine = null
|
||||
var/other_mobs = null
|
||||
var/disabilities = 0 //Carbon
|
||||
@@ -140,7 +141,6 @@
|
||||
var/list/observers = null //The list of people observing this mob.
|
||||
|
||||
var/list/progressbars = null //for stacking do_after bars
|
||||
var/list/can_ride_typecache = list()
|
||||
|
||||
var/list/mousemove_intercept_objects
|
||||
|
||||
|
||||
@@ -335,9 +335,9 @@ It's fairly easy to fix if dealing with single letters but not so much with comp
|
||||
|
||||
/proc/is_special_character(mob/M) // returns 1 for special characters and 2 for heroes of gamemode //moved out of admins.dm because things other than admin procs were calling this.
|
||||
if(!SSticker.HasRoundStarted())
|
||||
return 0
|
||||
return FALSE
|
||||
if(!istype(M))
|
||||
return 0
|
||||
return FALSE
|
||||
if(issilicon(M))
|
||||
if(iscyborg(M)) //For cyborgs, returns 1 if the cyborg has a law 0 and special_role. Returns 0 if the borg is merely slaved to an AI traitor.
|
||||
var/mob/living/silicon/robot/R = M
|
||||
@@ -346,13 +346,13 @@ It's fairly easy to fix if dealing with single letters but not so much with comp
|
||||
if(R.connected_ai)
|
||||
if(is_special_character(R.connected_ai) && R.connected_ai.laws && (R.connected_ai.laws.zeroth_borg == R.laws.zeroth || R.connected_ai.laws.zeroth == R.laws.zeroth))
|
||||
return 0 //AI is the real traitor here, so the borg itself is not a traitor
|
||||
return 1 //Slaved but also a traitor
|
||||
return 1 //Unslaved, traitor
|
||||
return TRUE//Slaved but also a traitor
|
||||
return TRUE //Unslaved, traitor
|
||||
else if(isAI(M))
|
||||
var/mob/living/silicon/ai/A = M
|
||||
if(A.laws && A.laws.zeroth && A.mind && A.mind.special_role)
|
||||
return 1
|
||||
return 0
|
||||
return TRUE
|
||||
return FALSE
|
||||
if(M.mind && M.mind.special_role)//If they have a mind and special role, they are some type of traitor or antagonist.
|
||||
switch(SSticker.mode.config_tag)
|
||||
if("revolution")
|
||||
@@ -379,8 +379,10 @@ It's fairly easy to fix if dealing with single letters but not so much with comp
|
||||
if("abductor")
|
||||
if(M.mind in SSticker.mode.abductors)
|
||||
return 2
|
||||
return 1
|
||||
return 0
|
||||
return TRUE
|
||||
if(M.mind && LAZYLEN(M.mind.antag_datums)) //they have an antag datum!
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
/mob/proc/reagent_check(datum/reagent/R) // utilized in the species code
|
||||
return 1
|
||||
|
||||
@@ -376,8 +376,6 @@
|
||||
if(!transfer_after)
|
||||
mind.active = FALSE
|
||||
mind.transfer_to(R)
|
||||
if(mind.special_role)
|
||||
R.mind.store_memory("In case you look at this after being borged, the objectives are only here until I find a way to make them not show up for you, as I can't simply delete them without screwing up round-end reporting. --NeoFite")
|
||||
else if(transfer_after)
|
||||
R.key = key
|
||||
|
||||
@@ -462,12 +460,9 @@
|
||||
. = new_slime
|
||||
qdel(src)
|
||||
|
||||
/mob/proc/become_overmind(mode_made, starting_points = 60)
|
||||
var/mob/camera/blob/B = new /mob/camera/blob(loc, 0, mode_made, starting_points)
|
||||
if(mind)
|
||||
mind.transfer_to(B)
|
||||
else
|
||||
B.key = key
|
||||
/mob/proc/become_overmind(starting_points = 60)
|
||||
var/mob/camera/blob/B = new /mob/camera/blob(loc, starting_points)
|
||||
B.key = key
|
||||
. = B
|
||||
qdel(src)
|
||||
|
||||
|
||||
+114
-112
@@ -1,112 +1,114 @@
|
||||
/datum/orbit
|
||||
var/atom/movable/orbiter
|
||||
var/atom/orbiting
|
||||
var/lock = TRUE
|
||||
var/turf/lastloc
|
||||
var/lastprocess
|
||||
|
||||
/datum/orbit/New(_orbiter, _orbiting, _lock)
|
||||
orbiter = _orbiter
|
||||
orbiting = _orbiting
|
||||
SSorbit.processing += src
|
||||
if (!orbiting.orbiters)
|
||||
orbiting.orbiters = list()
|
||||
orbiting.orbiters += src
|
||||
|
||||
if (orbiter.orbiting)
|
||||
orbiter.stop_orbit()
|
||||
orbiter.orbiting = src
|
||||
Check()
|
||||
lock = _lock
|
||||
|
||||
|
||||
|
||||
//do not qdel directly, use stop_orbit on the orbiter. (This way the orbiter can bind to the orbit stopping)
|
||||
/datum/orbit/Destroy(force = FALSE)
|
||||
SSorbit.processing -= src
|
||||
if (orbiter)
|
||||
orbiter.orbiting = null
|
||||
orbiter = null
|
||||
if (orbiting)
|
||||
if (orbiting.orbiters)
|
||||
orbiting.orbiters -= src
|
||||
if (!orbiting.orbiters.len)//we are the last orbit, delete the list
|
||||
orbiting.orbiters = null
|
||||
orbiting = null
|
||||
return ..()
|
||||
|
||||
/datum/orbit/proc/Check(turf/targetloc)
|
||||
if (!orbiter)
|
||||
qdel(src)
|
||||
return
|
||||
if (!orbiting)
|
||||
orbiter.stop_orbit()
|
||||
return
|
||||
if (!orbiter.orbiting) //admin wants to stop the orbit.
|
||||
orbiter.orbiting = src //set it back to us first
|
||||
orbiter.stop_orbit()
|
||||
lastprocess = world.time
|
||||
if (!targetloc)
|
||||
targetloc = get_turf(orbiting)
|
||||
if (!targetloc || (!lock && orbiter.loc != lastloc && orbiter.loc != targetloc))
|
||||
orbiter.stop_orbit()
|
||||
return
|
||||
orbiter.loc = targetloc
|
||||
orbiter.update_parallax_contents()
|
||||
lastloc = orbiter.loc
|
||||
|
||||
|
||||
/atom/movable/var/datum/orbit/orbiting = null
|
||||
/atom/var/list/orbiters = null
|
||||
|
||||
//A: atom to orbit
|
||||
//radius: range to orbit at, radius of the circle formed by orbiting (in pixels)
|
||||
//clockwise: whether you orbit clockwise or anti clockwise
|
||||
//rotation_speed: how fast to rotate (how many ds should it take for a rotation to complete)
|
||||
//rotation_segments: the resolution of the orbit circle, less = a more block circle, this can be used to produce hexagons (6 segments) triangles (3 segments), and so on, 36 is the best default.
|
||||
//pre_rotation: Chooses to rotate src 90 degress towards the orbit dir (clockwise/anticlockwise), useful for things to go "head first" like ghosts
|
||||
//lockinorbit: Forces src to always be on A's turf, otherwise the orbit cancels when src gets too far away (eg: ghosts)
|
||||
|
||||
/atom/movable/proc/orbit(atom/A, radius = 10, clockwise = FALSE, rotation_speed = 20, rotation_segments = 36, pre_rotation = TRUE, lockinorbit = FALSE)
|
||||
if (!istype(A))
|
||||
return
|
||||
|
||||
new/datum/orbit(src, A, lockinorbit)
|
||||
if (!orbiting) //something failed, and our orbit datum deleted itself
|
||||
return
|
||||
var/matrix/initial_transform = matrix(transform)
|
||||
|
||||
//Head first!
|
||||
if (pre_rotation)
|
||||
var/matrix/M = matrix(transform)
|
||||
var/pre_rot = 90
|
||||
if(!clockwise)
|
||||
pre_rot = -90
|
||||
M.Turn(pre_rot)
|
||||
transform = M
|
||||
|
||||
var/matrix/shift = matrix(transform)
|
||||
shift.Translate(0,radius)
|
||||
transform = shift
|
||||
|
||||
SpinAnimation(rotation_speed, -1, clockwise, rotation_segments)
|
||||
|
||||
//we stack the orbits up client side, so we can assign this back to normal server side without it breaking the orbit
|
||||
transform = initial_transform
|
||||
|
||||
/atom/movable/proc/stop_orbit()
|
||||
SpinAnimation(0,0)
|
||||
qdel(orbiting)
|
||||
|
||||
/atom/Destroy(force = FALSE)
|
||||
. = ..()
|
||||
if (orbiters)
|
||||
for (var/thing in orbiters)
|
||||
var/datum/orbit/O = thing
|
||||
if (O.orbiter)
|
||||
O.orbiter.stop_orbit()
|
||||
|
||||
/atom/movable/Destroy(force = FALSE)
|
||||
. = ..()
|
||||
if (orbiting)
|
||||
stop_orbit()
|
||||
/datum/orbit
|
||||
var/atom/movable/orbiter
|
||||
var/atom/orbiting
|
||||
var/lock = TRUE
|
||||
var/turf/lastloc
|
||||
var/lastprocess
|
||||
|
||||
/datum/orbit/New(_orbiter, _orbiting, _lock)
|
||||
orbiter = _orbiter
|
||||
orbiting = _orbiting
|
||||
SSorbit.processing += src
|
||||
if (!orbiting.orbiters)
|
||||
orbiting.orbiters = list()
|
||||
orbiting.orbiters += src
|
||||
|
||||
if (orbiter.orbiting)
|
||||
orbiter.stop_orbit()
|
||||
orbiter.orbiting = src
|
||||
Check()
|
||||
lock = _lock
|
||||
|
||||
//do not qdel directly, use stop_orbit on the orbiter. (This way the orbiter can bind to the orbit stopping)
|
||||
/datum/orbit/Destroy(force = FALSE)
|
||||
SSorbit.processing -= src
|
||||
if (orbiter)
|
||||
orbiter.orbiting = null
|
||||
orbiter = null
|
||||
if (orbiting)
|
||||
if (orbiting.orbiters)
|
||||
orbiting.orbiters -= src
|
||||
if (!orbiting.orbiters.len)//we are the last orbit, delete the list
|
||||
orbiting.orbiters = null
|
||||
orbiting = null
|
||||
return ..()
|
||||
|
||||
/datum/orbit/proc/Check(turf/targetloc)
|
||||
if (!orbiter)
|
||||
qdel(src)
|
||||
return
|
||||
if (!orbiting)
|
||||
orbiter.stop_orbit()
|
||||
return
|
||||
if (!orbiter.orbiting) //admin wants to stop the orbit.
|
||||
orbiter.orbiting = src //set it back to us first
|
||||
orbiter.stop_orbit()
|
||||
lastprocess = world.time
|
||||
if (!targetloc)
|
||||
targetloc = get_turf(orbiting)
|
||||
if (!targetloc || (!lock && orbiter.loc != lastloc && orbiter.loc != targetloc))
|
||||
orbiter.stop_orbit()
|
||||
return
|
||||
orbiter.loc = targetloc
|
||||
orbiter.update_parallax_contents()
|
||||
lastloc = orbiter.loc
|
||||
for(var/other_orbit in orbiter.orbiters)
|
||||
var/datum/orbit/OO = other_orbit
|
||||
if(OO == src)
|
||||
continue
|
||||
OO.Check(targetloc)
|
||||
|
||||
/atom/movable/var/datum/orbit/orbiting = null
|
||||
/atom/var/list/orbiters = null
|
||||
|
||||
//A: atom to orbit
|
||||
//radius: range to orbit at, radius of the circle formed by orbiting (in pixels)
|
||||
//clockwise: whether you orbit clockwise or anti clockwise
|
||||
//rotation_speed: how fast to rotate (how many ds should it take for a rotation to complete)
|
||||
//rotation_segments: the resolution of the orbit circle, less = a more block circle, this can be used to produce hexagons (6 segments) triangles (3 segments), and so on, 36 is the best default.
|
||||
//pre_rotation: Chooses to rotate src 90 degress towards the orbit dir (clockwise/anticlockwise), useful for things to go "head first" like ghosts
|
||||
//lockinorbit: Forces src to always be on A's turf, otherwise the orbit cancels when src gets too far away (eg: ghosts)
|
||||
|
||||
/atom/movable/proc/orbit(atom/A, radius = 10, clockwise = FALSE, rotation_speed = 20, rotation_segments = 36, pre_rotation = TRUE, lockinorbit = FALSE)
|
||||
if (!istype(A))
|
||||
return
|
||||
|
||||
new/datum/orbit(src, A, lockinorbit)
|
||||
if (!orbiting) //something failed, and our orbit datum deleted itself
|
||||
return
|
||||
var/matrix/initial_transform = matrix(transform)
|
||||
|
||||
//Head first!
|
||||
if (pre_rotation)
|
||||
var/matrix/M = matrix(transform)
|
||||
var/pre_rot = 90
|
||||
if(!clockwise)
|
||||
pre_rot = -90
|
||||
M.Turn(pre_rot)
|
||||
transform = M
|
||||
|
||||
var/matrix/shift = matrix(transform)
|
||||
shift.Translate(0,radius)
|
||||
transform = shift
|
||||
|
||||
SpinAnimation(rotation_speed, -1, clockwise, rotation_segments)
|
||||
|
||||
//we stack the orbits up client side, so we can assign this back to normal server side without it breaking the orbit
|
||||
transform = initial_transform
|
||||
|
||||
/atom/movable/proc/stop_orbit()
|
||||
SpinAnimation(0,0)
|
||||
qdel(orbiting)
|
||||
|
||||
/atom/Destroy(force = FALSE)
|
||||
. = ..()
|
||||
if (orbiters)
|
||||
for (var/thing in orbiters)
|
||||
var/datum/orbit/O = thing
|
||||
if (O.orbiter)
|
||||
O.orbiter.stop_orbit()
|
||||
|
||||
/atom/movable/Destroy(force = FALSE)
|
||||
. = ..()
|
||||
if (orbiting)
|
||||
stop_orbit()
|
||||
|
||||
@@ -25,10 +25,6 @@
|
||||
P.loc = src
|
||||
bin_pen = P
|
||||
update_icon()
|
||||
var/static/warned = FALSE
|
||||
if(P.type == /obj/item/pen && !warned)
|
||||
warning("one or more paperbins ate a pen duing initialize()")
|
||||
warned = TRUE
|
||||
|
||||
/obj/item/paper_bin/fire_act(exposed_temperature, exposed_volume)
|
||||
if(!total_paper)
|
||||
|
||||
@@ -78,7 +78,6 @@
|
||||
powernet = 0 // set so that APCs aren't found as powernet nodes //Hackish, Horrible, was like this before I changed it :(
|
||||
var/malfhack = 0 //New var for my changes to AI malf. --NeoFite
|
||||
var/mob/living/silicon/ai/malfai = null //See above --NeoFite
|
||||
// luminosity = 1
|
||||
var/has_electronics = 0 // 0 - none, 1 - plugged in, 2 - secured by screwdriver
|
||||
var/overload = 1 //used for the Blackout malf module
|
||||
var/beenhit = 0 // used for counting how many times it has been hit, used for Aliens at the moment
|
||||
|
||||
+44
-75
@@ -1,3 +1,14 @@
|
||||
GLOBAL_LIST_INIT(cable_colors, list(
|
||||
"yellow" = "#ffff00",
|
||||
"green" = "#00aa00",
|
||||
"blue" = "#1919c8",
|
||||
"pink" = "#ff3cc8",
|
||||
"orange" = "#ff8000",
|
||||
"cyan" = "#00ffff",
|
||||
"white" = "#ffffff",
|
||||
"red" = "#ff0000"
|
||||
))
|
||||
|
||||
///////////////////////////////
|
||||
//CABLE STRUCTURE
|
||||
///////////////////////////////
|
||||
@@ -23,61 +34,52 @@ By design, d1 is the smallest direction and d2 is the highest
|
||||
*/
|
||||
|
||||
/obj/structure/cable
|
||||
level = 1 //is underfloor
|
||||
anchored =1
|
||||
on_blueprints = TRUE
|
||||
var/datum/powernet/powernet
|
||||
name = "power cable"
|
||||
desc = "A flexible, superconducting insulated cable for heavy-duty power transfer."
|
||||
icon = 'icons/obj/power_cond/power_cond_red.dmi'
|
||||
icon = 'icons/obj/power_cond/cables.dmi'
|
||||
icon_state = "0-1"
|
||||
level = 1 //is underfloor
|
||||
layer = WIRE_LAYER //Above hidden pipes, GAS_PIPE_HIDDEN_LAYER
|
||||
anchored = TRUE
|
||||
on_blueprints = TRUE
|
||||
var/d1 = 0 // cable direction 1 (see above)
|
||||
var/d2 = 1 // cable direction 2 (see above)
|
||||
layer = WIRE_LAYER //Above hidden pipes, GAS_PIPE_HIDDEN_LAYER
|
||||
var/cable_color = "red"
|
||||
var/datum/powernet/powernet
|
||||
var/obj/item/stack/cable_coil/stored
|
||||
|
||||
var/cable_color = "red"
|
||||
|
||||
/obj/structure/cable/yellow
|
||||
cable_color = "yellow"
|
||||
icon = 'icons/obj/power_cond/power_cond_yellow.dmi'
|
||||
|
||||
/obj/structure/cable/green
|
||||
cable_color = "green"
|
||||
icon = 'icons/obj/power_cond/power_cond_green.dmi'
|
||||
|
||||
/obj/structure/cable/blue
|
||||
cable_color = "blue"
|
||||
icon = 'icons/obj/power_cond/power_cond_blue.dmi'
|
||||
|
||||
/obj/structure/cable/pink
|
||||
cable_color = "pink"
|
||||
icon = 'icons/obj/power_cond/power_cond_pink.dmi'
|
||||
|
||||
/obj/structure/cable/orange
|
||||
cable_color = "orange"
|
||||
icon = 'icons/obj/power_cond/power_cond_orange.dmi'
|
||||
|
||||
/obj/structure/cable/cyan
|
||||
cable_color = "cyan"
|
||||
icon = 'icons/obj/power_cond/power_cond_cyan.dmi'
|
||||
|
||||
/obj/structure/cable/white
|
||||
cable_color = "white"
|
||||
icon = 'icons/obj/power_cond/power_cond_white.dmi'
|
||||
|
||||
// the power cable object
|
||||
/obj/structure/cable/Initialize()
|
||||
/obj/structure/cable/Initialize(mapload, param_color)
|
||||
. = ..()
|
||||
|
||||
// ensure d1 & d2 reflect the icon_state for entering and exiting cable
|
||||
var/dash = findtext(icon_state, "-")
|
||||
|
||||
d1 = text2num( copytext( icon_state, 1, dash ) )
|
||||
|
||||
d2 = text2num( copytext( icon_state, dash+1 ) )
|
||||
|
||||
var/turf/T = get_turf(src) // hide if turf is not intact
|
||||
|
||||
if(level==1)
|
||||
hide(T.intact)
|
||||
GLOB.cable_list += src //add it to the global cable list
|
||||
@@ -87,6 +89,12 @@ By design, d1 is the smallest direction and d2 is the highest
|
||||
else
|
||||
stored = new/obj/item/stack/cable_coil(null,1,cable_color)
|
||||
|
||||
var/list/cable_colors = GLOB.cable_colors
|
||||
cable_color = param_color || cable_color || pick(cable_colors)
|
||||
if(cable_colors[cable_color])
|
||||
cable_color = cable_colors[cable_color]
|
||||
update_icon()
|
||||
|
||||
/obj/structure/cable/Destroy() // called when a cable is deleted
|
||||
if(powernet)
|
||||
cut_cable_from_powernet() // update the powernets
|
||||
@@ -115,6 +123,7 @@ By design, d1 is the smallest direction and d2 is the highest
|
||||
icon_state = "[d1]-[d2]-f"
|
||||
else
|
||||
icon_state = "[d1]-[d2]"
|
||||
add_atom_colour(cable_color, FIXED_COLOUR_PRIORITY)
|
||||
|
||||
/obj/structure/cable/proc/handlecable(obj/item/W, mob/user, params)
|
||||
var/turf/T = get_turf(src)
|
||||
@@ -175,26 +184,6 @@ By design, d1 is the smallest direction and d2 is the highest
|
||||
if(current_size >= STAGE_FIVE)
|
||||
deconstruct()
|
||||
|
||||
/obj/structure/cable/proc/cableColor(colorC = "red")
|
||||
cable_color = colorC
|
||||
switch(colorC)
|
||||
if("red")
|
||||
icon = 'icons/obj/power_cond/power_cond_red.dmi'
|
||||
if("yellow")
|
||||
icon = 'icons/obj/power_cond/power_cond_yellow.dmi'
|
||||
if("green")
|
||||
icon = 'icons/obj/power_cond/power_cond_green.dmi'
|
||||
if("blue")
|
||||
icon = 'icons/obj/power_cond/power_cond_blue.dmi'
|
||||
if("pink")
|
||||
icon = 'icons/obj/power_cond/power_cond_pink.dmi'
|
||||
if("orange")
|
||||
icon = 'icons/obj/power_cond/power_cond_orange.dmi'
|
||||
if("cyan")
|
||||
icon = 'icons/obj/power_cond/power_cond_cyan.dmi'
|
||||
if("white")
|
||||
icon = 'icons/obj/power_cond/power_cond_white.dmi'
|
||||
|
||||
/obj/structure/cable/proc/update_stored(length = 1, colorC = "red")
|
||||
stored.amount = length
|
||||
stored.item_color = colorC
|
||||
@@ -456,8 +445,8 @@ GLOBAL_LIST_INIT(cable_coil_recipes, list (new/datum/stack_recipe("cable restrai
|
||||
name = "cable coil"
|
||||
gender = NEUTER //That's a cable coil sounds better than that's some cable coils
|
||||
icon = 'icons/obj/power.dmi'
|
||||
icon_state = "coil_red"
|
||||
item_state = "coil_red"
|
||||
icon_state = "coil"
|
||||
item_state = "coil"
|
||||
lefthand_file = 'icons/mob/inhands/equipment/tools_lefthand.dmi'
|
||||
righthand_file = 'icons/mob/inhands/equipment/tools_righthand.dmi'
|
||||
max_amount = MAXCOIL
|
||||
@@ -497,8 +486,12 @@ GLOBAL_LIST_INIT(cable_coil_recipes, list (new/datum/stack_recipe("cable restrai
|
||||
. = ..()
|
||||
if(new_amount) // MAXCOIL by default
|
||||
amount = new_amount
|
||||
if(param_color)
|
||||
item_color = param_color
|
||||
|
||||
var/list/cable_colors = GLOB.cable_colors
|
||||
item_color = param_color || item_color || pick(cable_colors)
|
||||
if(cable_colors[item_color])
|
||||
item_color = cable_colors[item_color]
|
||||
|
||||
pixel_x = rand(-2,2)
|
||||
pixel_y = rand(-2,2)
|
||||
update_icon()
|
||||
@@ -528,18 +521,9 @@ GLOBAL_LIST_INIT(cable_coil_recipes, list (new/datum/stack_recipe("cable restrai
|
||||
|
||||
|
||||
/obj/item/stack/cable_coil/update_icon()
|
||||
if(!item_color)
|
||||
item_color = pick("red", "yellow", "blue", "green")
|
||||
item_state = "coil_[item_color]"
|
||||
if(amount == 1)
|
||||
icon_state = "coil_[item_color]1"
|
||||
name = "cable piece"
|
||||
else if(amount == 2)
|
||||
icon_state = "coil_[item_color]2"
|
||||
name = "cable piece"
|
||||
else
|
||||
icon_state = "coil_[item_color]"
|
||||
name = "cable coil"
|
||||
icon_state = "[initial(item_state)][amount < 3 ? amount : ""]"
|
||||
name = "cable [amount < 3 ? "piece" : "coil"]"
|
||||
add_atom_colour(item_color, FIXED_COLOUR_PRIORITY)
|
||||
|
||||
/obj/item/stack/cable_coil/attack_hand(mob/user)
|
||||
var/obj/item/stack/cable_coil/new_cable = ..()
|
||||
@@ -562,8 +546,8 @@ GLOBAL_LIST_INIT(cable_coil_recipes, list (new/datum/stack_recipe("cable restrai
|
||||
//////////////////////////////////////////////
|
||||
|
||||
/obj/item/stack/cable_coil/proc/get_new_cable(location)
|
||||
var/path = "/obj/structure/cable" + (item_color == "red" ? "" : "/" + item_color)
|
||||
return new path (location)
|
||||
var/path = /obj/structure/cable
|
||||
return new path(location, item_color)
|
||||
|
||||
// called when cable_coil is clicked on a turf
|
||||
/obj/item/stack/cable_coil/proc/place_turf(turf/T, mob/user, dirnew)
|
||||
@@ -714,7 +698,7 @@ GLOBAL_LIST_INIT(cable_coil_recipes, list (new/datum/stack_recipe("cable restrai
|
||||
return
|
||||
|
||||
|
||||
C.cableColor(item_color)
|
||||
C.update_icon()
|
||||
|
||||
C.d1 = nd1
|
||||
C.d2 = nd2
|
||||
@@ -750,11 +734,8 @@ GLOBAL_LIST_INIT(cable_coil_recipes, list (new/datum/stack_recipe("cable restrai
|
||||
// Misc.
|
||||
/////////////////////////////
|
||||
|
||||
/obj/item/stack/cable_coil/cut
|
||||
item_state = "coil_red2"
|
||||
|
||||
/obj/item/stack/cable_coil/cut/Initialize(mapload)
|
||||
. =..()
|
||||
. = ..()
|
||||
amount = rand(1,2)
|
||||
pixel_x = rand(-2,2)
|
||||
pixel_y = rand(-2,2)
|
||||
@@ -762,42 +743,30 @@ GLOBAL_LIST_INIT(cable_coil_recipes, list (new/datum/stack_recipe("cable restrai
|
||||
|
||||
/obj/item/stack/cable_coil/red
|
||||
item_color = "red"
|
||||
icon_state = "coil_red"
|
||||
|
||||
/obj/item/stack/cable_coil/yellow
|
||||
item_color = "yellow"
|
||||
icon_state = "coil_yellow"
|
||||
|
||||
/obj/item/stack/cable_coil/blue
|
||||
item_color = "blue"
|
||||
icon_state = "coil_blue"
|
||||
item_state = "coil_blue"
|
||||
|
||||
/obj/item/stack/cable_coil/green
|
||||
item_color = "green"
|
||||
icon_state = "coil_green"
|
||||
|
||||
/obj/item/stack/cable_coil/pink
|
||||
item_color = "pink"
|
||||
icon_state = "coil_pink"
|
||||
|
||||
/obj/item/stack/cable_coil/orange
|
||||
item_color = "orange"
|
||||
icon_state = "coil_orange"
|
||||
|
||||
/obj/item/stack/cable_coil/cyan
|
||||
item_color = "cyan"
|
||||
icon_state = "coil_cyan"
|
||||
|
||||
/obj/item/stack/cable_coil/white
|
||||
item_color = "white"
|
||||
icon_state = "coil_white"
|
||||
|
||||
/obj/item/stack/cable_coil/random/Initialize(mapload)
|
||||
. = ..()
|
||||
item_color = pick("red","orange","yellow","green","cyan","blue","pink","white")
|
||||
icon_state = "coil_[item_color]"
|
||||
|
||||
/obj/item/stack/cable_coil/random
|
||||
item_color = null
|
||||
|
||||
/obj/item/stack/cable_coil/random/five
|
||||
amount = 5
|
||||
|
||||
@@ -15,6 +15,15 @@
|
||||
var/power_output = 1
|
||||
var/consumption = 0
|
||||
var/base_icon = "portgen0"
|
||||
var/datum/looping_sound/generator/soundloop
|
||||
|
||||
/obj/machinery/power/port_gen/Initialize()
|
||||
. = ..()
|
||||
soundloop = new(list(src), active)
|
||||
|
||||
/obj/machinery/power/port_gen/Destroy()
|
||||
QDEL_NULL(soundloop)
|
||||
return ..()
|
||||
|
||||
/obj/machinery/power/port_gen/proc/HasFuel() //Placeholder for fuel check.
|
||||
return 1
|
||||
@@ -36,11 +45,13 @@
|
||||
add_avail(power_gen * power_output)
|
||||
UseFuel()
|
||||
src.updateDialog()
|
||||
soundloop.start()
|
||||
|
||||
else
|
||||
active = 0
|
||||
handleInactive()
|
||||
update_icon()
|
||||
soundloop.stop()
|
||||
|
||||
/obj/machinery/power/port_gen/attack_hand(mob/user)
|
||||
if(..())
|
||||
|
||||
@@ -9,7 +9,7 @@
|
||||
density = FALSE
|
||||
resistance_flags = INDESTRUCTIBLE | LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF
|
||||
use_power = NO_POWER_USE
|
||||
luminosity = 4
|
||||
light_range = 4
|
||||
layer = ABOVE_OBJ_LAYER
|
||||
var/obj/machinery/field/generator/FG1 = null
|
||||
var/obj/machinery/field/generator/FG2 = null
|
||||
|
||||
@@ -142,7 +142,7 @@
|
||||
|
||||
for(var/mob/living/carbon/food in GLOB.living_mob_list) //we don't care about constructs or cult-Ians or whatever. cult-monkeys are fair game i guess
|
||||
var/turf/pos = get_turf(food)
|
||||
if(pos.z != src.z)
|
||||
if(!pos || (pos.z != z))
|
||||
continue
|
||||
|
||||
if(iscultist(food))
|
||||
@@ -163,7 +163,7 @@
|
||||
if(!ghost.client)
|
||||
continue
|
||||
var/turf/pos = get_turf(ghost)
|
||||
if(pos.z != src.z)
|
||||
if(!pos || (pos.z != z))
|
||||
continue
|
||||
cultists += ghost
|
||||
if(cultists.len)
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
anchored = TRUE
|
||||
density = TRUE
|
||||
layer = MASSIVE_OBJ_LAYER
|
||||
luminosity = 6
|
||||
light_range = 6
|
||||
appearance_flags = 0
|
||||
var/current_size = 1
|
||||
var/allowed_size = 1
|
||||
@@ -278,7 +278,7 @@
|
||||
desc = "[initial(desc)] It glows fiercely with inner fire."
|
||||
name = "supermatter-charged [initial(name)]"
|
||||
consumedSupermatter = 1
|
||||
luminosity = 10
|
||||
set_light(10)
|
||||
return
|
||||
|
||||
|
||||
|
||||
@@ -9,7 +9,6 @@
|
||||
|
||||
#define OXYGEN_TRANSMIT_MODIFIER 1.5 //Higher == Bigger bonus to power generation.
|
||||
#define PLASMA_TRANSMIT_MODIFIER 4
|
||||
#define FREON_TRANSMIT_PENALTY 0.75 // Scales how much freon reduces total power transmission. 1 equals 1% per 1% of freon in the mix.
|
||||
|
||||
#define N2O_HEAT_RESISTANCE 6 //Higher == Gas makes the crystal more resistant against heat damage.
|
||||
|
||||
@@ -30,7 +29,7 @@
|
||||
#define THERMAL_RELEASE_MODIFIER 5 //Higher == less heat released during reaction, not to be confused with the above values
|
||||
#define PLASMA_RELEASE_MODIFIER 750 //Higher == less plasma released by reaction
|
||||
#define OXYGEN_RELEASE_MODIFIER 325 //Higher == less oxygen released at high temperature/power
|
||||
#define FREON_BREEDING_MODIFIER 100 //Higher == less freon created
|
||||
|
||||
#define REACTION_POWER_MODIFIER 0.55 //Higher == more overall power
|
||||
|
||||
#define MATTER_POWER_CONVERSION 10 //Crystal converts 1/this value of stored matter into energy.
|
||||
@@ -92,7 +91,6 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_shard)
|
||||
var/power = 0
|
||||
|
||||
var/n2comp = 0 // raw composition of each gas in the chamber, ranges from 0 to 1
|
||||
var/freoncomp = 0
|
||||
|
||||
var/plasmacomp = 0
|
||||
var/o2comp = 0
|
||||
@@ -107,7 +105,7 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_shard)
|
||||
var/powerloss_dynamic_scaling= 0
|
||||
var/power_transmission_bonus = 0
|
||||
var/mole_heat_penalty = 0
|
||||
var/freon_transmit_modifier = 1
|
||||
|
||||
|
||||
var/matter_power = 0
|
||||
|
||||
@@ -135,6 +133,8 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_shard)
|
||||
|
||||
var/is_main_engine = FALSE
|
||||
|
||||
var/datum/looping_sound/supermatter/soundloop
|
||||
|
||||
/obj/machinery/power/supermatter_shard/Initialize()
|
||||
. = ..()
|
||||
SSair.atmos_machinery += src
|
||||
@@ -149,6 +149,8 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_shard)
|
||||
if(is_main_engine)
|
||||
GLOB.main_supermatter_engine = src
|
||||
|
||||
soundloop = new(list(src), TRUE)
|
||||
|
||||
/obj/machinery/power/supermatter_shard/Destroy()
|
||||
investigate_log("has been destroyed.", INVESTIGATE_SUPERMATTER)
|
||||
SSair.atmos_machinery -= src
|
||||
@@ -157,7 +159,8 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_shard)
|
||||
QDEL_NULL(countdown)
|
||||
if(is_main_engine && GLOB.main_supermatter_engine == src)
|
||||
GLOB.main_supermatter_engine = null
|
||||
. = ..()
|
||||
QDEL_NULL(soundloop)
|
||||
return ..()
|
||||
|
||||
/obj/machinery/power/supermatter_shard/examine(mob/user)
|
||||
..()
|
||||
@@ -251,6 +254,9 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_shard)
|
||||
if(!istype(T)) //We are in a crate or somewhere that isn't turf, if we return to turf resume processing but for now.
|
||||
return //Yeah just stop.
|
||||
|
||||
if(power)
|
||||
soundloop.volume = min(50, (round(power, 50)/50)+1) // 5 +1 volume per 20 power. 2500 power is max
|
||||
|
||||
//Ok, get the air from the turf
|
||||
var/datum/gas_mixture/env = T.return_air()
|
||||
|
||||
@@ -284,7 +290,7 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_shard)
|
||||
if(damage > damage_archived && prob(10))
|
||||
playsound(get_turf(src), 'sound/effects/empulse.ogg', 50, 1)
|
||||
|
||||
removed.assert_gases(/datum/gas/oxygen, /datum/gas/plasma, /datum/gas/carbon_dioxide, /datum/gas/nitrous_oxide, /datum/gas/nitrogen, /datum/gas/freon)
|
||||
removed.assert_gases(/datum/gas/oxygen, /datum/gas/plasma, /datum/gas/carbon_dioxide, /datum/gas/nitrous_oxide, /datum/gas/nitrogen)
|
||||
//calculating gas related values
|
||||
combined_gas = max(removed.total_moles(), 0)
|
||||
|
||||
@@ -294,16 +300,15 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_shard)
|
||||
|
||||
n2ocomp = max(removed.gases[/datum/gas/nitrous_oxide][MOLES]/combined_gas, 0)
|
||||
n2comp = max(removed.gases[/datum/gas/nitrogen][MOLES]/combined_gas, 0)
|
||||
freoncomp = max(removed.gases[/datum/gas/freon][MOLES]/combined_gas, 0)
|
||||
|
||||
gasmix_power_ratio = min(max(plasmacomp + o2comp + co2comp - n2comp - freoncomp, 0), 1)
|
||||
gasmix_power_ratio = min(max(plasmacomp + o2comp + co2comp - n2comp, 0), 1)
|
||||
|
||||
dynamic_heat_modifier = max((plasmacomp * PLASMA_HEAT_PENALTY)+(o2comp * OXYGEN_HEAT_PENALTY)+(co2comp * CO2_HEAT_PENALTY)+(n2comp * NITROGEN_HEAT_MODIFIER), 0.5)
|
||||
dynamic_heat_resistance = max(n2ocomp * N2O_HEAT_RESISTANCE, 1)
|
||||
|
||||
power_transmission_bonus = max((plasmacomp * PLASMA_TRANSMIT_MODIFIER) + (o2comp * OXYGEN_TRANSMIT_MODIFIER), 0)
|
||||
|
||||
freon_transmit_modifier = max(1-(freoncomp * FREON_TRANSMIT_PENALTY), 0)
|
||||
|
||||
|
||||
//more moles of gases are harder to heat than fewer, so let's scale heat damage around them
|
||||
mole_heat_penalty = max(combined_gas / MOLE_HEAT_PENALTY, 0.25)
|
||||
@@ -332,7 +337,7 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_shard)
|
||||
power = max( (removed.temperature * temp_factor / T0C) * gasmix_power_ratio + power, 0) //Total laser power plus an overload
|
||||
|
||||
if(prob(50))
|
||||
radiation_pulse(src, power * (1 + power_transmission_bonus/10 * freon_transmit_modifier))
|
||||
radiation_pulse(src, power * (1 + power_transmission_bonus/10))
|
||||
|
||||
var/device_energy = power * REACTION_POWER_MODIFIER
|
||||
|
||||
@@ -352,9 +357,6 @@ GLOBAL_DATUM(main_supermatter_engine, /obj/machinery/power/supermatter_shard)
|
||||
|
||||
removed.gases[/datum/gas/oxygen][MOLES] += max(((device_energy + removed.temperature * dynamic_heat_modifier) - T0C) / OXYGEN_RELEASE_MODIFIER, 0)
|
||||
|
||||
if(combined_gas < 50)
|
||||
removed.gases[/datum/gas/freon][MOLES] = max((removed.gases[/datum/gas/freon][MOLES] + device_energy) * freoncomp / FREON_BREEDING_MODIFIER, 0)
|
||||
|
||||
if(produces_gas)
|
||||
env.merge(removed)
|
||||
air_update_turf()
|
||||
|
||||
@@ -32,7 +32,7 @@
|
||||
|
||||
/datum/mapGeneratorModule/bottomLayer/massdelete/no_delete_mobs/New()
|
||||
..()
|
||||
ignore_typecache = typecacheof(list(/mob))
|
||||
ignore_typecache = GLOB.typecache_mob
|
||||
|
||||
/datum/mapGeneratorModule/bottomLayer/massdelete/leave_turfs
|
||||
deleteturfs = FALSE
|
||||
@@ -42,7 +42,7 @@
|
||||
|
||||
/datum/mapGeneratorModule/bottomLayer/massdelete/regeneration_delete/New()
|
||||
..()
|
||||
ignore_typecache = typecacheof(list(/mob))
|
||||
ignore_typecache = GLOB.typecache_mob
|
||||
|
||||
//Only places atoms/turfs on area borders
|
||||
/datum/mapGeneratorModule/border
|
||||
|
||||
@@ -220,7 +220,7 @@
|
||||
var/mob/M = safepick(mobs)
|
||||
if(M)
|
||||
return M.lowest_buckled_mob()
|
||||
var/obj/O = safepick(typecache_filter_list(T, GLOB.typecache_machine_or_structure)) - A
|
||||
var/obj/O = safepick(typecache_filter_list(T, GLOB.typecache_machine_or_structure) - A)
|
||||
if(O)
|
||||
return O
|
||||
|
||||
|
||||
@@ -132,16 +132,14 @@
|
||||
if("monkey")
|
||||
new_mob = new /mob/living/carbon/monkey(M.loc)
|
||||
if("robot")
|
||||
var/robot = pick("cyborg","syndiborg","drone")
|
||||
var/robot = pick("random_cyborg","syndiborg","drone")
|
||||
var/path
|
||||
switch(robot)
|
||||
if("cyborg")
|
||||
new_mob = new /mob/living/silicon/robot(M.loc)
|
||||
if("random_cyborg")
|
||||
path = pick(typesof(/mob/living/silicon/robot/modules) - typesof(/mob/living/silicon/robot/modules/syndicate))
|
||||
new_mob = new path(M.loc)
|
||||
if("syndiborg")
|
||||
var/path
|
||||
if(prob(50))
|
||||
path = /mob/living/silicon/robot/modules/syndicate
|
||||
else
|
||||
path = /mob/living/silicon/robot/modules/syndicate/medical
|
||||
path = pick(typesof(/mob/living/silicon/robot/modules/syndicate))
|
||||
new_mob = new path(M.loc)
|
||||
if("drone")
|
||||
new_mob = new /mob/living/simple_animal/drone/polymorphed(M.loc)
|
||||
@@ -158,9 +156,15 @@
|
||||
new_mob = new /mob/living/simple_animal/slime/random(M.loc)
|
||||
if("xeno")
|
||||
if(prob(50))
|
||||
new_mob = new /mob/living/carbon/alien/humanoid/hunter(M.loc)
|
||||
if(!M.ckey) //spawn an AI alien if it isn't a player controlled mob.
|
||||
new_mob = new /mob/living/simple_animal/hostile/alien(M.loc)
|
||||
else
|
||||
new_mob = new /mob/living/carbon/alien/humanoid/hunter(M.loc)
|
||||
else
|
||||
new_mob = new /mob/living/carbon/alien/humanoid/sentinel(M.loc)
|
||||
if(!M.ckey)
|
||||
new_mob = new /mob/living/simple_animal/hostile/alien/sentinel(M.loc)
|
||||
else
|
||||
new_mob = new /mob/living/carbon/alien/humanoid/sentinel(M.loc)
|
||||
|
||||
if("animal")
|
||||
var/path
|
||||
|
||||
@@ -285,7 +285,9 @@
|
||||
updateUsrDialog()
|
||||
|
||||
/obj/machinery/reagentgrinder/proc/get_allowed_by_obj(obj/item/O)
|
||||
return blend_items[O.type]
|
||||
for (var/i in blend_items)
|
||||
if (istype(O, i))
|
||||
return blend_items[i]
|
||||
|
||||
/obj/machinery/reagentgrinder/proc/get_allowed_juice_by_obj(obj/item/reagent_containers/food/snacks/O)
|
||||
for(var/i in juice_items)
|
||||
@@ -433,7 +435,7 @@
|
||||
if (O.Uses > 0)
|
||||
beaker.reagents.add_reagent("slimejelly",min(20, space))
|
||||
remove_object(O)
|
||||
else if(istype(I, /obj/item/reagent_containers))
|
||||
if(istype(I, /obj/item/reagent_containers))
|
||||
var/obj/item/reagent_containers/O = I
|
||||
var/amount = O.reagents.total_volume
|
||||
O.reagents.trans_to(beaker, amount)
|
||||
|
||||
@@ -466,7 +466,7 @@
|
||||
metabolization_rate = 0.5 * REAGENTS_METABOLISM
|
||||
|
||||
/datum/reagent/medicine/pen_acid/on_mob_life(mob/living/M)
|
||||
M.radiation -= min(M.radiation-RAD_MOB_SAFE, 0)/100
|
||||
M.radiation -= max(M.radiation-RAD_MOB_SAFE, 0)/100
|
||||
M.adjustToxLoss(-2*REM, 0)
|
||||
for(var/datum/reagent/R in M.reagents.reagent_list)
|
||||
if(R != src)
|
||||
|
||||
@@ -1159,6 +1159,34 @@
|
||||
M.confused = min(M.confused + 2, 5)
|
||||
..()
|
||||
|
||||
/datum/reagent/stimulum
|
||||
name = "Stimulum"
|
||||
id = "stimulum"
|
||||
description = "An unstable experimental gas that greatly increases the energy of those that inhale it"
|
||||
reagent_state = GAS
|
||||
metabolization_rate = 1.5 * REAGENTS_METABOLISM
|
||||
color = "E1A116"
|
||||
taste_description = "sourness"
|
||||
|
||||
/datum/reagent/stimulum/on_mob_life(mob/living/M) // Has a speedup, and the anti-stun effects of nicotine.
|
||||
M.status_flags |= GOTTAGOFAST
|
||||
M.AdjustStun(-20, 0)
|
||||
M.AdjustKnockdown(-20, 0)
|
||||
M.AdjustUnconscious(-20, 0)
|
||||
M.adjustStaminaLoss(-0.5*REM, 0)
|
||||
|
||||
/datum/reagent/browngas
|
||||
name = "Brown gas"
|
||||
id = "brown_gas"
|
||||
description = "A strange brown gas that makes you feel faster"
|
||||
reagent_state = GAS
|
||||
metabolization_rate = REAGENTS_METABOLISM
|
||||
color = "90560B"
|
||||
taste_description = "burning"
|
||||
|
||||
/datum/reagent/browngas/on_mob_life(mob/living/M) //Has just a speedup
|
||||
M.status_flags |= GOTTAGOFAST
|
||||
|
||||
/////////////////////////Coloured Crayon Powder////////////////////////////
|
||||
//For colouring in /proc/mix_color_from_reagents
|
||||
|
||||
|
||||
@@ -243,7 +243,7 @@
|
||||
if(holder && holder.my_atom)
|
||||
var/turf/open/T = get_turf(holder.my_atom)
|
||||
if(istype(T))
|
||||
T.atmos_spawn_air("freon=50;TEMP=120")
|
||||
T.atmos_spawn_air("nitrogen=50;TEMP=2.7")
|
||||
|
||||
/datum/chemical_reaction/slime/slimefireproof
|
||||
name = "Slime Fireproof"
|
||||
|
||||
@@ -194,7 +194,7 @@
|
||||
SM.mind.enslave_mind_to_creator(user)
|
||||
SM.sentience_act()
|
||||
to_chat(SM, "<span class='warning'>All at once it makes sense: you know what you are and who you are! Self awareness is yours!</span>")
|
||||
to_chat(SM, "<span class='userdanger'>You are grateful to be self aware and owe [user] a great debt. Serve [user], and assist [user.p_them()] in completing [user.p_their()] goals at any cost.</span>")
|
||||
to_chat(SM, "<span class='userdanger'>You are grateful to be self aware and owe [user.real_name] a great debt. Serve [user.real_name], and assist [user.p_them()] in completing [user.p_their()] goals at any cost.</span>")
|
||||
to_chat(user, "<span class='notice'>[SM] accepts [src] and suddenly becomes attentive and aware. It worked!</span>")
|
||||
qdel(src)
|
||||
else
|
||||
@@ -473,75 +473,7 @@
|
||||
desc = "A golem's head."
|
||||
resistance_flags = LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF
|
||||
flags_1 = ABSTRACT_1 | NODROP_1
|
||||
|
||||
/obj/effect/golemrune
|
||||
anchored = TRUE
|
||||
desc = "A strange rune used to create golems. It glows when spirits are nearby."
|
||||
name = "rune"
|
||||
icon = 'icons/obj/rune.dmi'
|
||||
icon_state = "golem"
|
||||
resistance_flags = LAVA_PROOF | FIRE_PROOF | UNACIDABLE | ACID_PROOF
|
||||
layer = TURF_LAYER
|
||||
|
||||
/obj/effect/golemrune/Initialize()
|
||||
. = ..()
|
||||
START_PROCESSING(SSobj, src)
|
||||
notify_ghosts("Golem rune created in [get_area(src)].", 'sound/misc/server-ready.ogg', source = src)
|
||||
|
||||
/obj/effect/golemrune/Destroy()
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
return ..()
|
||||
|
||||
/obj/effect/golemrune/process()
|
||||
var/mob/dead/observer/ghost
|
||||
for(var/mob/dead/observer/O in src.loc)
|
||||
if(!O.client)
|
||||
continue
|
||||
if(O.mind && O.mind.current && O.mind.current.stat != DEAD)
|
||||
continue
|
||||
if (O.orbiting)
|
||||
continue
|
||||
ghost = O
|
||||
break
|
||||
if(ghost)
|
||||
icon_state = "golem2"
|
||||
else
|
||||
icon_state = "golem"
|
||||
|
||||
/obj/effect/golemrune/attack_hand(mob/living/user)
|
||||
var/mob/dead/observer/ghost
|
||||
for(var/mob/dead/observer/O in src.loc)
|
||||
if(!O.client)
|
||||
continue
|
||||
if(O.mind && O.mind.current && O.mind.current.stat != DEAD)
|
||||
continue
|
||||
if (O.orbiting)
|
||||
continue
|
||||
ghost = O
|
||||
break
|
||||
if(!ghost)
|
||||
to_chat(user, "<span class='warning'>The rune fizzles uselessly! There is no spirit nearby.</span>")
|
||||
return
|
||||
var/mob/living/carbon/human/G = new /mob/living/carbon/human
|
||||
G.set_species(/datum/species/golem/adamantine)
|
||||
G.set_cloned_appearance()
|
||||
G.real_name = G.dna.species.random_name()
|
||||
G.name = G.real_name
|
||||
G.dna.unique_enzymes = G.dna.generate_unique_enzymes()
|
||||
G.dna.species.auto_equip(G)
|
||||
G.loc = src.loc
|
||||
G.key = ghost.key
|
||||
to_chat(G, "You are an adamantine golem. You move slowly, but are highly resistant to heat and cold as well as blunt trauma. You are unable to wear clothes, but can still use most tools. \
|
||||
Serve [user], and assist [user.p_them()] in completing their goals at any cost.")
|
||||
G.mind.store_memory("<b>Serve [user.real_name], your creator.</b>")
|
||||
G.mind.assigned_role = "Servant Golem"
|
||||
|
||||
G.mind.enslave_mind_to_creator(user)
|
||||
|
||||
log_game("[key_name(G)] was made a golem by [key_name(user)].")
|
||||
log_admin("[key_name(G)] was made a golem by [key_name(user)].")
|
||||
qdel(src)
|
||||
|
||||
|
||||
/obj/item/stack/tile/bluespace
|
||||
name = "bluespace floor tile"
|
||||
singular_name = "floor tile"
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user