mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-28 22:47:59 +01:00
LINDA, Stage 1
This commit ports the base system of LINDA from TG. This version of linda is the original version, with none of -tg-'s fixes, rewrites, or other such improvements attached. The mob ignite system has been 100% removed, as LINDA does not support this normally. It may be added back in when the improvements and refactors to LINDA have been ported.
This commit is contained in:
@@ -129,8 +129,6 @@ var/list/admin_verbs_server = list(
|
||||
var/list/admin_verbs_debug = list(
|
||||
/client/proc/cmd_admin_list_open_jobs,
|
||||
/client/proc/Debug2,
|
||||
/client/proc/kill_air,
|
||||
/client/proc/ZASSettings,
|
||||
/client/proc/cmd_debug_make_powernets,
|
||||
/client/proc/debug_controller,
|
||||
/client/proc/cmd_debug_mob_lists,
|
||||
|
||||
@@ -3048,18 +3048,6 @@
|
||||
src.admincaster_signature = adminscrub(input(usr, "Provide your desired signature", "Network Identity Handler", ""))
|
||||
src.access_news_network()
|
||||
|
||||
else if(href_list["vsc"])
|
||||
if(check_rights(R_ADMIN|R_SERVER))
|
||||
if(href_list["vsc"] == "airflow")
|
||||
vsc.ChangeSettingsDialog(usr,vsc.settings)
|
||||
if(href_list["vsc"] == "plasma")
|
||||
vsc.ChangeSettingsDialog(usr,vsc.plc.settings)
|
||||
// zas_settings.ChangeSettingsDialog(usr,zas_settings.settings)
|
||||
if(href_list["vsc"] == "default")
|
||||
vsc.SetDefault(usr)
|
||||
// zas_settings.SetDefault(usr)
|
||||
// player info stuff
|
||||
|
||||
if(href_list["add_player_info"])
|
||||
var/key = href_list["add_player_info"]
|
||||
var/add = input("Add Player Info") as null|text
|
||||
|
||||
@@ -1,3 +1,22 @@
|
||||
/client/proc/air_status(turf/target as turf)
|
||||
set category = "Debug"
|
||||
set name = "Display Air Status"
|
||||
|
||||
if(!isturf(target))
|
||||
return
|
||||
|
||||
var/datum/gas_mixture/GM = target.return_air()
|
||||
var/burning = 0
|
||||
if(istype(target, /turf/simulated))
|
||||
var/turf/simulated/T = target
|
||||
if(T.active_hotspot)
|
||||
burning = 1
|
||||
|
||||
usr << "\blue @[target.x],[target.y] ([GM.group_multiplier]): O:[GM.oxygen] T:[GM.toxins] N:[GM.nitrogen] C:[GM.carbon_dioxide] w [GM.temperature] Kelvin, [GM.return_pressure()] kPa [(burning)?("\red BURNING"):(null)]"
|
||||
for(var/datum/gas/trace_gas in GM.trace_gases)
|
||||
usr << "[trace_gas.type]: [trace_gas.moles]"
|
||||
feedback_add_details("admin_verb","DAST") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
/client/proc/fix_next_move()
|
||||
set category = "Debug"
|
||||
set name = "Unfreeze Everyone"
|
||||
|
||||
@@ -143,10 +143,6 @@ var/intercom_range_display_status = 0
|
||||
src.verbs += /client/proc/print_jobban_old
|
||||
src.verbs += /client/proc/print_jobban_old_filter
|
||||
src.verbs += /client/proc/forceEvent
|
||||
src.verbs += /client/proc/Zone_Info
|
||||
src.verbs += /client/proc/Test_ZAS_Connection
|
||||
src.verbs += /client/proc/ZoneTick
|
||||
//src.verbs += /client/proc/TestZASRebuild
|
||||
//src.verbs += /client/proc/cmd_admin_rejuvenate
|
||||
|
||||
feedback_add_details("admin_verb","mDV") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
|
||||
|
||||
@@ -22,7 +22,7 @@
|
||||
if (istype(src.loc.loc, /obj/item/weapon/reagent_containers/glass/beaker/))
|
||||
var/obj/item/weapon/reagent_containers/glass/beaker/beakerbomb = src.loc.loc
|
||||
if(beakerbomb)
|
||||
beakerbomb.ignite()
|
||||
beakerbomb.fire_act()
|
||||
|
||||
var/datum/effect/effect/system/spark_spread/s = new /datum/effect/effect/system/spark_spread
|
||||
s.set_up(3, 1, src)
|
||||
|
||||
@@ -82,7 +82,6 @@
|
||||
phaseanim.density = 1
|
||||
phaseanim.layer = FLY_LAYER
|
||||
phaseanim.master = user
|
||||
user.ExtinguishMob()
|
||||
if(user.buckled)
|
||||
user.buckled.unbuckle()
|
||||
user.loc = holder
|
||||
|
||||
@@ -16,25 +16,6 @@
|
||||
icon_state = "plasmaman_suit"
|
||||
item_state = "plasmaman_suit"
|
||||
|
||||
var/next_extinguish=0
|
||||
var/extinguish_cooldown=10 SECONDS
|
||||
var/extinguishes_left=10 // Yeah yeah, reagents, blah blah blah. This should be simple.
|
||||
|
||||
/obj/item/clothing/suit/space/eva/plasmaman/examine(mob/user)
|
||||
..()
|
||||
user << "<span class='info'>There are [extinguishes_left] extinguisher canisters left in this suit.</span>"
|
||||
|
||||
/obj/item/clothing/suit/space/eva/plasmaman/proc/Extinguish(var/mob/user)
|
||||
var/mob/living/carbon/human/H=user
|
||||
if(extinguishes_left)
|
||||
if(next_extinguish > world.time)
|
||||
return
|
||||
|
||||
next_extinguish = world.time + extinguish_cooldown
|
||||
extinguishes_left--
|
||||
H << "<span class='warning'>Your suit automatically extinguishes the fire.</span>"
|
||||
H.ExtinguishMob()
|
||||
|
||||
/obj/item/clothing/head/helmet/space/eva/plasmaman
|
||||
name = "plasmaman helmet"
|
||||
desc = "A special containment helmet designed to protect a plasmaman's volatile body from outside exposure and quickly extinguish it in emergencies."
|
||||
|
||||
@@ -20,8 +20,6 @@
|
||||
opacity = 1
|
||||
var/health = 50
|
||||
|
||||
autoignition_temperature = AUTOIGNITION_WOOD
|
||||
|
||||
/obj/structure/bookcase/initialize()
|
||||
for(var/obj/item/I in loc)
|
||||
if(istype(I, /obj/item/weapon/book))
|
||||
@@ -151,8 +149,6 @@
|
||||
w_class = 3 //upped to three because books are, y'know, pretty big. (and you could hide them inside eachother recursively forever)
|
||||
attack_verb = list("bashed", "whacked", "educated")
|
||||
|
||||
autoignition_temperature = AUTOIGNITION_PAPER
|
||||
|
||||
var/dat // Actual page content
|
||||
var/due_date = 0 // Game time in 1/10th seconds
|
||||
var/author // Who wrote the thing, can be changed by pen or PC. It is not automatically assigned
|
||||
|
||||
@@ -87,14 +87,13 @@
|
||||
// Aliens are now weak to fire.
|
||||
|
||||
//After then, it reacts to the surrounding atmosphere based on your thermal protection
|
||||
if(!on_fire) // If you're on fire, ignore local air temperature
|
||||
if(loc_temp > bodytemperature)
|
||||
//Place is hotter than we are
|
||||
var/thermal_protection = heat_protection //This returns a 0 - 1 value, which corresponds to the percentage of protection based on what you're wearing and what you're exposed to.
|
||||
if(thermal_protection < 1)
|
||||
bodytemperature += (1-thermal_protection) * ((loc_temp - bodytemperature) / BODYTEMP_HEAT_DIVISOR)
|
||||
else
|
||||
bodytemperature += 1 * ((loc_temp - bodytemperature) / BODYTEMP_HEAT_DIVISOR)
|
||||
if(loc_temp > bodytemperature)
|
||||
//Place is hotter than we are
|
||||
var/thermal_protection = heat_protection //This returns a 0 - 1 value, which corresponds to the percentage of protection based on what you're wearing and what you're exposed to.
|
||||
if(thermal_protection < 1)
|
||||
bodytemperature += (1-thermal_protection) * ((loc_temp - bodytemperature) / BODYTEMP_HEAT_DIVISOR)
|
||||
else
|
||||
bodytemperature += 1 * ((loc_temp - bodytemperature) / BODYTEMP_HEAT_DIVISOR)
|
||||
// bodytemperature -= max((loc_temp - bodytemperature / BODYTEMP_AUTORECOVERY_DIVISOR), BODYTEMP_AUTORECOVERY_MINIMUM)
|
||||
|
||||
// +/- 50 degrees from 310.15K is the 'safe' zone, where no damage is dealt.
|
||||
@@ -105,16 +104,12 @@
|
||||
if(360 to 400)
|
||||
apply_damage(HEAT_DAMAGE_LEVEL_1, BURN)
|
||||
fire_alert = max(fire_alert, 2)
|
||||
if(400 to 460)
|
||||
if(400 to 1000)
|
||||
apply_damage(HEAT_DAMAGE_LEVEL_2, BURN)
|
||||
fire_alert = max(fire_alert, 2)
|
||||
if(460 to INFINITY)
|
||||
if(on_fire)
|
||||
apply_damage(HEAT_DAMAGE_LEVEL_3, BURN)
|
||||
fire_alert = max(fire_alert, 2)
|
||||
else
|
||||
apply_damage(HEAT_DAMAGE_LEVEL_2, BURN)
|
||||
fire_alert = max(fire_alert, 2)
|
||||
if(1000 to INFINITY)
|
||||
apply_damage(HEAT_DAMAGE_LEVEL_3, BURN)
|
||||
fire_alert = max(fire_alert, 2)
|
||||
return
|
||||
|
||||
/mob/living/carbon/alien/proc/handle_mutations_and_radiation()
|
||||
@@ -146,12 +141,6 @@
|
||||
radiation -= 3
|
||||
adjustToxLoss(3)
|
||||
|
||||
/mob/living/carbon/alien/handle_fire()//Aliens on fire code
|
||||
if(..())
|
||||
return
|
||||
bodytemperature += BODYTEMP_HEATING_MAX //If you're on fire, you heat up!
|
||||
return
|
||||
|
||||
/mob/living/carbon/alien/IsAdvancedToolUser()
|
||||
return has_fine_manipulation
|
||||
|
||||
|
||||
@@ -50,9 +50,6 @@
|
||||
//stuff in the stomach
|
||||
handle_stomach()
|
||||
|
||||
//Handle being on fire
|
||||
handle_fire()
|
||||
|
||||
//Status updates, death etc.
|
||||
handle_regular_status_updates()
|
||||
update_canmove()
|
||||
|
||||
@@ -62,7 +62,7 @@
|
||||
update_inv_pockets(0)
|
||||
update_hud()
|
||||
update_icons()
|
||||
update_fire()
|
||||
|
||||
|
||||
|
||||
/mob/living/carbon/alien/humanoid/update_hud()
|
||||
@@ -72,21 +72,6 @@
|
||||
// else client.screen -= hud_used.other //Not used
|
||||
client.screen |= contents
|
||||
|
||||
/mob/living/carbon/alien/humanoid/update_fire()
|
||||
overlays -= overlays_lying[X_FIRE_LAYER]
|
||||
overlays -= overlays_standing[X_FIRE_LAYER]
|
||||
if(on_fire)
|
||||
overlays_lying[X_FIRE_LAYER] = image("icon"='icons/mob/OnFire.dmi', "icon_state"="Lying", "layer"= -X_FIRE_LAYER)
|
||||
overlays_standing[X_FIRE_LAYER] = image("icon"='icons/mob/OnFire.dmi', "icon_state"="Standing", "layer"= -X_FIRE_LAYER)
|
||||
if(src.lying)
|
||||
overlays += overlays_lying[X_FIRE_LAYER]
|
||||
else
|
||||
overlays += overlays_standing[X_FIRE_LAYER]
|
||||
return
|
||||
else
|
||||
overlays_lying[X_FIRE_LAYER] = null
|
||||
overlays_standing[X_FIRE_LAYER] = null
|
||||
|
||||
/mob/living/carbon/alien/humanoid/update_inv_wear_suit(var/update_icons=1)
|
||||
if(wear_suit)
|
||||
var/t_state = wear_suit.item_state
|
||||
|
||||
@@ -440,6 +440,10 @@ mob/living
|
||||
|
||||
item.throw_at(target, item.throw_range, item.throw_speed, src)
|
||||
|
||||
/mob/living/carbon/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume)
|
||||
..()
|
||||
bodytemperature = max(bodytemperature, BODYTEMP_HEAT_DAMAGE_LIMIT+10)
|
||||
|
||||
/mob/living/carbon/can_use_hands()
|
||||
if(handcuffed)
|
||||
return 0
|
||||
|
||||
@@ -226,12 +226,6 @@
|
||||
usr << "<span class='deadsay'>[t_He] has a pulse!</span>"
|
||||
|
||||
msg += "<span class='warning'>"
|
||||
|
||||
if(fire_stacks > 0)
|
||||
msg += "[t_He] [t_is] covered in something flammable.\n"
|
||||
if(fire_stacks < 0)
|
||||
msg += "[t_He] looks a little soaked.\n"
|
||||
|
||||
if(nutrition < 100)
|
||||
msg += "[t_He] [t_is] severely malnourished.\n"
|
||||
else if(nutrition >= 500)
|
||||
|
||||
@@ -80,7 +80,4 @@
|
||||
|
||||
var/lastFart = 0 // Toxic fart cooldown.
|
||||
|
||||
var/frozen = 0 //used for preventing attacks on admin-frozen people
|
||||
|
||||
fire_dmi = 'icons/mob/OnFire.dmi'
|
||||
fire_sprite = "Standing"
|
||||
var/frozen = 0 //used for preventing attacks on admin-frozen people
|
||||
@@ -105,9 +105,6 @@ var/global/list/brutefireloss_overlays = list("1" = image("icon" = 'icons/mob/sc
|
||||
|
||||
handle_virus_updates()
|
||||
|
||||
//Check if we're on fire
|
||||
handle_fire()
|
||||
|
||||
//stuff in the stomach
|
||||
handle_stomach()
|
||||
|
||||
@@ -371,7 +368,7 @@ var/global/list/brutefireloss_overlays = list("1" = image("icon" = 'icons/mob/sc
|
||||
breath = loc.remove_air(breath_moles)
|
||||
|
||||
if(!is_lung_ruptured())
|
||||
if(!breath || breath.total_moles < BREATH_MOLES / 5 || breath.total_moles > BREATH_MOLES * 5)
|
||||
if(!breath || breath.total_moles() < BREATH_MOLES / 5 || breath.total_moles() > BREATH_MOLES * 5)
|
||||
if(prob(5))
|
||||
rupture_lung()
|
||||
|
||||
@@ -382,18 +379,6 @@ var/global/list/brutefireloss_overlays = list("1" = image("icon" = 'icons/mob/sc
|
||||
|
||||
handle_breath(breath)
|
||||
|
||||
if(species.name=="Plasmaman")
|
||||
|
||||
// Check if we're wearing our biosuit and mask.
|
||||
if (!istype(wear_suit,/obj/item/clothing/suit/space/eva/plasmaman) || !istype(head,/obj/item/clothing/head/helmet/space/eva/plasmaman))
|
||||
//testing("Plasmaman [src] leakin'. coverflags=[cover_flags]")
|
||||
// OH FUCK HE LEAKIN'.
|
||||
// This was OP.
|
||||
//environment.adjust(tx = environment.total_moles()*BREATH_PERCENTAGE) // About one breath's worth. (I know we aren't breathing it out, but this should be about the right amount)
|
||||
src << "<span class='warning'>Your body reacts with the atmosphere and bursts into flame!</span>"
|
||||
adjust_fire_stacks(0.5)
|
||||
IgniteMob()
|
||||
|
||||
if(breath)
|
||||
loc.assume_air(breath)
|
||||
|
||||
@@ -451,17 +436,16 @@ var/global/list/brutefireloss_overlays = list("1" = image("icon" = 'icons/mob/sc
|
||||
stabilize_temperature_from_calories()
|
||||
|
||||
//After then, it reacts to the surrounding atmosphere based on your thermal protection
|
||||
if(!on_fire) //If you're on fire, you do not heat up or cool down based on surrounding gases
|
||||
if(loc_temp < bodytemperature)
|
||||
//Place is colder than we are
|
||||
var/thermal_protection = get_cold_protection(loc_temp) //This returns a 0 - 1 value, which corresponds to the percentage of protection based on what you're wearing and what you're exposed to.
|
||||
if(thermal_protection < 1)
|
||||
bodytemperature += min((1-thermal_protection) * ((loc_temp - bodytemperature) / BODYTEMP_COLD_DIVISOR), BODYTEMP_COOLING_MAX)
|
||||
else
|
||||
//Place is hotter than we are
|
||||
var/thermal_protection = get_heat_protection(loc_temp) //This returns a 0 - 1 value, which corresponds to the percentage of protection based on what you're wearing and what you're exposed to.
|
||||
if(thermal_protection < 1)
|
||||
bodytemperature += min((1-thermal_protection) * ((loc_temp - bodytemperature) / BODYTEMP_HEAT_DIVISOR), BODYTEMP_HEATING_MAX)
|
||||
if(loc_temp < bodytemperature)
|
||||
//Place is colder than we are
|
||||
var/thermal_protection = get_cold_protection(loc_temp) //This returns a 0 - 1 value, which corresponds to the percentage of protection based on what you're wearing and what you're exposed to.
|
||||
if(thermal_protection < 1)
|
||||
bodytemperature += min((1-thermal_protection) * ((loc_temp - bodytemperature) / BODYTEMP_COLD_DIVISOR), BODYTEMP_COOLING_MAX)
|
||||
else
|
||||
//Place is hotter than we are
|
||||
var/thermal_protection = get_heat_protection(loc_temp) //This returns a 0 - 1 value, which corresponds to the percentage of protection based on what you're wearing and what you're exposed to.
|
||||
if(thermal_protection < 1)
|
||||
bodytemperature += min((1-thermal_protection) * ((loc_temp - bodytemperature) / BODYTEMP_HEAT_DIVISOR), BODYTEMP_HEATING_MAX)
|
||||
|
||||
// +/- 50 degrees from 310.15K is the 'safe' zone, where no damage is dealt.
|
||||
if(bodytemperature > species.heat_level_1)
|
||||
@@ -476,12 +460,8 @@ var/global/list/brutefireloss_overlays = list("1" = image("icon" = 'icons/mob/sc
|
||||
take_overall_damage(burn=HEAT_DAMAGE_LEVEL_2, used_weapon = "High Body Temperature")
|
||||
fire_alert = max(fire_alert, 2)
|
||||
if(bodytemperature > species.heat_level_3 && bodytemperature < INFINITY)
|
||||
if(on_fire)
|
||||
take_overall_damage(burn=HEAT_DAMAGE_LEVEL_3, used_weapon = "Fire")
|
||||
fire_alert = max(fire_alert, 2)
|
||||
else
|
||||
take_overall_damage(burn=HEAT_DAMAGE_LEVEL_2, used_weapon = "High Body Temperature")
|
||||
fire_alert = max(fire_alert, 2)
|
||||
take_overall_damage(burn=HEAT_DAMAGE_LEVEL_3, used_weapon = "Fire")
|
||||
fire_alert = max(fire_alert, 2)
|
||||
|
||||
else if(bodytemperature < species.cold_level_1)
|
||||
fire_alert = max(fire_alert, 1)
|
||||
@@ -526,28 +506,6 @@ var/global/list/brutefireloss_overlays = list("1" = image("icon" = 'icons/mob/sc
|
||||
|
||||
return
|
||||
|
||||
///FIRE CODE
|
||||
handle_fire()
|
||||
if(..())
|
||||
return
|
||||
var/thermal_protection = 0 //Simple check to estimate how protected we are against multiple temperatures
|
||||
if(wear_suit)
|
||||
if(wear_suit.max_heat_protection_temperature >= FIRESUIT_MAX_HEAT_PROTECTION_TEMPERATURE)
|
||||
thermal_protection += (wear_suit.max_heat_protection_temperature*0.7)
|
||||
if(head)
|
||||
if(head.max_heat_protection_temperature >= FIRE_HELMET_MAX_HEAT_PROTECTION_TEMPERATURE)
|
||||
thermal_protection += (head.max_heat_protection_temperature*THERMAL_PROTECTION_HEAD)
|
||||
thermal_protection = round(thermal_protection)
|
||||
if(thermal_protection >= FIRE_IMMUNITY_SUIT_MAX_TEMP_PROTECT)
|
||||
return
|
||||
if(thermal_protection >= FIRESUIT_MAX_HEAT_PROTECTION_TEMPERATURE)
|
||||
bodytemperature += 11
|
||||
return
|
||||
else
|
||||
bodytemperature += BODYTEMP_HEATING_MAX
|
||||
return
|
||||
//END FIRE CODE
|
||||
|
||||
/*
|
||||
proc/adjust_body_temperature(current, loc_temp, boost)
|
||||
var/temperature = current
|
||||
@@ -728,12 +686,6 @@ var/global/list/brutefireloss_overlays = list("1" = image("icon" = 'icons/mob/sc
|
||||
alien = species.reagent_tag
|
||||
reagents.metabolize(src,alien)
|
||||
|
||||
var/total_plasmaloss = 0
|
||||
for(var/obj/item/I in src)
|
||||
if(I.contaminated)
|
||||
total_plasmaloss += vsc.plc.CONTAMINATION_LOSS
|
||||
if(!(status_flags & GODMODE)) adjustToxLoss(total_plasmaloss)
|
||||
|
||||
if(status_flags & GODMODE) return 0 //godmode
|
||||
|
||||
if(species.flags & REQUIRE_LIGHT)
|
||||
|
||||
@@ -21,8 +21,6 @@
|
||||
return message
|
||||
|
||||
/datum/species/plasmaman/equip(var/mob/living/carbon/human/H)
|
||||
H.fire_sprite = "Plasmaman"
|
||||
|
||||
// Unequip existing suits and hats.
|
||||
H.unEquip(H.wear_suit)
|
||||
H.unEquip(H.head)
|
||||
|
||||
@@ -459,16 +459,6 @@ proc/get_damage_icon_part(damage_state, body_part)
|
||||
overlays_standing[TARGETED_LAYER] = null
|
||||
if(update_icons) update_icons()
|
||||
|
||||
/mob/living/carbon/human/update_fire()
|
||||
|
||||
remove_overlay(FIRE_LAYER)
|
||||
if(on_fire)
|
||||
overlays_standing[FIRE_LAYER] = image("icon"=fire_dmi, "icon_state"=fire_sprite, "layer"=-FIRE_LAYER)
|
||||
else
|
||||
overlays_standing[FIRE_LAYER] = null
|
||||
|
||||
apply_overlay(FIRE_LAYER)
|
||||
|
||||
|
||||
/* --------------------------------------- */
|
||||
//For legacy support.
|
||||
@@ -499,7 +489,6 @@ proc/get_damage_icon_part(damage_state, body_part)
|
||||
update_icons()
|
||||
//Hud Stuff
|
||||
update_hud()
|
||||
update_fire()
|
||||
/* --------------------------------------- */
|
||||
//vvvvvv UPDATE_INV PROCS vvvvvv
|
||||
|
||||
|
||||
@@ -32,10 +32,6 @@
|
||||
msg += "It has minor burns.\n"
|
||||
else
|
||||
msg += "<B>It has severe burns!</B>\n"
|
||||
if (src.fire_stacks > 0)
|
||||
msg += "It's covered in something flammable.\n"
|
||||
if (src.fire_stacks < 0)
|
||||
msg += "It's soaked in water.\n"
|
||||
if (src.stat == UNCONSCIOUS)
|
||||
msg += "It isn't responding to anything around it; it seems to be asleep.\n"
|
||||
msg += "</span>"
|
||||
|
||||
@@ -59,9 +59,6 @@
|
||||
if(environment) // More error checking -- TLE
|
||||
handle_environment(environment)
|
||||
|
||||
//Check if we're on fire
|
||||
handle_fire()
|
||||
|
||||
//Status updates, death etc.
|
||||
handle_regular_status_updates()
|
||||
update_canmove()
|
||||
@@ -266,7 +263,7 @@
|
||||
if(status_flags & GODMODE)
|
||||
return
|
||||
|
||||
if(!breath || (breath.total_moles == 0))
|
||||
if(!breath || (breath.total_moles() == 0))
|
||||
adjustOxyLoss(7)
|
||||
|
||||
oxygen_alert = max(oxygen_alert, 1)
|
||||
@@ -388,11 +385,10 @@
|
||||
var/turf/heat_turf = get_turf(src)
|
||||
environment_heat_capacity = heat_turf.heat_capacity
|
||||
|
||||
if(!on_fire)
|
||||
if((environment.temperature > (T0C + 50)) || (environment.temperature < (T0C + 10)))
|
||||
var/transfer_coefficient = 1
|
||||
if((environment.temperature > (T0C + 50)) || (environment.temperature < (T0C + 10)))
|
||||
var/transfer_coefficient = 1
|
||||
|
||||
handle_temperature_damage(HEAD, environment.temperature, environment_heat_capacity*transfer_coefficient)
|
||||
handle_temperature_damage(HEAD, environment.temperature, environment_heat_capacity*transfer_coefficient)
|
||||
|
||||
if(stat==2)
|
||||
bodytemperature += 0.1*(environment.temperature - bodytemperature)*environment_heat_capacity/(environment_heat_capacity + 270000)
|
||||
@@ -652,12 +648,4 @@
|
||||
|
||||
proc/handle_changeling()
|
||||
if(mind && mind.changeling)
|
||||
mind.changeling.regenerate()
|
||||
|
||||
///FIRE CODE
|
||||
handle_fire()
|
||||
if(..())
|
||||
return
|
||||
adjustFireLoss(6)
|
||||
return
|
||||
//END FIRE CODE
|
||||
mind.changeling.regenerate()
|
||||
@@ -20,7 +20,6 @@
|
||||
update_inv_r_hand(0)
|
||||
update_inv_l_hand(0)
|
||||
update_inv_handcuffed(0)
|
||||
update_fire()
|
||||
update_icons()
|
||||
//Hud Stuff
|
||||
update_hud()
|
||||
@@ -113,15 +112,6 @@
|
||||
overlays_standing[TARGETED_LAYER] = null
|
||||
if(update_icons) update_icons()
|
||||
|
||||
/mob/living/carbon/monkey/update_fire()
|
||||
overlays -= overlays_standing[M_FIRE_LAYER]
|
||||
if(on_fire)
|
||||
overlays_standing[M_FIRE_LAYER] = image("icon"='icons/mob/OnFire.dmi', "icon_state"="Standing", "layer"= -M_FIRE_LAYER)
|
||||
overlays += overlays_standing[M_FIRE_LAYER]
|
||||
return
|
||||
else
|
||||
overlays_standing[M_FIRE_LAYER] = null
|
||||
|
||||
//Monkey Overlays Indexes////////
|
||||
#undef M_MASK_LAYER
|
||||
#undef M_BACK_LAYER
|
||||
|
||||
@@ -328,8 +328,6 @@
|
||||
ear_deaf = 0
|
||||
ear_damage = 0
|
||||
heal_overall_damage(1000, 1000)
|
||||
fire_stacks = 0
|
||||
on_fire = 0
|
||||
suiciding = 0
|
||||
buckled = initial(src.buckled)
|
||||
|
||||
@@ -352,7 +350,6 @@
|
||||
timeofdeath = 0
|
||||
|
||||
stat = CONSCIOUS
|
||||
update_fire()
|
||||
regenerate_icons()
|
||||
hud_updateflag |= 1 << HEALTH_HUD
|
||||
hud_updateflag |= 1 << STATUS_HUD
|
||||
@@ -638,19 +635,6 @@
|
||||
//breaking out of handcuffs
|
||||
else if(iscarbon(L))
|
||||
var/mob/living/carbon/CM = L
|
||||
if(CM.on_fire && CM.canmove)
|
||||
CM.fire_stacks -= 5
|
||||
CM.weakened = max(CM.weakened, 3)//We dont check for CANWEAKEN, I don't care how immune to weakening you are, if you're rolling on the ground, you're busy.
|
||||
CM.update_canmove()
|
||||
CM.spin(32,2)
|
||||
CM.visible_message("<span class='danger'>[CM] rolls on the floor, trying to put themselves out!</span>", \
|
||||
"<span class='notice'>You stop, drop, and roll!</span>")
|
||||
sleep(30)
|
||||
if(fire_stacks <= 0)
|
||||
CM.visible_message("<span class='danger'>[CM] has successfully extinguished themselves!</span>", \
|
||||
"<span class='notice'>You extinguish yourself.</span>")
|
||||
ExtinguishMob()
|
||||
return
|
||||
if(CM.handcuffed && CM.canmove && (CM.last_special <= world.time))
|
||||
CM.changeNext_move(CLICK_CD_BREAKOUT)
|
||||
CM.last_special = world.time + CLICK_CD_BREAKOUT
|
||||
|
||||
@@ -219,45 +219,6 @@
|
||||
|
||||
// End BS12 momentum-transfer code.
|
||||
|
||||
//Mobs on Fire
|
||||
/mob/living/proc/IgniteMob()
|
||||
if(fire_stacks > 0)
|
||||
on_fire = 1
|
||||
src.AddLuminosity(3)
|
||||
update_fire()
|
||||
|
||||
/mob/living/proc/ExtinguishMob()
|
||||
if(on_fire)
|
||||
on_fire = 0
|
||||
fire_stacks = 0
|
||||
src.AddLuminosity(-3)
|
||||
update_fire()
|
||||
|
||||
/mob/living/proc/update_fire()
|
||||
return
|
||||
|
||||
/mob/living/proc/adjust_fire_stacks(add_fire_stacks) //Adjusting the amount of fire_stacks we have on person
|
||||
fire_stacks = Clamp(fire_stacks + add_fire_stacks, min = -20, max = 20)
|
||||
|
||||
/mob/living/proc/handle_fire()
|
||||
if(fire_stacks < 0)
|
||||
fire_stacks++ //If we've doused ourselves in water to avoid fire, dry off slowly
|
||||
fire_stacks = min(0, fire_stacks)//So we dry ourselves back to default, nonflammable.
|
||||
if(!on_fire)
|
||||
return 1
|
||||
var/datum/gas_mixture/G = loc.return_air() // Check if we're standing in an oxygenless environment
|
||||
if(G.oxygen < 1)
|
||||
ExtinguishMob() //If there's no oxygen in the tile we're on, put out the fire
|
||||
return
|
||||
var/turf/location = get_turf(src)
|
||||
location.hotspot_expose(700, 50, 1)
|
||||
|
||||
/mob/living/fire_act()
|
||||
adjust_fire_stacks(0.5)
|
||||
IgniteMob()
|
||||
|
||||
//Mobs on Fire end
|
||||
|
||||
/mob/living/proc/grabbedby(mob/living/carbon/user,var/supress_message = 0)
|
||||
if(user == src || anchored)
|
||||
return 0
|
||||
|
||||
@@ -37,8 +37,6 @@
|
||||
|
||||
var/tod = null // Time of death
|
||||
var/update_slimes = 1
|
||||
on_fire = 0 //The "Are we on fire?" var
|
||||
var/fire_stacks = 0 //Tracks how many stacks of fire we have on, max is usually 20
|
||||
var/specialsauce = 0 //Has this person consumed enough special sauce? IF so they're a ticking time bomb of death.
|
||||
var/implanting = 0 //Used for the mind-slave implant
|
||||
var/silent = null //Can't talk. Value goes down every life proc.
|
||||
|
||||
@@ -49,8 +49,7 @@
|
||||
// DOORS
|
||||
|
||||
// Simply updates the visibility of the area when it opens/closes/destroyed.
|
||||
/obj/machinery/door/update_nearby_tiles(need_rebuild)
|
||||
. = ..(need_rebuild)
|
||||
/obj/machinery/door/proc/update_freelok_sight()
|
||||
// Glass door glass = 1
|
||||
// don't check then?
|
||||
if(!glass && cameranet)
|
||||
|
||||
@@ -419,7 +419,7 @@
|
||||
data["temperature"] = round(env.temperature)
|
||||
data["temperatureC"] = round(env.temperature-T0C)
|
||||
|
||||
var/t_moles = env.total_moles
|
||||
var/t_moles = env.total_moles()
|
||||
var/gases[0]
|
||||
if(t_moles)
|
||||
var/n2[0]
|
||||
|
||||
@@ -61,7 +61,6 @@
|
||||
see_in_dark = 8
|
||||
see_invisible = SEE_INVISIBLE_LEVEL_TWO
|
||||
updateicon()
|
||||
update_fire()
|
||||
tod = worldtime2text() //weasellos time of death patch
|
||||
if(mind) mind.store_memory("Time of death: [tod]", 0)
|
||||
|
||||
|
||||
@@ -21,10 +21,6 @@
|
||||
msg += "It looks slightly charred.\n"
|
||||
else
|
||||
msg += "<B>It looks severely burnt and heat-warped!</B>\n"
|
||||
if (src.fire_stacks < 0)
|
||||
msg += "It's covered in water.\n"
|
||||
if (src.fire_stacks > 0)
|
||||
msg += "It's coated in something flammable.\n"
|
||||
msg += "</span>"
|
||||
|
||||
if(opened)
|
||||
@@ -50,4 +46,4 @@
|
||||
msg += "\nIt is [pose]"
|
||||
|
||||
usr << msg
|
||||
return
|
||||
return
|
||||
@@ -22,7 +22,6 @@
|
||||
|
||||
update_gravity(mob_has_gravity())
|
||||
|
||||
handle_fire()
|
||||
|
||||
/mob/living/silicon/robot/proc/clamp_values()
|
||||
|
||||
@@ -341,29 +340,3 @@
|
||||
if(paralysis || stunned || weakened || buckled || lockcharge) canmove = 0
|
||||
else canmove = 1
|
||||
return canmove
|
||||
|
||||
//Robots on fire
|
||||
/mob/living/silicon/robot/handle_fire()
|
||||
if(..())
|
||||
return
|
||||
if(fire_stacks > 0)
|
||||
fire_stacks--
|
||||
fire_stacks = max(0, fire_stacks)
|
||||
else
|
||||
ExtinguishMob()
|
||||
|
||||
//adjustFireLoss(3)
|
||||
return
|
||||
|
||||
/mob/living/silicon/robot/update_fire()
|
||||
overlays -= image("icon"='icons/mob/OnFire.dmi', "icon_state"="Standing")
|
||||
if(on_fire)
|
||||
overlays += image("icon"='icons/mob/OnFire.dmi', "icon_state"="Standing")
|
||||
update_icons()
|
||||
return
|
||||
|
||||
/mob/living/silicon/robot/fire_act()
|
||||
if(!on_fire) //Silicons don't gain stacks from hotspots, but hotspots can ignite them
|
||||
IgniteMob()
|
||||
|
||||
//Robots on fire
|
||||
|
||||
@@ -510,9 +510,6 @@
|
||||
return 0
|
||||
return 1
|
||||
|
||||
/mob/living/simple_animal/update_fire()
|
||||
return
|
||||
|
||||
/mob/living/simple_animal/revive()
|
||||
..()
|
||||
health = maxHealth
|
||||
|
||||
@@ -6,8 +6,6 @@
|
||||
w_class = 2
|
||||
pressure_resistance = 2
|
||||
|
||||
autoignition_temperature = 522 // Kelvin
|
||||
|
||||
/obj/item/weapon/folder/blue
|
||||
desc = "A blue folder."
|
||||
icon_state = "folder_blue"
|
||||
|
||||
@@ -10,7 +10,7 @@
|
||||
pressure_resistance = 10
|
||||
var/amount = 30 //How much paper is in the bin.
|
||||
var/list/papers = new/list() //List of papers put in the bin for reference.
|
||||
|
||||
/*
|
||||
autoignition_temperature = 519.15 // Kelvin
|
||||
|
||||
/obj/item/weapon/paper_bin/ignite(var/temperature)
|
||||
@@ -24,7 +24,7 @@
|
||||
papers=0
|
||||
amount=0
|
||||
update_icon()
|
||||
|
||||
*///LINDA shit figure out later
|
||||
/obj/item/weapon/paper_bin/MouseDrop(atom/over_object)
|
||||
var/mob/M = usr
|
||||
if(M.restrained() || M.stat || !Adjacent(M))
|
||||
|
||||
@@ -32,7 +32,7 @@ var/global/list/rad_collectors = list()
|
||||
P.air_contents.toxins = 0
|
||||
eject()
|
||||
else
|
||||
P.air_contents.adjust(tx = -0.001*drainratio)
|
||||
P.air_contents.toxins -= 0.001*drainratio
|
||||
return
|
||||
|
||||
|
||||
|
||||
@@ -128,7 +128,7 @@
|
||||
|
||||
if(!tank || !..()) return //Only do this on a successful shot.
|
||||
|
||||
var/lost_gas_amount = tank.air_contents.total_moles*(pressure_setting/100)
|
||||
var/lost_gas_amount = tank.air_contents.total_moles()*(pressure_setting/100)
|
||||
var/datum/gas_mixture/removed = tank.air_contents.remove(lost_gas_amount)
|
||||
user.loc.assume_air(removed)
|
||||
|
||||
|
||||
@@ -90,13 +90,14 @@
|
||||
|
||||
/obj/item/projectile/bullet/incendiary
|
||||
|
||||
/*
|
||||
/obj/item/projectile/bullet/incendiary/on_hit(var/atom/target, var/blocked = 0)
|
||||
..()
|
||||
if(istype(target, /mob/living/carbon))
|
||||
var/mob/living/carbon/M = target
|
||||
M.adjust_fire_stacks(1)
|
||||
M.IgniteMob()
|
||||
|
||||
// M.adjust_fire_stacks(1)
|
||||
// M.IgniteMob() // need to find out linda shit later for this
|
||||
*/
|
||||
/obj/item/projectile/bullet/incendiary/shell
|
||||
name = "incendiary slug"
|
||||
damage = 20
|
||||
@@ -104,7 +105,7 @@
|
||||
/obj/item/projectile/bullet/incendiary/shell/Move()
|
||||
..()
|
||||
var/turf/location = get_turf(src)
|
||||
new/obj/fire(location)
|
||||
new/obj/effect/hotspot(location)
|
||||
location.hotspot_expose(700, 50, 1)
|
||||
|
||||
/obj/item/projectile/bullet/incendiary/shell/dragonsbreath
|
||||
|
||||
@@ -214,16 +214,8 @@ datum
|
||||
if(!istype(M, /mob/living))
|
||||
return
|
||||
|
||||
// Put out fire
|
||||
if(method == TOUCH)
|
||||
M.adjust_fire_stacks(-(volume / 10))
|
||||
if(M.fire_stacks <= 0)
|
||||
M.ExtinguishMob()
|
||||
return
|
||||
|
||||
reaction_turf(var/turf/simulated/T, var/volume)
|
||||
if (!istype(T)) return
|
||||
var/CT = cooling_temperature
|
||||
src = null
|
||||
if(volume >= 3)
|
||||
if(T.wet >= 1) return
|
||||
@@ -245,10 +237,10 @@ datum
|
||||
for(var/mob/living/carbon/slime/M in T)
|
||||
M.apply_water()
|
||||
|
||||
var/hotspot = (locate(/obj/fire) in T)
|
||||
var/hotspot = (locate(/obj/effect/hotspot) in T)
|
||||
if(hotspot && !istype(T, /turf/space))
|
||||
var/datum/gas_mixture/lowertemp = T.remove_air( T:air:total_moles() )
|
||||
lowertemp.temperature = max( min(lowertemp.temperature-(CT*1000),lowertemp.temperature / CT) ,0)
|
||||
lowertemp.temperature = max( min(lowertemp.temperature-2000,lowertemp.temperature / 2) ,0)
|
||||
lowertemp.react()
|
||||
T.assume_air(lowertemp)
|
||||
qdel(hotspot)
|
||||
@@ -257,13 +249,13 @@ datum
|
||||
reaction_obj(var/obj/O, var/volume)
|
||||
src = null
|
||||
var/turf/T = get_turf(O)
|
||||
var/hotspot = (locate(/obj/fire) in T)
|
||||
var/hotspot = (locate(/obj/effect/hotspot) in T)
|
||||
if(hotspot && !istype(T, /turf/space))
|
||||
var/datum/gas_mixture/lowertemp = T.remove_air( T:air:total_moles() )
|
||||
lowertemp.temperature = max( min(lowertemp.temperature-2000,lowertemp.temperature / 2) ,0)
|
||||
lowertemp.react()
|
||||
T.assume_air(lowertemp)
|
||||
del(hotspot)
|
||||
qdel(hotspot)
|
||||
if(istype(O,/obj/item/weapon/reagent_containers/food/snacks/monkeycube))
|
||||
var/obj/item/weapon/reagent_containers/food/snacks/monkeycube/cube = O
|
||||
if(!cube.wrapped)
|
||||
@@ -280,10 +272,8 @@ datum
|
||||
description = "YOUR FLESH! IT BURNS!"
|
||||
|
||||
on_mob_life(var/mob/living/M as mob)
|
||||
M.fire_stacks = min(5,M.fire_stacks + 3)
|
||||
M.IgniteMob() //Only problem with igniting people is currently the commonly availible fire suits make you immune to being on fire
|
||||
M.adjustToxLoss(1)
|
||||
M.adjustFireLoss(1) //Hence the other damages... ain't I a bastard?
|
||||
M.adjustFireLoss(5) //does more damage since mob fire isn't a thing anymore
|
||||
M.adjustBrainLoss(5)
|
||||
holder.remove_reagent(src.id, 1)
|
||||
|
||||
@@ -466,9 +456,7 @@ datum
|
||||
M << "<span class = 'danger'>You suddenly ignite in a holy fire!</span>"
|
||||
for(var/mob/O in viewers(M, null))
|
||||
O.show_message(text("<span class = 'danger'>[] suddenly bursts into flames!<span>", M), 1)
|
||||
M.fire_stacks = min(5,M.fire_stacks + 3)
|
||||
M.IgniteMob() //Only problem with igniting people is currently the commonly availible fire suits make you immune to being on fire
|
||||
M.adjustFireLoss(3) //Hence the other damages... ain't I a bastard?
|
||||
M.adjustFireLoss(9) //Hence the other damages... ain't I a bastard?
|
||||
M.mind.vampire.nullified = max(5, M.mind.vampire.nullified + 2)
|
||||
holder.remove_reagent(src.id, 10 * REAGENTS_METABOLISM) //high metabolism to prevent extended uncult rolls.
|
||||
|
||||
@@ -1016,8 +1004,6 @@ datum
|
||||
reaction_mob(var/mob/living/M, var/method=TOUCH, var/volume)//Splashing people with welding fuel to make them easy to ignite!
|
||||
if(!istype(M, /mob/living))
|
||||
return
|
||||
if(method == TOUCH)
|
||||
M.adjust_fire_stacks(volume / 10)
|
||||
return
|
||||
/*
|
||||
reaction_obj(var/obj/O, var/volume)
|
||||
@@ -1046,8 +1032,6 @@ datum
|
||||
reaction_mob(var/mob/living/M, var/method=TOUCH, var/volume)//Splashing people with welding fuel to make them easy to ignite!
|
||||
if(!istype(M, /mob/living))
|
||||
return
|
||||
if(method == TOUCH)
|
||||
M.adjust_fire_stacks(volume / 10)
|
||||
return
|
||||
|
||||
reaction_obj(var/obj/O, var/volume)
|
||||
@@ -1139,7 +1123,6 @@ datum
|
||||
if(!istype(M, /mob/living))
|
||||
return
|
||||
if(method == TOUCH)
|
||||
M.adjust_fire_stacks(volume / 5)
|
||||
..()
|
||||
return
|
||||
lexorin
|
||||
@@ -1767,13 +1750,13 @@ datum
|
||||
if(T.wet_overlay)
|
||||
T.overlays -= T.wet_overlay
|
||||
T.wet_overlay = null
|
||||
var/hotspot = (locate(/obj/fire) in T)
|
||||
var/hotspot = (locate(/obj/effect/hotspot) in T)
|
||||
if(hotspot)
|
||||
var/datum/gas_mixture/lowertemp = T.remove_air( T:air:total_moles() )
|
||||
lowertemp.temperature = max( min(lowertemp.temperature-2000,lowertemp.temperature / 2) ,0)
|
||||
lowertemp.react()
|
||||
T.assume_air(lowertemp)
|
||||
del(hotspot)
|
||||
qdel(hotspot)
|
||||
|
||||
enzyme
|
||||
name = "Denatured Enzyme"
|
||||
@@ -2471,9 +2454,6 @@ datum
|
||||
reaction_mob(var/mob/living/M, var/method=TOUCH, var/volume)//Splashing people with ethanol isn't quite as good as fuel.
|
||||
if(!istype(M, /mob/living))
|
||||
return
|
||||
if(method == TOUCH)
|
||||
M.adjust_fire_stacks(volume / 15)
|
||||
return
|
||||
|
||||
beer //It's really much more stronger than other drinks.
|
||||
name = "Beer"
|
||||
|
||||
@@ -644,19 +644,13 @@ datum
|
||||
required_container = /obj/item/slime_extract/orange
|
||||
required_other = 1
|
||||
on_reaction(var/datum/reagents/holder)
|
||||
for(var/mob/O in viewers(get_turf_loc(holder.my_atom), null))
|
||||
feedback_add_details("slime_cores_used","[replacetext(name," ","_")]")
|
||||
for(var/mob/O in viewers(get_turf(holder.my_atom), null))
|
||||
O.show_message(text("\red The slime extract begins to vibrate violently !"), 1)
|
||||
sleep(50)
|
||||
var/turf/location = get_turf(holder.my_atom.loc)
|
||||
for(var/turf/simulated/floor/target_tile in range(0,location))
|
||||
|
||||
var/datum/gas_mixture/napalm = new
|
||||
|
||||
napalm.toxins = 25
|
||||
napalm.temperature = 1400
|
||||
|
||||
target_tile.assume_air(napalm)
|
||||
spawn (0) target_tile.hotspot_expose(700, 400)
|
||||
var/turf/simulated/T = get_turf(src)
|
||||
if(istype(T))
|
||||
T.atmos_spawn_air("fire", 50)
|
||||
|
||||
//Yellow
|
||||
slimeoverload
|
||||
|
||||
@@ -90,7 +90,7 @@ datum/reagent/crank/addiction_act_stage4(var/mob/living/M as mob)
|
||||
/datum/chemical_reaction/crank/on_reaction(var/datum/reagents/holder, var/created_volume)
|
||||
var/turf/T = get_turf(holder.my_atom)
|
||||
for(var/turf/turf in range(1,T))
|
||||
new /obj/fire(turf)
|
||||
new /obj/effect/hotspot(turf)
|
||||
explosion(T,0,0,2)
|
||||
return
|
||||
|
||||
|
||||
@@ -37,15 +37,14 @@
|
||||
|
||||
/datum/reagent/clf3/on_mob_life(var/mob/living/M as mob)
|
||||
if(!M) M = holder.my_atom
|
||||
M.adjust_fire_stacks(4)
|
||||
M.adjustFireLoss(0.35*M.fire_stacks)
|
||||
M.adjustFireLoss(0.35*1)
|
||||
..()
|
||||
return
|
||||
|
||||
/datum/chemical_reaction/clf3/on_reaction(var/datum/reagents/holder, var/created_volume)
|
||||
var/turf/T = get_turf(holder.my_atom)
|
||||
for(var/turf/turf in range(1,T))
|
||||
new /obj/fire(turf)
|
||||
new /obj/effect/hotspot(turf)
|
||||
return
|
||||
|
||||
/datum/reagent/clf3/reaction_turf(var/turf/simulated/T, var/volume)
|
||||
@@ -58,7 +57,7 @@
|
||||
if(prob(volume/10))
|
||||
F.make_plating()
|
||||
if(istype(F, /turf/simulated/floor/))
|
||||
new /obj/fire(F)
|
||||
new /obj/effect/hotspot(F)
|
||||
if(istype(T, /turf/simulated/wall/))
|
||||
var/turf/simulated/wall/W = T
|
||||
if(prob(volume/10))
|
||||
@@ -67,8 +66,6 @@
|
||||
|
||||
/datum/reagent/clf3/reaction_mob(var/mob/living/M, var/method=TOUCH, var/volume)
|
||||
if(method == TOUCH && isliving(M))
|
||||
M.adjust_fire_stacks(5)
|
||||
M.IgniteMob()
|
||||
M.bodytemperature += 30
|
||||
return
|
||||
|
||||
@@ -415,14 +412,12 @@ datum/reagent/blackpowder/reaction_turf(var/turf/T, var/volume) //oh shit
|
||||
return
|
||||
var/turf/simulated/T = get_turf(holder.my_atom)
|
||||
for(var/turf/simulated/turf in range(created_volume/10,T))
|
||||
new /obj/fire(turf)
|
||||
new /obj/effect/hotspot(turf)
|
||||
return
|
||||
|
||||
/datum/reagent/phlogiston/on_mob_life(var/mob/living/M as mob)
|
||||
if(!M) M = holder.my_atom
|
||||
M.adjust_fire_stacks(1)
|
||||
M.IgniteMob()
|
||||
M.adjustFireLoss(0.2*M.fire_stacks)
|
||||
M.adjustFireLoss(0.2*1)
|
||||
..()
|
||||
return
|
||||
|
||||
@@ -435,13 +430,11 @@ datum/reagent/blackpowder/reaction_turf(var/turf/T, var/volume) //oh shit
|
||||
|
||||
/datum/reagent/napalm/on_mob_life(var/mob/living/M as mob)
|
||||
if(!M) M = holder.my_atom
|
||||
M.adjust_fire_stacks(1)
|
||||
..()
|
||||
return
|
||||
|
||||
/datum/reagent/napalm/reaction_mob(var/mob/living/M, var/method=TOUCH, var/volume)
|
||||
if(method == TOUCH && isliving(M))
|
||||
M.adjust_fire_stacks(7)
|
||||
return
|
||||
|
||||
/datum/chemical_reaction/napalm
|
||||
@@ -547,9 +540,6 @@ datum/reagent/firefighting_foam/reaction_mob(var/mob/living/M, var/method=TOUCH,
|
||||
|
||||
// Put out fire
|
||||
if(method == TOUCH)
|
||||
M.adjust_fire_stacks(-(volume / 5)) // more effective than water
|
||||
if(M.fire_stacks <= 0)
|
||||
M.ExtinguishMob()
|
||||
return
|
||||
|
||||
datum/reagent/firefighting_foam/reaction_turf(var/turf/simulated/T, var/volume)
|
||||
@@ -558,7 +548,7 @@ datum/reagent/firefighting_foam/reaction_turf(var/turf/simulated/T, var/volume)
|
||||
src = null
|
||||
if(!istype(T, /turf/space))
|
||||
new /obj/effect/decal/cleanable/flour/foam(T) //foam mess; clears up quickly.
|
||||
var/hotspot = (locate(/obj/fire) in T)
|
||||
var/hotspot = (locate(/obj/effect/hotspot) in T)
|
||||
if(hotspot && !istype(T, /turf/space))
|
||||
var/datum/gas_mixture/lowertemp = T.remove_air( T:air:total_moles() )
|
||||
lowertemp.temperature = max( min(lowertemp.temperature-(CT*1000),lowertemp.temperature / CT) ,0)
|
||||
@@ -570,7 +560,7 @@ datum/reagent/firefighting_foam/reaction_turf(var/turf/simulated/T, var/volume)
|
||||
datum/reagent/firefighting_foam/reaction_obj(var/obj/O, var/volume)
|
||||
src = null
|
||||
var/turf/T = get_turf(O)
|
||||
var/hotspot = (locate(/obj/fire) in T)
|
||||
var/hotspot = (locate(/obj/effect/hotspot) in T)
|
||||
if(hotspot && !istype(T, /turf/space))
|
||||
var/datum/gas_mixture/lowertemp = T.remove_air( T:air:total_moles() )
|
||||
lowertemp.temperature = max( min(lowertemp.temperature-2000,lowertemp.temperature / 2) ,0)
|
||||
|
||||
@@ -246,7 +246,7 @@
|
||||
else
|
||||
usr << "<span class='notice'>There is no assembly to remove.</span>"
|
||||
|
||||
/obj/item/weapon/reagent_containers/glass/beaker/ignite()
|
||||
/obj/item/weapon/reagent_containers/glass/beaker/fire_act()
|
||||
if(reagents)
|
||||
reagents.chem_temp += 30
|
||||
reagents.handle_reactions()
|
||||
|
||||
@@ -405,6 +405,7 @@
|
||||
//Actually transfer the gas
|
||||
var/datum/gas_mixture/removed = env.remove(transfer_moles)
|
||||
air_contents.merge(removed)
|
||||
air_update_turf()
|
||||
|
||||
|
||||
// if full enough, switch to ready mode
|
||||
|
||||
@@ -117,21 +117,22 @@
|
||||
removed.temperature = min((removed.temperature*heat_capacity + heating_power)/heat_capacity, 1000)
|
||||
|
||||
env.merge(removed)
|
||||
air_update_turf()
|
||||
|
||||
/obj/machinery/r_n_d/server/attackby(var/obj/item/O as obj, var/mob/user as mob, params)
|
||||
if (disabled)
|
||||
return
|
||||
|
||||
|
||||
if (shocked)
|
||||
shock(user,50)
|
||||
|
||||
if(istype(O, /obj/item/weapon/screwdriver))
|
||||
|
||||
if(istype(O, /obj/item/weapon/screwdriver))
|
||||
default_deconstruction_screwdriver(user, "server_o", "server")
|
||||
return 1
|
||||
|
||||
|
||||
if(exchange_parts(user, O))
|
||||
return 1
|
||||
|
||||
|
||||
if (panel_open)
|
||||
if(istype(O, /obj/item/weapon/crowbar))
|
||||
griefProtection()
|
||||
@@ -141,7 +142,7 @@
|
||||
/obj/machinery/r_n_d/server/attack_hand(mob/user as mob)
|
||||
if (disabled)
|
||||
return
|
||||
|
||||
|
||||
if (shocked)
|
||||
shock(user,50)
|
||||
return
|
||||
|
||||
@@ -22,5 +22,5 @@
|
||||
/datum/artifact_effect/gasco2/DoEffectAura()
|
||||
if(holder)
|
||||
var/datum/gas_mixture/env = holder.loc.return_air()
|
||||
if(env && env.total_moles < max_pressure)
|
||||
if(env && env.total_moles() < max_pressure)
|
||||
env.carbon_dioxide += pick(0, 0, 0.1, rand())
|
||||
|
||||
@@ -19,5 +19,5 @@
|
||||
/datum/artifact_effect/gasnitro/DoEffectAura()
|
||||
if(holder)
|
||||
var/datum/gas_mixture/env = holder.loc.return_air()
|
||||
if(env && env.total_moles < max_pressure)
|
||||
if(env && env.total_moles() < max_pressure)
|
||||
env.nitrogen += pick(0, 0, 0.1, rand())
|
||||
|
||||
@@ -19,5 +19,5 @@
|
||||
/datum/artifact_effect/gasoxy/DoEffectAura()
|
||||
if(holder)
|
||||
var/datum/gas_mixture/env = holder.loc.return_air()
|
||||
if(env && env.total_moles < max_pressure)
|
||||
if(env && env.total_moles() < max_pressure)
|
||||
env.oxygen += pick(0, 0, 0.1, rand())
|
||||
|
||||
@@ -19,5 +19,5 @@
|
||||
/datum/artifact_effect/gasplasma/DoEffectAura()
|
||||
if(holder)
|
||||
var/datum/gas_mixture/env = holder.loc.return_air()
|
||||
if(env && env.total_moles < max_pressure)
|
||||
if(env && env.total_moles() < max_pressure)
|
||||
env.toxins += pick(0, 0, 0.1, rand())
|
||||
|
||||
+1
-1
@@ -23,7 +23,7 @@
|
||||
/datum/artifact_effect/gassleeping/DoEffectAura()
|
||||
if(holder)
|
||||
var/datum/gas_mixture/env = holder.loc.return_air()
|
||||
if(env && env.total_moles < max_pressure)
|
||||
if(env && env.total_moles() < max_pressure)
|
||||
var/datum/gas/sleeping_agent/trace_gas = new
|
||||
env.trace_gases += trace_gas
|
||||
trace_gas.moles = pick(0, 0, 0.1, rand())
|
||||
|
||||
@@ -155,84 +155,67 @@
|
||||
if(grav_pulling)
|
||||
supermatter_pull()
|
||||
|
||||
//Ok, get the air from the turf
|
||||
var/datum/gas_mixture/removed = null
|
||||
var/datum/gas_mixture/env = null
|
||||
//Ok, get the air from the turf
|
||||
var/datum/gas_mixture/env = L.return_air()
|
||||
|
||||
//ensure that damage doesn't increase too quickly due to super high temperatures resulting from no coolant, for example. We dont want the SM exploding before anyone can react.
|
||||
//We want the cap to scale linearly with power (and explosion_point). Let's aim for a cap of 5 at power = 900 (based on testing, equals roughly 5% per SM alert announcement).
|
||||
var/damage_inc_limit = (power/900)*(explosion_point/1000)*DAMAGE_RATE_LIMIT
|
||||
//Remove gas from surrounding area
|
||||
var/datum/gas_mixture/removed = env.remove(gasefficency * env.total_moles())
|
||||
|
||||
if(!istype(L, /turf/space))
|
||||
env = L.return_air()
|
||||
removed = env.remove(gasefficency * env.total_moles) //Remove gas from surrounding area
|
||||
if(!removed || !removed.total_moles())
|
||||
damage += max((power-1600)/10, 0)
|
||||
power = min(power, 1600)
|
||||
return 1
|
||||
|
||||
if(!env || !removed || !removed.total_moles)
|
||||
damage += max(((power-(1600*POWER_FACTOR)))/10, 0) //exciting the supermatter in a vacuum means the internal energy is mostly locked inside.
|
||||
else if (grav_pulling) //If supermatter is detonating, remove all air from the zone
|
||||
env.remove(env.total_moles)
|
||||
damage_archived = damage
|
||||
damage = max( damage + ( (removed.temperature - 800) / 150 ) , 0 )
|
||||
//Ok, 100% oxygen atmosphere = best reaction
|
||||
//Maxes out at 100% oxygen pressure
|
||||
oxygen = max(min((removed.oxygen - (removed.nitrogen * NITROGEN_RETARDATION_FACTOR)) / MOLES_CELLSTANDARD, 1), 0)
|
||||
|
||||
var/temp_factor = 50
|
||||
|
||||
if(oxygen > 0.8)
|
||||
// with a perfect gas mix, make the power less based on heat
|
||||
icon_state = "[base_icon_state]_glow"
|
||||
else
|
||||
damage_archived = damage
|
||||
// in normal mode, base the produced energy around the heat
|
||||
temp_factor = 30
|
||||
icon_state = base_icon_state
|
||||
|
||||
damage = max( damage + min( ( (removed.temperature - 800) / 150 ), damage_inc_limit ) , 0 )
|
||||
//Ok, 100% oxygen atmosphere = best reaction
|
||||
//Maxes out at 100% oxygen pressure
|
||||
oxygen = max(min((removed.oxygen - (removed.nitrogen * NITROGEN_RETARDATION_FACTOR)) / MOLES_CELLSTANDARD, 1), 0)
|
||||
power = max( (removed.temperature * temp_factor / T0C) * oxygen + power, 0) //Total laser power plus an overload
|
||||
|
||||
var/temp_factor = 100
|
||||
//We've generated power, now let's transfer it to the collectors for storing/usage
|
||||
transfer_energy()
|
||||
|
||||
if(oxygen > 0.8)
|
||||
// with a perfect gas mix, make the power less based on heat
|
||||
icon_state = "[base_icon_state]_glow"
|
||||
else
|
||||
// in normal mode, base the produced energy around the heat
|
||||
temp_factor = 60
|
||||
icon_state = base_icon_state
|
||||
var/device_energy = power * REACTION_POWER_MODIFIER
|
||||
|
||||
power = max( (removed.temperature * temp_factor / T0C) * oxygen + power, 0) //Total laser power plus an overload
|
||||
//To figure out how much temperature to add each tick, consider that at one atmosphere's worth
|
||||
//of pure oxygen, with all four lasers firing at standard energy and no N2 present, at room temperature
|
||||
//that the device energy is around 2140. At that stage, we don't want too much heat to be put out
|
||||
//Since the core is effectively "cold"
|
||||
|
||||
//We've generated power, now let's transfer it to the collectors for storing/usage
|
||||
transfer_energy()
|
||||
//Also keep in mind we are only adding this temperature to (efficiency)% of the one tile the rock
|
||||
//is on. An increase of 4*C @ 25% efficiency here results in an increase of 1*C / (#tilesincore) overall.
|
||||
removed.temperature += (device_energy / THERMAL_RELEASE_MODIFIER)
|
||||
|
||||
var/device_energy = power * REACTION_POWER_MODIFIER
|
||||
removed.temperature = max(0, min(removed.temperature, 2500))
|
||||
|
||||
//To figure out how much temperature to add each tick, consider that at one atmosphere's worth
|
||||
//of pure oxygen, with all four lasers firing at standard energy and no N2 present, at room temperature
|
||||
//that the device energy is around 2140. At that stage, we don't want too much heat to be put out
|
||||
//Since the core is effectively "cold"
|
||||
//Calculate how much gas to release
|
||||
removed.toxins += max(device_energy / PLASMA_RELEASE_MODIFIER, 0)
|
||||
|
||||
//Also keep in mind we are only adding this temperature to (efficiency)% of the one tile the rock
|
||||
//is on. An increase of 4*C @ 25% efficiency here results in an increase of 1*C / (#tilesincore) overall.
|
||||
removed.oxygen += max((device_energy + removed.temperature - T0C) / OXYGEN_RELEASE_MODIFIER, 0)
|
||||
|
||||
var/thermal_power = THERMAL_RELEASE_MODIFIER
|
||||
|
||||
//This shouldn't be necessary. If the number of moles is low, then heat_capacity should be tiny.
|
||||
//if(removed.total_moles < 35) thermal_power += 750 //If you don't add coolant, you are going to have a bad time.
|
||||
|
||||
removed.temperature += ((device_energy * thermal_power) / removed.heat_capacity())
|
||||
|
||||
removed.temperature = max(0, min(removed.temperature, 10000))
|
||||
|
||||
//Calculate how much gas to release
|
||||
removed.toxins += max(device_energy / PLASMA_RELEASE_MODIFIER, 0)
|
||||
|
||||
removed.oxygen += max((device_energy + removed.temperature - T0C) / OXYGEN_RELEASE_MODIFIER, 0)
|
||||
|
||||
removed.update_values()
|
||||
|
||||
env.merge(removed)
|
||||
env.merge(removed)
|
||||
|
||||
for(var/mob/living/carbon/human/l in view(src, min(7, round(power ** 0.25)))) // If they can see it without mesons on. Bad on them.
|
||||
if(!istype(l.glasses, /obj/item/clothing/glasses/meson))
|
||||
l.hallucination = max(0, min(200, l.hallucination + power * config_hallucination_power * sqrt( 1 / max(1,get_dist(l, src)) ) ) )
|
||||
l.hallucination = max(0, min(200, l.hallucination + power * config_hallucination_power * sqrt( 1 / max(1, get_dist(l, src)) ) ) )
|
||||
|
||||
//adjusted range so that a power of 600 (pretty high) results in 8 tiles, roughly the distance from the core to the engine monitoring room.
|
||||
//at power of 1210 this becomes 9 tiles --> increases very very slowly.
|
||||
for(var/mob/living/l in range(src, round((power / 0.146484375) ** 0.25)))
|
||||
var/rads = (power / 10) * sqrt( 1 / get_dist(l, src) )
|
||||
l.apply_effect(rads, IRRADIATE)
|
||||
for(var/mob/living/l in range(src, round((power / 100) ** 0.25)))
|
||||
var/rads = (power / 10) * sqrt( 1 / max(get_dist(l, src),1) )
|
||||
l.apply_effect(irradiate=rads)
|
||||
|
||||
power -= (power/500)**3 //energy losses due to radiation
|
||||
power -= (power/500)**3
|
||||
|
||||
return 1
|
||||
|
||||
@@ -354,11 +337,4 @@
|
||||
|
||||
if(defer_powernet_rebuild != 2)
|
||||
defer_powernet_rebuild = 0
|
||||
return
|
||||
|
||||
|
||||
/obj/machinery/power/supermatter/GotoAirflowDest(n) //Supermatter not pushed around by airflow
|
||||
return
|
||||
|
||||
/obj/machinery/power/supermatter/RepelAirflowDest(n)
|
||||
return
|
||||
return
|
||||
Reference in New Issue
Block a user