fire update

enabled fire to destroy floors and objects
also tweaked the behaviour of glass to enable glasslocks against fire
also made fire extingiushers stop being useless
This commit is contained in:
LordBraindead
2013-07-14 21:20:45 +02:00
parent b777ae4bac
commit 08d2e22220
13 changed files with 264 additions and 227 deletions

View File

@@ -0,0 +1,15 @@
obj/effect/decal/cleanable/scorchmark
//this is used as an additional visual result of fire and as a reagent holder for fuel created by burning of turfs and items.
icon = 'icons/effects/scorchmark.dmi'
name = "Soot"
icon_state = "1"
layer = TURF_LAYER+0.1
anchored = 1
var/amount = 0 //starts always empty and is filled by procs called by fire
New(newLoc,start_amount=0)
..()
icon_state = pick("1","2","3","4","5","6","7","8","9")
dir = pick(cardinal)
amount = start_amount

View File

@@ -39,25 +39,25 @@ would spawn and follow the beaker, even if it is carried or thrown.
/obj/effect/effect/water/New()
..()
//var/turf/T = src.loc
//if (istype(T, /turf))
// T.firelevel = 0 //TODO: FIX
var/turf/simulated/floor/T = src.loc
if (istype(T, /turf/simulated/floor))
T.fire_protection = world.time
spawn( 70 )
delete()
return
return
/obj/effect/effect/water/Del()
//var/turf/T = src.loc
//if (istype(T, /turf))
// T.firelevel = 0 //TODO: FIX
var/turf/simulated/floor/T = src.loc
if (istype(T, /turf/simulated/floor))
T.fire_protection = world.time
..()
return
/obj/effect/effect/water/Move(turf/newloc)
//var/turf/T = src.loc
//if (istype(T, /turf))
// T.firelevel = 0 //TODO: FIX
var/turf/simulated/floor/T = src.loc
if (istype(T, /turf/simulated/floor))
T.fire_protection = world.time
if (--src.life < 1)
//SN src = null
delete()

View File

@@ -103,6 +103,9 @@ var/global/list/datum/stack_recipe/uranium_recipes = list ( \
origin_tech = "plasmatech=2;materials=2"
perunit = 2000
sheettype = "plasma"
fire_min_burn_temp = 500
fire_burn_multiplier = 3 //made of burnium
fire_fuel_worth = 0
var/global/list/datum/stack_recipe/plasma_recipes = list ( \
new/datum/stack_recipe("plasma door", /obj/structure/mineral_door/transparent/plasma, 10, one_per_turf = 1, on_floor = 1), \
@@ -114,6 +117,18 @@ var/global/list/datum/stack_recipe/plasma_recipes = list ( \
pixel_y = rand(0,4)-4
..()
/obj/item/stack/sheet/mineral/plasma/fire_burn()
//get location and check if it is in a proper ZAS zone
var/turf/simulated/floor/S = loc
if(S.zone)
var/datum/gas_mixture/air_contents = S.return_air()
if(air_contents)
air_contents.toxins += 20
air_contents.update_values()
amount -= 1
if(amount <= 0)
del src
/obj/item/stack/sheet/mineral/plastic
name = "Plastic"
icon_state = "sheet-plastic"
@@ -124,6 +139,7 @@ var/global/list/datum/stack_recipe/plasma_recipes = list ( \
throw_range = 3
origin_tech = "materials=3"
perunit = 2000
sheettype = "plastic"
var/global/list/datum/stack_recipe/plastic_recipes = list ( \
new/datum/stack_recipe("plastic crate", /obj/structure/closet/pcrate, 10, one_per_turf = 1, on_floor = 1), \

View File

@@ -20,6 +20,10 @@
var/construction_cost = list("metal"=750,"glass"=75)
var/construction_time=100
fire_min_burn_temp = 1000
fire_burn_multiplier = 0.75
fire_fuel_worth = 0
suicide_act(mob/user)
viewers(user) << "\red <b>[user] is licking the electrodes of the [src.name]! It looks like \he's trying to commit suicide.</b>"
return (FIRELOSS)
@@ -111,4 +115,12 @@
maxcharge = 10000
maxcharge = 10000
m_amt = 0
g_amt = 0
g_amt = 0
/obj/item/weapon/cell/fire_burn()
viewers(src) << "\red <b>Charge: [src.charge]</b>"
var/radius = round( (sqrt(charge)/30)+0.5, 1 )
viewers(src) << "\red <b>Radius: [radius]</b>"
if (radius >= 1)
explosion(src.loc,0,0,radius)
..()

View File

@@ -16,6 +16,11 @@
var/integrity = 3
var/volume = 70
m_amt = 3750
fire_min_burn_temp = 800
fire_burn_multiplier = 0.75
fire_fuel_worth = 0
/obj/item/weapon/tank/New()
..()
@@ -261,4 +266,11 @@
integrity--
else if(integrity < 3)
integrity++
integrity++
/obj/item/weapon/tank/fire_burn()
//get location and check if it is in a proper ZAS zone
var/turf/simulated/floor/S = loc
if(S.zone)
S.assume_air(air_contents)
..()

View File

@@ -76,11 +76,19 @@
icon_state = "wooden_chair"
name = "wooden chair"
desc = "Old is never too old to not be in fashion."
fire_min_burn_temp = 500
fire_burn_multiplier = 1.25
fire_fuel_worth = 5
m_amt = 0
/obj/structure/stool/bed/chair/wood/wings
icon_state = "wooden_chair_wings"
name = "wooden chair"
desc = "Old is never too old to not be in fashion."
fire_min_burn_temp = 500
fire_burn_multiplier = 1.25
fire_fuel_worth = 5
m_amt = 0
/obj/structure/stool/bed/chair/wood/attackby(obj/item/weapon/W as obj, mob/user as mob)
if(istype(W, /obj/item/weapon/wrench))
@@ -93,6 +101,9 @@
/obj/structure/stool/bed/chair/comfy
name = "comfy chair"
desc = "It looks comfy."
fire_min_burn_temp = 500
fire_burn_multiplier = 1.25
fire_fuel_worth = 4
/obj/structure/stool/bed/chair/comfy/brown
icon_state = "comfychair_brown"

View File

@@ -6,6 +6,10 @@
anchored = 1.0
flags = FPRINT
pressure_resistance = 15
m_amt = 3750
fire_min_burn_temp = 600
fire_burn_multiplier = 1
fire_fuel_worth = 2
/obj/structure/stool/ex_act(severity)
switch(severity)

View File

@@ -373,8 +373,9 @@
return
/obj/structure/window/temperature_expose(datum/gas_mixture/air, exposed_temperature, exposed_volume)
if(exposed_temperature > T0C + 800)
hit(round(exposed_volume / 100), 0)
//Since glasslocks are the only thing you can do to prevent spreading atmos issues, this was disabled for the time being
//if(exposed_temperature > T0C + 800)
// hit(round(exposed_volume / 100), 0)
..()