moar glass!

This commit is contained in:
S34NW
2021-05-01 20:33:40 +01:00
parent c7db5e0d16
commit 557d4e4af5
8 changed files with 59 additions and 34 deletions
+17 -25
View File
@@ -70,41 +70,33 @@
to_chat(user, "<span class='warning'>This section is too damaged to support a tile! Use a welder to fix the damage.</span>")
return TRUE
else if(istype(C, /obj/item/stack/sheet/glass))
else if(is_glass_sheet(C))
if(broken || burnt)
to_chat(user, "<span class='warning'>Repair the plating first!</span>")
return TRUE
var/obj/item/stack/sheet/glass/R = C
var/obj/item/stack/sheet/R = C
if(R.get_amount() < 2)
to_chat(user, "<span class='warning'>You need two sheets of glass to build a glass floor!</span>")
to_chat(user, "<span class='warning'>You need two sheets of [C] to build a [C] floor!</span>")
return TRUE
else
to_chat(user, "<span class='notice'>You begin swapping the plating for glass...</span>")
to_chat(user, "<span class='notice'>You begin swapping the plating for [C]...</span>")
if(do_after(user, 3 SECONDS * C.toolspeed, target = src))
if(R.get_amount() >= 2 && !istype(src, /turf/simulated/floor/transparent/glass))
ChangeTurf(/turf/simulated/floor/transparent/glass)
if(istype(C, /obj/item/stack/sheet/plasmaglass)) //So, what type of glass floor do we want today?
ChangeTurf(/turf/simulated/floor/transparent/glass/plasma)
else if(istype(C, /obj/item/stack/sheet/plasmarglass))
ChangeTurf(/turf/simulated/floor/transparent/glass/reinforced/plasma)
else if(istype(C, /obj/item/stack/sheet/glass))
ChangeTurf(/turf/simulated/floor/transparent/glass)
else if(istype(C, /obj/item/stack/sheet/rglass))
ChangeTurf(/turf/simulated/floor/transparent/glass/reinforced)
else if(istype(C, /obj/item/stack/sheet/titaniumglass))
ChangeTurf(/turf/simulated/floor/transparent/glass/titanium)
else if(istype(C, /obj/item/stack/sheet/plastitaniumglass))
ChangeTurf(/turf/simulated/floor/transparent/glass/titanium/plastic)
playsound(src, C.usesound, 80, TRUE)
R.use(2)
to_chat(user, "<span class='notice'>You swap the plating for glass.</span>")
new /obj/item/stack/sheet/metal(src, 2)
return TRUE
else if(istype(C, /obj/item/stack/sheet/rglass))
if(broken || burnt)
to_chat(user, "<span class='warning'>Repair the plating first!</span>")
return TRUE
var/obj/item/stack/sheet/rglass/R = C
if(R.get_amount() < 2)
to_chat(user, "<span class='warning'>You need two sheets of reinforced glass to build a reinforced glass floor!</span>")
return TRUE
else
to_chat(user, "<span class='notice'>You begin swapping the plating for reinforced glass...</span>")
if(do_after(user, 3 SECONDS * C.toolspeed, target = src))
if(R.get_amount() >= 2 && !istype(src, /turf/simulated/floor/transparent/glass/reinforced))
ChangeTurf(/turf/simulated/floor/transparent/glass/reinforced)
playsound(src, C.usesound, 80, TRUE)
R.use(2)
to_chat(user, "<span class='notice'>You swap the plating for reinforced glass.</span>")
to_chat(user, "<span class='notice'>You swap the plating for [C].</span>")
new /obj/item/stack/sheet/metal(src, 2)
return TRUE
+42 -9
View File
@@ -1,12 +1,11 @@
/turf/simulated/floor/transparent/glass
name = "glass floor"
desc = "Don't jump on it, or do, I'm not your mom."
desc = "Don't jump on it... Or do, I'm not your mom."
icon = 'icons/turf/floors/glass.dmi'
icon_state = "unsmooth"
baseturf = /turf/space
broken_states = list("damaged1", "damaged2", "damaged3")
smooth = SMOOTH_MORE
canSmoothWith = list(/turf/simulated/floor/transparent/glass)
smooth = SMOOTH_TRUE
canSmoothWith = list(/turf/simulated/floor/transparent/glass, /turf/simulated/floor/transparent/glass/reinforced, /turf/simulated/floor/transparent/glass/plasma, /turf/simulated/floor/transparent/glass/reinforced/plasma)
footstep = FOOTSTEP_PLATING
light_power = 0.25
light_range = 2
@@ -30,24 +29,32 @@
var/obj/item/stack/R = user.get_inactive_hand()
if(istype(R, /obj/item/stack/sheet/metal))
if(R.get_amount() < 2) //not enough metal in the stack
to_chat(user, "<span class='danger'>You also need to hold two sheets of metal to dismantle [src]!</span>")
to_chat(user, "<span class='danger'>You also need to hold two sheets of metal to dismantle \the [src]!</span>")
return
else
to_chat(user, "<span class='notice'>You begin replacing the glass...</span>")
to_chat(user, "<span class='notice'>You begin replacing \the [src]...</span>")
playsound(src, C.usesound, 80, TRUE)
if(do_after(user, 3 SECONDS * C.toolspeed, target = src))
if(R.get_amount() >= 2 && !istype(src, /turf/simulated/floor/plating))
if(!transparent_floor)
return
if(istype(src, /turf/simulated/floor/transparent/glass/reinforced))
if(istype(src, /turf/simulated/floor/transparent/glass/reinforced)) //What material is returned? Depends on the turf
new /obj/item/stack/sheet/rglass(src, 2)
else
else if(istype(src, /turf/simulated/floor/transparent/glass))
new /obj/item/stack/sheet/glass(src, 2)
else if(istype(src, /turf/simulated/floor/transparent/glass/plasma))
new /obj/item/stack/sheet/plasmaglass(src, 2)
else if(istype(src, /turf/simulated/floor/transparent/glass/reinforced/plasma))
new /obj/item/stack/sheet/plasmarglass(src, 2)
else if(istype(src, /turf/simulated/floor/transparent/glass/titanium))
new /obj/item/stack/sheet/titaniumglass(src, 2)
else if(istype(src, /turf/simulated/floor/transparent/glass/titanium/plastic))
new /obj/item/stack/sheet/plastitaniumglass(src, 2)
R.use(2)
ChangeTurf(/turf/simulated/floor/plating)
else //not holding metal at all
to_chat(user, "<span class='danger'>You also need to hold two sheets of metal to dismantle [src]!</span>")
to_chat(user, "<span class='danger'>You also need to hold two sheets of metal to dismantle \the [src]!</span>")
return
@@ -61,3 +68,29 @@
/turf/simulated/floor/transparent/glass/reinforced/acid_act(acidpwr, acid_volume)
acidpwr = min(acidpwr, 50)
. = ..()
/turf/simulated/floor/transparent/glass/plasma
name = "plasma glass floor"
desc = "Wait, was space always that color?"
icon = 'icons/turf/floors/plasmaglass.dmi'
thermal_conductivity = 0.030
heat_capacity = 75000
/turf/simulated/floor/transparent/glass/reinforced/plasma
name = "reinforced plasma glass floor"
desc = "For when you REALLY don't want your floor choice to suffocate everyone."
icon = 'icons/turf/floors/reinf_plasmaglass.dmi'
thermal_conductivity = 0.025
heat_capacity = 325000
/turf/simulated/floor/transparent/glass/titanium
name = "titanium glass floor"
canSmoothWith = list(/turf/simulated/floor/transparent/glass/titanium, /turf/simulated/floor/transparent/glass/titanium/plastic)
desc = "Stylish AND strong!"
icon = 'icons/turf/floors/titaniumglass.dmi'
thermal_conductivity = 0.025
heat_capacity = 325000
/turf/simulated/floor/transparent/glass/titanium/plastic
name = "plastitanium glass floor"
icon = 'icons/turf/floors/plastitaniumglass.dmi'
Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.6 KiB

After

Width:  |  Height:  |  Size: 2.3 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 5.9 KiB

After

Width:  |  Height:  |  Size: 3.8 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.2 KiB