mirror of
https://github.com/CHOMPstation/CHOMPstation.git
synced 2026-08-29 15:06:39 +01:00
Fixes #9581
This commit is contained in:
+5
-10
@@ -76,32 +76,27 @@ var/global/list/ashtray_cache = list()
|
||||
health = max(0,health - W.force)
|
||||
user << "You hit [src] with [W]."
|
||||
if (health < 1)
|
||||
die()
|
||||
shatter()
|
||||
return
|
||||
|
||||
/obj/item/weapon/material/ashtray/throw_impact(atom/hit_atom)
|
||||
if (health > 0)
|
||||
health = max(0,health - 3)
|
||||
if (health < 1)
|
||||
die()
|
||||
return
|
||||
if (contents.len)
|
||||
src.visible_message("<span class='danger'>\The [src] slams into [hit_atom], spilling its contents!</span>")
|
||||
for (var/obj/item/clothing/mask/smokable/cigarette/O in contents)
|
||||
O.loc = src.loc
|
||||
if (health < 1)
|
||||
shatter()
|
||||
return
|
||||
update_icon()
|
||||
return ..()
|
||||
|
||||
/obj/item/weapon/material/ashtray/proc/die()
|
||||
material.place_shard(get_turf(src))
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
/obj/item/weapon/material/ashtray/plastic/New(var/newloc)
|
||||
..(newloc, "plastic")
|
||||
|
||||
/obj/item/weapon/material/ashtray/bronze/New(var/newloc)
|
||||
..(newloc, "gold") //placeholder
|
||||
..(newloc, "bronze")
|
||||
|
||||
/obj/item/weapon/material/ashtray/glass/New(var/newloc)
|
||||
..(newloc, "glass")
|
||||
@@ -72,7 +72,7 @@
|
||||
var/mob/living/M = loc
|
||||
M.drop_from_inventory(src)
|
||||
playsound(src, "shatter", 70, 1)
|
||||
new material.shard_type(T)
|
||||
material.place_shard(T)
|
||||
qdel(src)
|
||||
|
||||
/obj/item/weapon/material/process()
|
||||
@@ -82,18 +82,12 @@
|
||||
L.apply_effect(round(material.radioactivity/3),IRRADIATE,0)
|
||||
|
||||
/obj/item/weapon/material/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume)
|
||||
if(exposed_temperature > material.ignition_point)
|
||||
TemperatureAct(exposed_temperature)
|
||||
TemperatureAct(exposed_temperature)
|
||||
|
||||
// This might need adjustment. Will work that out later.
|
||||
/obj/item/weapon/material/proc/TemperatureAct(temperature)
|
||||
if(temperature > material.ignition_point)
|
||||
for(var/turf/simulated/floor/target_tile in range(2,loc))
|
||||
var/phoronToDeduce = temperature/30
|
||||
target_tile.assume_gas("phoron", phoronToDeduce, 200+T0C)
|
||||
spawn (0) target_tile.hotspot_expose(temperature, 400)
|
||||
health -= phoronToDeduce/100
|
||||
check_health()
|
||||
health -= material.combustion_effect(get_turf(src), temperature, 0.1)
|
||||
check_health()
|
||||
|
||||
/obj/item/weapon/material/attackby(obj/item/weapon/W as obj, mob/user as mob)
|
||||
if(istype(W,/obj/item/weapon/weldingtool))
|
||||
|
||||
@@ -13,17 +13,11 @@
|
||||
var/oreAmount = 7
|
||||
|
||||
/obj/structure/simple_door/fire_act(datum/gas_mixture/air, exposed_temperature, exposed_volume)
|
||||
if(exposed_temperature > material.ignition_point)
|
||||
TemperatureAct(exposed_temperature)
|
||||
TemperatureAct(exposed_temperature)
|
||||
|
||||
/obj/structure/simple_door/proc/TemperatureAct(temperature)
|
||||
if(temperature > material.ignition_point)
|
||||
for(var/turf/simulated/floor/target_tile in range(2,loc))
|
||||
var/phoronToDeduce = temperature/10
|
||||
target_tile.assume_gas("phoron", phoronToDeduce, 200+T0C)
|
||||
spawn (0) target_tile.hotspot_expose(temperature, 400)
|
||||
hardness -= phoronToDeduce/100
|
||||
CheckHardness()
|
||||
hardness -= material.combustion_effect(get_turf(src),temperature, 0.3)
|
||||
CheckHardness()
|
||||
|
||||
/obj/structure/simple_door/New(var/newloc, var/material_name)
|
||||
..()
|
||||
|
||||
Reference in New Issue
Block a user