mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-29 15:08:02 +01:00
Merge branch 'master' of https://github.com/ParadiseSS13/Paradise into HereWeGoAgain
This commit is contained in:
@@ -1,136 +0,0 @@
|
||||
///////////
|
||||
// EASEL //
|
||||
///////////
|
||||
|
||||
/obj/structure/easel
|
||||
name = "easel"
|
||||
desc = "only for the finest of art!"
|
||||
icon = 'icons/obj/artstuff.dmi'
|
||||
icon_state = "easel"
|
||||
density = 1
|
||||
burn_state = FLAMMABLE
|
||||
burntime = 15
|
||||
var/obj/item/canvas/painting = null
|
||||
|
||||
/obj/structure/easel/Destroy()
|
||||
QDEL_NULL(painting)
|
||||
return ..()
|
||||
|
||||
//Adding canvases
|
||||
/obj/structure/easel/attackby(var/obj/item/I, var/mob/user, params)
|
||||
if(istype(I, /obj/item/canvas))
|
||||
var/obj/item/canvas/C = I
|
||||
user.unEquip(C)
|
||||
painting = C
|
||||
C.loc = get_turf(src)
|
||||
C.layer = layer+0.1
|
||||
user.visible_message("<span class='notice'>[user] puts \the [C] on \the [src].</span>","<span class='notice'>You place \the [C] on \the [src].</span>")
|
||||
return
|
||||
|
||||
..()
|
||||
|
||||
|
||||
//Stick to the easel like glue
|
||||
/obj/structure/easel/Move()
|
||||
var/turf/T = get_turf(src)
|
||||
..()
|
||||
if(painting && painting.loc == T) //Only move if it's near us.
|
||||
painting.loc = get_turf(src)
|
||||
else
|
||||
painting = null
|
||||
|
||||
|
||||
//////////////
|
||||
// CANVASES //
|
||||
//////////////
|
||||
|
||||
#define AMT_OF_CANVASES 4 //Keep this up to date or shit will break.
|
||||
|
||||
//To safe memory on making /icons we cache the blanks..
|
||||
var/global/list/globalBlankCanvases[AMT_OF_CANVASES]
|
||||
|
||||
/obj/item/canvas
|
||||
name = "11px by 11px canvas"
|
||||
desc = "Draw out your soul on this canvas! Only crayons can draw on it. Examine it to focus on the canvas."
|
||||
icon = 'icons/obj/artstuff.dmi'
|
||||
icon_state = "11x11"
|
||||
burn_state = FLAMMABLE
|
||||
var/whichGlobalBackup = 1 //List index
|
||||
|
||||
/obj/item/canvas/nineteenXnineteen
|
||||
name = "19px by 19px canvas"
|
||||
icon_state = "19x19"
|
||||
whichGlobalBackup = 2
|
||||
|
||||
/obj/item/canvas/twentythreeXnineteen
|
||||
name = "23px by 19px canvas"
|
||||
icon_state = "23x19"
|
||||
whichGlobalBackup = 3
|
||||
|
||||
/obj/item/canvas/twentythreeXtwentythree
|
||||
name = "23px by 23px canvas"
|
||||
icon_state = "23x23"
|
||||
whichGlobalBackup = 4
|
||||
|
||||
|
||||
//Find the right size blank canvas
|
||||
/obj/item/canvas/proc/getGlobalBackup()
|
||||
. = null
|
||||
if(globalBlankCanvases[whichGlobalBackup])
|
||||
. = globalBlankCanvases[whichGlobalBackup]
|
||||
else
|
||||
var/icon/I = icon(initial(icon),initial(icon_state))
|
||||
globalBlankCanvases[whichGlobalBackup] = I
|
||||
. = I
|
||||
|
||||
|
||||
|
||||
//One pixel increments
|
||||
/obj/item/canvas/attackby(var/obj/item/I, var/mob/user, params)
|
||||
//Click info
|
||||
var/list/click_params = params2list(params)
|
||||
var/pixX = text2num(click_params["icon-x"])
|
||||
var/pixY = text2num(click_params["icon-y"])
|
||||
|
||||
//Should always be true, otherwise you didn't click the object, but let's check because SS13~
|
||||
if(!click_params || !click_params["icon-x"] || !click_params["icon-y"])
|
||||
return
|
||||
|
||||
var/icon/masterpiece = icon(icon,icon_state)
|
||||
//Cleaning one pixel with a soap or rag
|
||||
if(istype(I, /obj/item/soap) || istype(I, /obj/item/reagent_containers/glass/rag))
|
||||
//Pixel info created only when needed
|
||||
var/thePix = masterpiece.GetPixel(pixX,pixY)
|
||||
var/icon/Ico = getGlobalBackup()
|
||||
if(!Ico)
|
||||
qdel(masterpiece)
|
||||
return
|
||||
|
||||
var/theOriginalPix = Ico.GetPixel(pixX,pixY)
|
||||
if(thePix != theOriginalPix) //colour changed
|
||||
DrawPixelOn(theOriginalPix,pixX,pixY)
|
||||
qdel(masterpiece)
|
||||
return 1
|
||||
|
||||
//Drawing one pixel with a crayon
|
||||
if(istype(I, /obj/item/toy/crayon))
|
||||
var/obj/item/toy/crayon/C = I
|
||||
var/pix = masterpiece.GetPixel(pixX, pixY)
|
||||
if(pix && pix != C.colour) // if the located pixel isn't blank (null))
|
||||
DrawPixelOn(C.colour, pixX, pixY)
|
||||
qdel(masterpiece)
|
||||
return 1
|
||||
|
||||
..()
|
||||
|
||||
//Clean the whole canvas
|
||||
/obj/item/canvas/attack_self(var/mob/user)
|
||||
if(!user)
|
||||
return
|
||||
var/icon/blank = getGlobalBackup()
|
||||
if(blank)
|
||||
//it's basically a giant etch-a-sketch
|
||||
icon = blank
|
||||
user.visible_message("<span class='notice'>[user] cleans the canvas.</span>","<span class='notice'>You clean the canvas.</span>")
|
||||
|
||||
#undef AMT_OF_CANVASES
|
||||
@@ -206,9 +206,7 @@
|
||||
if(!(E.rcell && E.rcell.use(E.chargecost)))
|
||||
to_chat(user, "<span class='notice'>Unable to teleport, insufficient charge.</span>")
|
||||
return
|
||||
var/datum/effect_system/spark_spread/s = new /datum/effect_system/spark_spread
|
||||
s.set_up(5, 1, src)
|
||||
s.start()
|
||||
do_sparks(5, 1, src)
|
||||
do_teleport(src, E.pad, 0)
|
||||
to_chat(user, "<span class='notice'>Teleport successful. [round(E.rcell.charge/E.chargecost)] charge\s left.</span>")
|
||||
return
|
||||
@@ -233,9 +231,7 @@
|
||||
if(!(E.rcell && E.rcell.use(E.chargecost)))
|
||||
to_chat(user, "<span class='notice'>Unable to teleport, insufficient charge.</span>")
|
||||
return
|
||||
var/datum/effect_system/spark_spread/s = new /datum/effect_system/spark_spread
|
||||
s.set_up(5, 1, src)
|
||||
s.start()
|
||||
do_sparks(5, 1, src)
|
||||
do_teleport(src, L)
|
||||
to_chat(user, "<span class='notice'>Teleport successful. [round(E.rcell.charge/E.chargecost)] charge\s left.</span>")
|
||||
return
|
||||
@@ -423,4 +419,7 @@
|
||||
|
||||
/obj/structure/closet/get_remote_view_fullscreens(mob/user)
|
||||
if(user.stat == DEAD || !(user.sight & (SEEOBJS|SEEMOBS)))
|
||||
user.overlay_fullscreen("remote_view", /obj/screen/fullscreen/impaired, 1)
|
||||
user.overlay_fullscreen("remote_view", /obj/screen/fullscreen/impaired, 1)
|
||||
|
||||
/obj/structure/closet/AllowDrop()
|
||||
return TRUE
|
||||
@@ -60,9 +60,7 @@
|
||||
if(allowed(user))
|
||||
locked = !locked
|
||||
playsound(loc, 'sound/machines/click.ogg', 15, 1, -3)
|
||||
for(var/mob/O in viewers(user, 3))
|
||||
if((O.client && !( O.blinded )))
|
||||
to_chat(O, "<span class='notice'>The locker has been [locked ? null : "un"]locked by [user].</span>")
|
||||
visible_message("<span class='notice'>The locker has been [locked ? null : "un"]locked by [user].</span>")
|
||||
update_icon()
|
||||
else
|
||||
to_chat(user, "<span class='notice'>Access Denied</span>")
|
||||
@@ -93,12 +91,11 @@
|
||||
|
||||
/obj/structure/closet/secure_closet/emag_act(mob/user)
|
||||
if(!broken)
|
||||
broken = 1
|
||||
locked = 0
|
||||
desc = "It appears to be broken."
|
||||
broken = TRUE
|
||||
locked = FALSE
|
||||
icon_state = icon_off
|
||||
flick(icon_broken, src)
|
||||
to_chat(user, "<span class='notice'>You unlock \the [src].</span>")
|
||||
to_chat(user, "<span class='notice'>You break the lock on \the [src].</span>")
|
||||
|
||||
/obj/structure/closet/secure_closet/attack_hand(mob/user)
|
||||
add_fingerprint(user)
|
||||
|
||||
@@ -253,6 +253,7 @@
|
||||
new /obj/item/clothing/accessory/holster(src)
|
||||
new /obj/item/clothing/accessory/blue(src)
|
||||
new /obj/item/clothing/shoes/jackboots/jacksandals(src)
|
||||
new /obj/item/clothing/under/rank/centcom/blueshield(src)
|
||||
|
||||
|
||||
/obj/structure/closet/secure_closet/ntrep
|
||||
|
||||
@@ -156,8 +156,8 @@
|
||||
|
||||
/obj/structure/closet/wardrobe/yellow
|
||||
name = "yellow wardrobe"
|
||||
icon_state = "wardrobe-y"
|
||||
icon_closed = "wardrobe-y"
|
||||
icon_state = "yellow"
|
||||
icon_closed = "yellow"
|
||||
|
||||
/obj/structure/closet/wardrobe/yellow/New()
|
||||
..()
|
||||
|
||||
@@ -38,15 +38,13 @@
|
||||
if(isliving(usr))
|
||||
var/mob/living/L = usr
|
||||
if(L.electrocute_act(17, src))
|
||||
var/datum/effect_system/spark_spread/s = new /datum/effect_system/spark_spread
|
||||
s.set_up(5, 1, src)
|
||||
s.start()
|
||||
do_sparks(5, 1, src)
|
||||
return 2
|
||||
|
||||
playsound(src.loc, 'sound/machines/click.ogg', 15, 1, -3)
|
||||
for(var/obj/O in src) //Objects
|
||||
O.forceMove(loc)
|
||||
for(var/mob/M in src) //Mobs
|
||||
O.forceMove(loc)
|
||||
for(var/mob/M in src) //Mobs
|
||||
M.forceMove(loc)
|
||||
icon_state = icon_opened
|
||||
src.opened = 1
|
||||
@@ -69,8 +67,8 @@
|
||||
break
|
||||
if(O.density || O.anchored || istype(O,/obj/structure/closet))
|
||||
continue
|
||||
if(istype(O, /obj/structure/stool/bed)) //This is only necessary because of rollerbeds and swivel chairs.
|
||||
var/obj/structure/stool/bed/B = O
|
||||
if(istype(O, /obj/structure/bed)) //This is only necessary because of rollerbeds and swivel chairs.
|
||||
var/obj/structure/bed/B = O
|
||||
if(B.buckled_mob)
|
||||
continue
|
||||
O.forceMove(src)
|
||||
@@ -115,9 +113,7 @@
|
||||
if(!(E.rcell && E.rcell.use(E.chargecost)))
|
||||
to_chat(user, "<span class='notice'>Unable to teleport, insufficient charge.</span>")
|
||||
return
|
||||
var/datum/effect_system/spark_spread/s = new /datum/effect_system/spark_spread
|
||||
s.set_up(5, 1, src)
|
||||
s.start()
|
||||
do_sparks(5, 1, src)
|
||||
do_teleport(src, E.pad, 0)
|
||||
to_chat(user, "<span class='notice'>Teleport successful. [round(E.rcell.charge/E.chargecost)] charge\s left.</span>")
|
||||
return
|
||||
@@ -139,9 +135,7 @@
|
||||
if(!(E.rcell && E.rcell.use(E.chargecost)))
|
||||
to_chat(user, "<span class='notice'>Unable to teleport, insufficient charge.</span>")
|
||||
return
|
||||
var/datum/effect_system/spark_spread/s = new /datum/effect_system/spark_spread
|
||||
s.set_up(5, 1, src)
|
||||
s.start()
|
||||
do_sparks(5, 1, src)
|
||||
do_teleport(src, L)
|
||||
to_chat(user, "<span class='notice'>Teleport successful. [round(E.rcell.charge/E.chargecost)] charge\s left.</span>")
|
||||
return
|
||||
@@ -217,9 +211,7 @@
|
||||
if(isliving(user))
|
||||
var/mob/living/L = user
|
||||
if(L.electrocute_act(17, src))
|
||||
var/datum/effect_system/spark_spread/s = new /datum/effect_system/spark_spread
|
||||
s.set_up(5, 1, src)
|
||||
s.start()
|
||||
do_sparks(5, 1, src)
|
||||
return
|
||||
src.add_fingerprint(user)
|
||||
src.toggle(user)
|
||||
@@ -270,9 +262,7 @@
|
||||
return
|
||||
if(src.allowed(user))
|
||||
src.locked = !src.locked
|
||||
for(var/mob/O in viewers(user, 3))
|
||||
if((O.client && !( O.blinded )))
|
||||
to_chat(O, "<span class='notice'>The crate has been [locked ? null : "un"]locked by [user].</span>")
|
||||
visible_message("<span class='notice'>The crate has been [locked ? null : "un"]locked by [user].</span>")
|
||||
update_icon()
|
||||
else
|
||||
to_chat(user, "<span class='notice'>Access Denied</span>")
|
||||
|
||||
@@ -21,33 +21,33 @@
|
||||
switch(choice)
|
||||
if("Underwear")
|
||||
var/list/valid_underwear = list()
|
||||
for(var/underwear in underwear_list)
|
||||
var/datum/sprite_accessory/S = underwear_list[underwear]
|
||||
for(var/underwear in GLOB.underwear_list)
|
||||
var/datum/sprite_accessory/S = GLOB.underwear_list[underwear]
|
||||
if(!(H.dna.species.name in S.species_allowed))
|
||||
continue
|
||||
valid_underwear[underwear] = underwear_list[underwear]
|
||||
valid_underwear[underwear] = GLOB.underwear_list[underwear]
|
||||
var/new_underwear = input(user, "Choose your underwear:", "Changing") as null|anything in valid_underwear
|
||||
if(new_underwear)
|
||||
H.underwear = new_underwear
|
||||
|
||||
if("Undershirt")
|
||||
var/list/valid_undershirts = list()
|
||||
for(var/undershirt in undershirt_list)
|
||||
var/datum/sprite_accessory/S = undershirt_list[undershirt]
|
||||
for(var/undershirt in GLOB.undershirt_list)
|
||||
var/datum/sprite_accessory/S = GLOB.undershirt_list[undershirt]
|
||||
if(!(H.dna.species.name in S.species_allowed))
|
||||
continue
|
||||
valid_undershirts[undershirt] = undershirt_list[undershirt]
|
||||
valid_undershirts[undershirt] = GLOB.undershirt_list[undershirt]
|
||||
var/new_undershirt = input(user, "Choose your undershirt:", "Changing") as null|anything in valid_undershirts
|
||||
if(new_undershirt)
|
||||
H.undershirt = new_undershirt
|
||||
|
||||
if("Socks")
|
||||
var/list/valid_sockstyles = list()
|
||||
for(var/sockstyle in socks_list)
|
||||
var/datum/sprite_accessory/S = socks_list[sockstyle]
|
||||
for(var/sockstyle in GLOB.socks_list)
|
||||
var/datum/sprite_accessory/S = GLOB.socks_list[sockstyle]
|
||||
if(!(H.dna.species.name in S.species_allowed))
|
||||
continue
|
||||
valid_sockstyles[sockstyle] = socks_list[sockstyle]
|
||||
valid_sockstyles[sockstyle] = GLOB.socks_list[sockstyle]
|
||||
var/new_socks = input(user, "Choose your socks:", "Changing") as null|anything in valid_sockstyles
|
||||
if(new_socks)
|
||||
H.socks = new_socks
|
||||
|
||||
@@ -1,14 +1,15 @@
|
||||
/obj/structure/stool/bed/chair/e_chair
|
||||
/obj/structure/chair/e_chair
|
||||
name = "electric chair"
|
||||
desc = "Looks absolutely SHOCKING!"
|
||||
icon_state = "echair0"
|
||||
item_chair = null
|
||||
var/obj/item/assembly/shock_kit/part = null
|
||||
var/last_time = 1.0
|
||||
var/delay_time = 50
|
||||
|
||||
/obj/structure/stool/bed/chair/e_chair/New()
|
||||
/obj/structure/chair/e_chair/New()
|
||||
..()
|
||||
overlays += image('icons/obj/objects.dmi', src, "echair_over", MOB_LAYER + 1, dir)
|
||||
overlays += image('icons/obj/chairs.dmi', src, "echair_over", MOB_LAYER + 1, dir)
|
||||
spawn(2)
|
||||
if(isnull(part)) //This e-chair was not custom built
|
||||
part = new(src)
|
||||
@@ -19,11 +20,10 @@
|
||||
part2.master = part
|
||||
part.part1 = part1
|
||||
part.part2 = part2
|
||||
return
|
||||
|
||||
/obj/structure/stool/bed/chair/e_chair/attackby(obj/item/W as obj, mob/user as mob, params)
|
||||
/obj/structure/chair/e_chair/attackby(obj/item/W as obj, mob/user as mob, params)
|
||||
if(istype(W, /obj/item/wrench))
|
||||
var/obj/structure/stool/bed/chair/C = new /obj/structure/stool/bed/chair(loc)
|
||||
var/obj/structure/chair/C = new /obj/structure/chair(loc)
|
||||
playsound(loc, W.usesound, 50, 1)
|
||||
C.dir = dir
|
||||
part.loc = loc
|
||||
@@ -31,9 +31,8 @@
|
||||
part = null
|
||||
qdel(src)
|
||||
return
|
||||
return
|
||||
|
||||
/obj/structure/stool/bed/chair/e_chair/verb/activate_e_chair()
|
||||
/obj/structure/chair/e_chair/verb/activate_e_chair()
|
||||
set name = "Activate Electric Chair"
|
||||
set category = "Object"
|
||||
set src in oview(1)
|
||||
@@ -44,15 +43,13 @@
|
||||
return
|
||||
to_chat(usr, "<span class='notice'>You activate \the [src].</span>")
|
||||
shock()
|
||||
return
|
||||
|
||||
/obj/structure/stool/bed/chair/e_chair/rotate()
|
||||
/obj/structure/chair/e_chair/rotate()
|
||||
..()
|
||||
overlays.Cut()
|
||||
overlays += image('icons/obj/objects.dmi', src, "echair_over", MOB_LAYER + 1, dir) //there's probably a better way of handling this, but eh. -Pete
|
||||
return
|
||||
overlays += image('icons/obj/chairs.dmi', src, "echair_over", MOB_LAYER + 1, dir) //there's probably a better way of handling this, but eh. -Pete
|
||||
|
||||
/obj/structure/stool/bed/chair/e_chair/proc/shock()
|
||||
/obj/structure/chair/e_chair/proc/shock()
|
||||
if(last_time + delay_time > world.time)
|
||||
return
|
||||
last_time = world.time
|
||||
@@ -72,9 +69,7 @@
|
||||
A.updateicon()
|
||||
|
||||
flick("echair_shock", src)
|
||||
var/datum/effect_system/spark_spread/s = new /datum/effect_system/spark_spread
|
||||
s.set_up(12, 1, src)
|
||||
s.start()
|
||||
do_sparks(12, 1, src)
|
||||
visible_message("<span class='danger'>The electric chair went off!</span>", "<span class='danger'>You hear a deep sharp shock!</span>")
|
||||
if(buckled_mob)
|
||||
buckled_mob.electrocute_act(110, src, 1)
|
||||
|
||||
@@ -1,3 +1,8 @@
|
||||
#define NO_EXTINGUISHER 0
|
||||
#define NORMAL_EXTINGUISHER 1
|
||||
#define MINI_EXTINGUISHER 2
|
||||
|
||||
|
||||
/obj/structure/extinguisher_cabinet
|
||||
name = "extinguisher cabinet"
|
||||
desc = "A small wall mounted cabinet designed to hold a fire extinguisher."
|
||||
@@ -5,13 +10,28 @@
|
||||
icon_state = "extinguisher_closed"
|
||||
anchored = 1
|
||||
density = 0
|
||||
var/obj/item/extinguisher/has_extinguisher = new/obj/item/extinguisher
|
||||
var/obj/item/extinguisher/has_extinguisher = null
|
||||
var/extinguishertype
|
||||
var/opened = 0
|
||||
var/material_drop = /obj/item/stack/sheet/metal
|
||||
|
||||
/obj/structure/extinguisher_cabinet/New(turf/loc, ndir = null)
|
||||
..()
|
||||
if(ndir)
|
||||
pixel_x = (ndir & EAST|WEST) ? (ndir == EAST ? 28 : -28) : 0
|
||||
pixel_y = (ndir & NORTH|SOUTH)? (ndir == WEST ? 28 : -28) : 0
|
||||
switch(extinguishertype)
|
||||
if(NO_EXTINGUISHER)
|
||||
return
|
||||
if(MINI_EXTINGUISHER)
|
||||
has_extinguisher = new/obj/item/extinguisher/mini
|
||||
else
|
||||
has_extinguisher = new/obj/item/extinguisher
|
||||
|
||||
/obj/structure/extinguisher_cabinet/Destroy()
|
||||
QDEL_NULL(has_extinguisher)
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/structure/extinguisher_cabinet/attackby(obj/item/O, mob/user, params)
|
||||
if(isrobot(user) || isalien(user))
|
||||
return
|
||||
@@ -23,13 +43,34 @@
|
||||
to_chat(user, "<span class='notice'>You place [O] in [src].</span>")
|
||||
else
|
||||
opened = !opened
|
||||
else if(istype(O, /obj/item/weldingtool))
|
||||
if(has_extinguisher)
|
||||
to_chat(user, "<span class='warning'>You need to remove the extinguisher before deconstructing the cabinet!</span>")
|
||||
return
|
||||
if(!opened)
|
||||
to_chat(user, "<span class='warning'>Open the cabinet before cutting it apart!</span>")
|
||||
return
|
||||
var/obj/item/weldingtool/WT = O
|
||||
if(!WT.remove_fuel(0, user))
|
||||
return
|
||||
to_chat(user, "<span class='notice'>You begin cutting [src] apart...</span>")
|
||||
playsound(loc, WT.usesound, 40, 1)
|
||||
if(do_after(user, 40 * WT.toolspeed, 1, target = src))
|
||||
if(!src ||!opened || !WT.isOn()) // !src to prevent it being duped
|
||||
return
|
||||
visible_message("<span class='notice'>[user] slices apart [src].</span>",
|
||||
"<span class='notice'>You cut [src] apart with [WT].</span>",
|
||||
"<span class='italics'>You hear welding.</span>")
|
||||
var/turf/T = get_turf(src)
|
||||
new material_drop(T)
|
||||
qdel(src)
|
||||
else
|
||||
opened = !opened
|
||||
update_icon()
|
||||
|
||||
|
||||
/obj/structure/extinguisher_cabinet/attack_hand(mob/user)
|
||||
if(isrobot(user) || isalien(user))
|
||||
to_chat(user, "<span class='notice'>You don't have the dexterity to do this!</span>")
|
||||
return
|
||||
if(ishuman(user))
|
||||
var/mob/living/carbon/human/H = user
|
||||
@@ -70,3 +111,11 @@
|
||||
icon_state = "extinguisher_full"
|
||||
else
|
||||
icon_state = "extinguisher_empty"
|
||||
|
||||
/obj/structure/extinguisher_cabinet/empty/New(turf/loc, ndir = null)
|
||||
extinguishertype = NO_EXTINGUISHER
|
||||
..()
|
||||
|
||||
#undef NO_EXTINGUISHER
|
||||
#undef NORMAL_EXTINGUISHER
|
||||
#undef MINI_EXTINGUISHER
|
||||
|
||||
@@ -82,7 +82,7 @@
|
||||
if(density)
|
||||
icon_state = initial(icon_state)
|
||||
smooth = SMOOTH_TRUE
|
||||
smooth_icon(src)
|
||||
queue_smooth(src)
|
||||
else
|
||||
icon_state = "fwall_open"
|
||||
|
||||
@@ -322,4 +322,4 @@
|
||||
mineral = /obj/item/stack/sheet/mineral/plastitanium
|
||||
walltype = /turf/simulated/wall/mineral/plastitanium
|
||||
smooth = SMOOTH_MORE
|
||||
canSmoothWith = list(/turf/simulated/wall/mineral/plastitanium, /obj/machinery/door/airlock/shuttle, /obj/machinery/door/airlock, /obj/structure/window/full/shuttle, /obj/structure/shuttle/engine/heater)
|
||||
canSmoothWith = list(/turf/simulated/wall/mineral/plastitanium, /obj/machinery/door/airlock/shuttle, /obj/machinery/door/airlock, /obj/structure/window/full/shuttle, /obj/structure/shuttle/engine/heater)
|
||||
|
||||
@@ -211,6 +211,7 @@
|
||||
layer = 5
|
||||
w_class = WEIGHT_CLASS_HUGE
|
||||
force = 10
|
||||
force_wielded = 10
|
||||
throwforce = 13
|
||||
throw_speed = 2
|
||||
throw_range = 4
|
||||
@@ -222,9 +223,10 @@
|
||||
icon_state = "plant-36"
|
||||
|
||||
/obj/item/twohanded/required/kirbyplants/equipped(mob/living/user)
|
||||
. = ..()
|
||||
var/image/I = image(icon = 'icons/obj/flora/plants.dmi' , icon_state = src.icon_state, loc = user)
|
||||
I.override = 1
|
||||
user.add_alt_appearance("sneaking_mission", I, player_list)
|
||||
user.add_alt_appearance("sneaking_mission", I, GLOB.player_list)
|
||||
|
||||
/obj/item/twohanded/required/kirbyplants/dropped(mob/living/user)
|
||||
..()
|
||||
|
||||
@@ -17,6 +17,8 @@
|
||||
var/rods_broken = 1
|
||||
var/grille_type
|
||||
var/broken_type = /obj/structure/grille/broken
|
||||
var/shockcooldown = 0
|
||||
var/my_shockcooldown = 1 SECONDS
|
||||
|
||||
/obj/structure/grille/fence/
|
||||
var/width = 3
|
||||
@@ -67,7 +69,10 @@
|
||||
|
||||
/obj/structure/grille/Bumped(atom/user)
|
||||
if(ismob(user))
|
||||
if(!(shockcooldown <= world.time))
|
||||
return
|
||||
shock(user, 70)
|
||||
shockcooldown = world.time + my_shockcooldown
|
||||
|
||||
/obj/structure/grille/hulk_damage()
|
||||
return 60
|
||||
@@ -249,9 +254,7 @@
|
||||
var/obj/structure/cable/C = T.get_cable_node()
|
||||
if(C)
|
||||
if(electrocute_mob(user, C, src))
|
||||
var/datum/effect_system/spark_spread/s = new /datum/effect_system/spark_spread
|
||||
s.set_up(3, 1, src)
|
||||
s.start()
|
||||
do_sparks(3, 1, src)
|
||||
return 1
|
||||
else
|
||||
return 0
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
icon_state = "cart"
|
||||
anchored = 0
|
||||
density = 1
|
||||
flags = OPENCONTAINER
|
||||
container_type = OPENCONTAINER
|
||||
//copypaste sorry
|
||||
var/amount_per_transfer_from_this = 5 //shit I dunno, adding this so syringes stop runtime erroring. --NeoFite
|
||||
var/obj/item/storage/bag/trash/mybag = null
|
||||
@@ -21,10 +21,10 @@
|
||||
/obj/structure/janitorialcart/New()
|
||||
..()
|
||||
create_reagents(100)
|
||||
janitorial_equipment += src
|
||||
GLOB.janitorial_equipment += src
|
||||
|
||||
/obj/structure/janitorialcart/Destroy()
|
||||
janitorial_equipment -= src
|
||||
GLOB.janitorial_equipment -= src
|
||||
QDEL_NULL(mybag)
|
||||
QDEL_NULL(mymop)
|
||||
QDEL_NULL(myspray)
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
|
||||
|
||||
/obj/structure/kitchenspike
|
||||
name = "a meat spike"
|
||||
name = "meat spike"
|
||||
icon = 'icons/obj/kitchen.dmi'
|
||||
icon_state = "spike"
|
||||
desc = "A spike for collecting meat from animals."
|
||||
|
||||
@@ -69,10 +69,7 @@
|
||||
if(src.destroyed)
|
||||
return
|
||||
else
|
||||
to_chat(usr, text("<span class='notice'>You kick the lab cage.</span>"))
|
||||
for(var/mob/O in oviewers())
|
||||
if((O.client && !( O.blinded )))
|
||||
to_chat(O, text("<span class='warning'>[] kicks the lab cage.</span>", usr))
|
||||
user.visible_message("<span class='warning'>[user] kicks the lab cage.</span>", "<span class='notice'>You kick the lab cage.</span>")
|
||||
src.health -= 2
|
||||
healthcheck()
|
||||
return
|
||||
@@ -82,4 +79,4 @@
|
||||
new /obj/item/clothing/mask/facehugger/lamarr(src.loc)
|
||||
occupied = 0
|
||||
update_icon()
|
||||
return
|
||||
return
|
||||
|
||||
@@ -4,20 +4,20 @@
|
||||
icon = 'icons/obj/janitor.dmi'
|
||||
icon_state = "mopbucket"
|
||||
density = 1
|
||||
flags = OPENCONTAINER
|
||||
container_type = OPENCONTAINER
|
||||
var/amount_per_transfer_from_this = 5 //shit I dunno, adding this so syringes stop runtime erroring. --NeoFite
|
||||
|
||||
/obj/structure/mopbucket/New()
|
||||
..()
|
||||
create_reagents(100)
|
||||
janitorial_equipment += src
|
||||
GLOB.janitorial_equipment += src
|
||||
|
||||
/obj/structure/mopbucket/full/New()
|
||||
..()
|
||||
reagents.add_reagent("water", 100)
|
||||
|
||||
/obj/structure/mopbucket/Destroy()
|
||||
janitorial_equipment -= src
|
||||
GLOB.janitorial_equipment -= src
|
||||
return ..()
|
||||
|
||||
/obj/structure/mopbucket/examine(mob/user)
|
||||
|
||||
@@ -207,9 +207,7 @@
|
||||
return
|
||||
O.forceMove(loc)
|
||||
if(user != O)
|
||||
for(var/mob/B in viewers(user, 3))
|
||||
if((B.client && !( B.blinded )))
|
||||
to_chat(B, text("<span class='warning'>[] stuffs [] into []!</span>", user, O, src))
|
||||
user.visible_message("<span class='warning'>[user] stuffs [O] into [src]!</span>")
|
||||
return
|
||||
|
||||
/obj/structure/m_tray/Destroy()
|
||||
@@ -440,9 +438,7 @@
|
||||
return
|
||||
O.forceMove(loc)
|
||||
if(user != O)
|
||||
for(var/mob/B in viewers(user, 3))
|
||||
if((B.client && !( B.blinded )))
|
||||
to_chat(B, text("<span class='warning'>[] stuffs [] into []!</span>", user, O, src))
|
||||
user.visible_message("<span class='warning'>[user] stuffs [O] into [src]!</span>")
|
||||
//Foreach goto(99)
|
||||
return
|
||||
|
||||
|
||||
@@ -65,8 +65,8 @@
|
||||
if(istype(A) && A.checkpass(PASSGLASS))
|
||||
return prob(60)
|
||||
|
||||
var/obj/structure/stool/bed/B = A
|
||||
if(istype(A, /obj/structure/stool/bed) && B.buckled_mob)//if it's a bed/chair and someone is buckled, it will not pass
|
||||
var/obj/structure/bed/B = A
|
||||
if(istype(A, /obj/structure/bed) && B.buckled_mob)//if it's a bed/chair and someone is buckled, it will not pass
|
||||
return 0
|
||||
|
||||
if(istype(A, /obj/structure/closet/cardboard))
|
||||
@@ -133,4 +133,4 @@
|
||||
return ..()
|
||||
|
||||
/obj/structure/plasticflaps/mining/CanAtmosPass(turf/T)
|
||||
return 0
|
||||
return 0
|
||||
|
||||
@@ -6,29 +6,44 @@ FLOOR SAFES
|
||||
|
||||
//SAFES
|
||||
/obj/structure/safe
|
||||
name = "safe"
|
||||
name = "\improper Safe"
|
||||
desc = "A huge chunk of metal with a dial embedded in it. Fine print on the dial reads \"Scarborough Arms - 2 tumbler safe, guaranteed thermite resistant, explosion resistant, and assistant resistant.\""
|
||||
icon = 'icons/obj/structures.dmi'
|
||||
icon_state = "safe"
|
||||
anchored = 1
|
||||
density = 1
|
||||
var/open = 0 //is the safe open?
|
||||
var/open = FALSE //is the safe open?
|
||||
var/unlocked = FALSE
|
||||
var/tumbler_1_pos //the tumbler position- from 0 to 72
|
||||
var/tumbler_1_open //the tumbler position to open at- 0 to 72
|
||||
var/tumbler_2_pos
|
||||
var/tumbler_2_open
|
||||
var/open_pos
|
||||
var/dial = 0 //where is the dial pointing?
|
||||
var/space = 0 //the combined w_class of everything in the safe
|
||||
var/maxspace = 24 //the maximum combined w_class of stuff in the safe
|
||||
var/combo_to_open //so admins know the code
|
||||
|
||||
|
||||
/obj/structure/safe/New()
|
||||
tumbler_1_pos = rand(0, 71)
|
||||
tumbler_1_open = rand(0, 71)
|
||||
tumbler_2_pos = rand(0, 99) // first value in the combination set first
|
||||
tumbler_2_open = rand(0, 99)
|
||||
|
||||
tumbler_2_pos = rand(0, 71)
|
||||
tumbler_2_open = rand(0, 71)
|
||||
tumbler_1_pos = rand(0, 99)
|
||||
do
|
||||
tumbler_1_open = rand(0, 99)
|
||||
while(tumbler_1_open > Wrap(tumbler_2_open +48, 0, 100) && tumbler_1_open < Wrap(tumbler_2_open + 53, 0, 100)) // prevents a combination that wont open
|
||||
do
|
||||
open_pos = rand(0,99)
|
||||
while(open_pos > Wrap(tumbler_1_open - 2, 0, 100) && open_pos < Wrap(tumbler_1_open + 2, 0, 100)) // prevents a combination that wont open
|
||||
var/num1 = tumbler_2_open + 54
|
||||
if(num1 > 99)
|
||||
num1 = num1 - 100
|
||||
var/num2 = tumbler_1_open + 98
|
||||
if(num2 > 99)
|
||||
num2 = num2 - 100
|
||||
|
||||
combo_to_open = "Go right past [num1] twice then stop at [num1]. Go left past [num2] once then stop at [num2]. Turn right till it stops and its open."
|
||||
|
||||
/obj/structure/safe/Initialize()
|
||||
..()
|
||||
@@ -40,31 +55,28 @@ FLOOR SAFES
|
||||
I.loc = src
|
||||
|
||||
|
||||
/obj/structure/safe/proc/check_unlocked(mob/user, canhear)
|
||||
/obj/structure/safe/proc/check_unlocked()
|
||||
if(tumbler_1_pos == tumbler_1_open && tumbler_2_pos == tumbler_2_open && dial == open_pos)
|
||||
unlocked = TRUE
|
||||
return TRUE
|
||||
unlocked = FALSE
|
||||
return FALSE
|
||||
|
||||
/obj/structure/safe/proc/make_noise(turns, turns_total, tum1 = 0, tum2 = 0, mob/user, canhear)
|
||||
if(user && canhear)
|
||||
if(tumbler_1_pos == tumbler_1_open)
|
||||
if(turns == 2)
|
||||
to_chat(user, "<span class='italics'>The sounds from [src] are too fast and blend together.</span>")
|
||||
if(tum1 && (turns_total == 1 || prob(10))) // So multi turns dont super spam the chat
|
||||
to_chat(user, "<span class='italics'>You hear a [pick("clack", "scrape", "clank")] from [src].</span>")
|
||||
if(tum2 && (turns_total == 1 || prob(10))) // So multi turns dont super spam the chat
|
||||
to_chat(user, "<span class='italics'>You hear a [pick("click", "chink", "clink")] from [src].</span>")
|
||||
if(tumbler_1_pos == tumbler_1_open && turns_total == 1) // You cant hear tumblers if you spin fast!
|
||||
to_chat(user, "<span class='italics'>You hear a [pick("tonk", "krunk", "plunk")] from [src].</span>")
|
||||
if(tumbler_2_pos == tumbler_2_open)
|
||||
if(tumbler_2_pos == tumbler_2_open && turns_total == 1 ) // You cant hear tumblers if you spin fast!
|
||||
to_chat(user, "<span class='italics'>You hear a [pick("tink", "krink", "plink")] from [src].</span>")
|
||||
if(tumbler_1_pos == tumbler_1_open && tumbler_2_pos == tumbler_2_open)
|
||||
if(user) visible_message("<i><b>[pick("Spring", "Sprang", "Sproing", "Clunk", "Krunk")]!</b></i>")
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
/obj/structure/safe/proc/decrement(num)
|
||||
num -= 1
|
||||
if(num < 0)
|
||||
num = 71
|
||||
return num
|
||||
|
||||
|
||||
/obj/structure/safe/proc/increment(num)
|
||||
num += 1
|
||||
if(num > 71)
|
||||
num = 0
|
||||
return num
|
||||
|
||||
if(unlocked)
|
||||
if(user)
|
||||
visible_message("<i><b>[pick("Spring", "Sprang", "Sproing", "Clunk", "Krunk")]!</b></i>")
|
||||
|
||||
/obj/structure/safe/update_icon()
|
||||
if(open)
|
||||
@@ -72,75 +84,112 @@ FLOOR SAFES
|
||||
else
|
||||
icon_state = initial(icon_state)
|
||||
|
||||
|
||||
/obj/structure/safe/attack_hand(mob/user)
|
||||
user.set_machine(src)
|
||||
var/dat = "<center>"
|
||||
dat += "<a href='?src=[UID()];open=1'>[open ? "Close" : "Open"] [src]</a> | <a href='?src=[UID()];decrement=1'>-</a> [dial * 5] <a href='?src=[UID()];increment=1'>+</a>"
|
||||
if(..())
|
||||
return TRUE
|
||||
ui_interact(user)
|
||||
return
|
||||
|
||||
/obj/structure/safe/ui_interact(mob/user, ui_key = "main", datum/nanoui/ui = null, force_open = 1)
|
||||
ui = SSnanoui.try_update_ui(user, src, ui_key, ui, force_open)
|
||||
if(!ui)
|
||||
ui = new(user, src, ui_key, "safe.tmpl", name, 600, 750)
|
||||
ui.open()
|
||||
ui.set_auto_update(1)
|
||||
|
||||
/obj/structure/safe/ui_data(mob/user, ui_key = "main", datum/topic_state/state = default_state)
|
||||
var/data[0]
|
||||
var/list/contents_names = list()
|
||||
if(open)
|
||||
dat += "<table>"
|
||||
for(var/i = contents.len, i>=1, i--)
|
||||
var/obj/item/P = contents[i]
|
||||
dat += "<tr><td><a href='?src=[UID()];retrieve=\ref[P]'>[P.name]</a></td></tr>"
|
||||
dat += "</table></center>"
|
||||
user << browse("<html><head><title>[name]</title></head><body>[dat]</body></html>", "window=safe;size=350x300")
|
||||
for(var/obj/O in contents)
|
||||
contents_names[++contents_names.len] = list("name" = O.name, "index" = contents.Find(O), "sprite" = O.icon_state)
|
||||
user << browse_rsc(icon(O.icon, O.icon_state), "[O.icon_state].png")
|
||||
else
|
||||
contents_names = list(list("name" = "you're"), list("name" = "a"), list("name" = "cheater"))
|
||||
|
||||
data["dial"] = dial
|
||||
data["open"] = open
|
||||
data["unlocked"] = unlocked
|
||||
data["rotation"] = "[-dial*3.6]deg"
|
||||
data["contents"] = contents_names
|
||||
|
||||
return data
|
||||
|
||||
|
||||
/obj/structure/safe/Topic(href, href_list)
|
||||
if(!ishuman(usr)) return
|
||||
var/mob/living/carbon/human/user = usr
|
||||
if(..())
|
||||
return TRUE
|
||||
|
||||
var/canhear = 0
|
||||
if(!ishuman(usr))
|
||||
to_chat(usr, "You don't have hands to operate the safe!")
|
||||
return FALSE
|
||||
|
||||
var/mob/living/carbon/human/user = usr
|
||||
if(istype(user.l_hand, /obj/item/clothing/accessory/stethoscope) || istype(user.r_hand, /obj/item/clothing/accessory/stethoscope))
|
||||
canhear = 1
|
||||
|
||||
if(href_list["open"])
|
||||
if(check_unlocked())
|
||||
if(check_unlocked() || open)
|
||||
to_chat(user, "<span class='notice'>You [open ? "close" : "open"] [src].</span>")
|
||||
open = !open
|
||||
update_icon()
|
||||
updateUsrDialog()
|
||||
return
|
||||
else
|
||||
to_chat(user, "<span class='warning'>You can't [open ? "close" : "open"] [src], the lock is engaged!</span>")
|
||||
return
|
||||
to_chat(user, "<span class='warning'>You can't open [src], the lock is engaged!</span>")
|
||||
.= TRUE
|
||||
SSnanoui.update_uis(src)
|
||||
|
||||
if(href_list["decrement"])
|
||||
dial = decrement(dial)
|
||||
if(dial == tumbler_1_pos + 1 || dial == tumbler_1_pos - 71)
|
||||
tumbler_1_pos = decrement(tumbler_1_pos)
|
||||
if(canhear)
|
||||
to_chat(user, "<span class='italics'>You hear a [pick("clack", "scrape", "clank")] from [src].</span>")
|
||||
if(tumbler_1_pos == tumbler_2_pos + 37 || tumbler_1_pos == tumbler_2_pos - 35)
|
||||
tumbler_2_pos = decrement(tumbler_2_pos)
|
||||
if(canhear)
|
||||
to_chat(user, "<span class='italics'>You hear a [pick("click", "chink", "clink")] from [src].</span>")
|
||||
check_unlocked(user, canhear)
|
||||
updateUsrDialog()
|
||||
return
|
||||
var/ticks = text2num(href_list["decrement"])
|
||||
if(open)
|
||||
return
|
||||
for(var/i=1 to ticks)
|
||||
if(!check_unlocked())
|
||||
dial = Wrap(dial - 1, 0 ,100)
|
||||
if(dial == tumbler_1_pos + 1 || dial == tumbler_1_pos - 99)
|
||||
tumbler_1_pos = Wrap(tumbler_1_pos - 1, 0, 100)
|
||||
make_noise(i, ticks, 1, 0, user, canhear)
|
||||
if(tumbler_1_pos == tumbler_2_pos + 51 || tumbler_1_pos == tumbler_2_pos - 49)
|
||||
tumbler_2_pos = Wrap(tumbler_2_pos - 1, 0, 100)
|
||||
make_noise(0, ticks, 0, 1, user, canhear)
|
||||
sleep(1)
|
||||
check_unlocked()
|
||||
SSnanoui.update_uis(src)
|
||||
make_noise(0, 0, 0, 0, user, canhear)
|
||||
.= TRUE
|
||||
|
||||
if(href_list["increment"])
|
||||
dial = increment(dial)
|
||||
if(dial == tumbler_1_pos - 1 || dial == tumbler_1_pos + 71)
|
||||
tumbler_1_pos = increment(tumbler_1_pos)
|
||||
if(canhear)
|
||||
to_chat(user, "<span class='italics'>You hear a [pick("clack", "scrape", "clank")] from [src].</span>")
|
||||
if(tumbler_1_pos == tumbler_2_pos - 37 || tumbler_1_pos == tumbler_2_pos + 35)
|
||||
tumbler_2_pos = increment(tumbler_2_pos)
|
||||
if(canhear)
|
||||
to_chat(user, "<span class='italics'>You hear a [pick("click", "chink", "clink")] from [src].</span>")
|
||||
check_unlocked(user, canhear)
|
||||
updateUsrDialog()
|
||||
return
|
||||
var/ticks = text2num(href_list["increment"])
|
||||
if(open)
|
||||
return
|
||||
for(var/i=1 to ticks)
|
||||
check_unlocked()
|
||||
dial = Wrap(dial + 1, 0, 100)
|
||||
if(dial == tumbler_1_pos - 1 || dial == tumbler_1_pos + 99)
|
||||
tumbler_1_pos = Wrap(tumbler_1_pos + 1, 0, 100)
|
||||
make_noise(i, ticks, 1, 0, user, canhear)
|
||||
if(tumbler_1_pos == tumbler_2_pos - 51 || tumbler_1_pos == tumbler_2_pos + 49)
|
||||
tumbler_2_pos = Wrap(tumbler_2_pos + 1, 0, 100)
|
||||
make_noise(0, ticks, 0, 1, user, canhear)
|
||||
sleep(1)
|
||||
SSnanoui.update_uis(src)
|
||||
make_noise(0, 0, 0, 0, user, canhear)
|
||||
.= TRUE
|
||||
|
||||
if(href_list["retrieve"])
|
||||
user << browse("", "window=safe") // Close the menu
|
||||
var/index = text2num(href_list["retrieve"])
|
||||
if(index > 0 && index <= contents.len)
|
||||
var/obj/item/P = contents[index]
|
||||
if(open)
|
||||
if(P && in_range(src, user))
|
||||
user.put_in_hands(P)
|
||||
space -= P.w_class
|
||||
SSnanoui.update_uis(src)
|
||||
.= TRUE
|
||||
|
||||
var/obj/item/P = locate(href_list["retrieve"]) in src
|
||||
if(open)
|
||||
if(P && in_range(src, user))
|
||||
user.put_in_hands(P)
|
||||
updateUsrDialog()
|
||||
|
||||
updateUsrDialog()
|
||||
return
|
||||
|
||||
|
||||
/obj/structure/safe/attackby(obj/item/I, mob/user, params)
|
||||
@@ -161,14 +210,19 @@ FLOOR SAFES
|
||||
if(istype(I, /obj/item/clothing/accessory/stethoscope))
|
||||
to_chat(user, "<span class='warning'>Hold [I] in one of your hands while you manipulate the dial!</span>")
|
||||
return
|
||||
else
|
||||
to_chat(user, "<span class='warning'>You can't put [I] in into the safe while it is closed!</span>")
|
||||
return
|
||||
|
||||
|
||||
obj/structure/safe/blob_act()
|
||||
/obj/structure/safe/blob_act()
|
||||
return
|
||||
|
||||
obj/structure/safe/ex_act(severity)
|
||||
/obj/structure/safe/ex_act(severity)
|
||||
return
|
||||
|
||||
/obj/structure/safe/examine_status(mob/user)
|
||||
return
|
||||
|
||||
//FLOOR SAFES
|
||||
/obj/structure/safe/floor
|
||||
|
||||
@@ -174,6 +174,8 @@
|
||||
|
||||
/obj/structure/statue/plasma/bullet_act(obj/item/projectile/Proj)
|
||||
var/burn = FALSE
|
||||
if(Proj.damage == 0)//lasertag guns and so on don't set off plasma anymore. can't use nodamage here because lasertag guns actually don't have it.
|
||||
return
|
||||
if(istype(Proj,/obj/item/projectile/beam))
|
||||
PlasmaBurn(2500)
|
||||
burn = TRUE
|
||||
@@ -182,17 +184,17 @@
|
||||
burn = TRUE
|
||||
if(burn)
|
||||
if(Proj.firer)
|
||||
message_admins("Plasma statue ignited by [key_name_admin(Proj.firer)](<A HREF='?_src_=holder;adminmoreinfo=\ref[Proj.firer]'>?</A>) (<A HREF='?_src_=holder;adminplayerobservefollow=\ref[Proj.firer]'>FLW</A>) in ([x],[y],[z] - <A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[x];Y=[y];Z=[z]'>JMP</a>)",0,1)
|
||||
message_admins("Plasma statue ignited by [key_name_admin(Proj.firer)]([ADMIN_QUE(Proj.firer,"?")]) ([ADMIN_FLW(Proj.firer,"FLW")]) in ([x],[y],[z] - <A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[x];Y=[y];Z=[z]'>JMP</a>)",0,1)
|
||||
log_game("Plasma statue ignited by [key_name(Proj.firer)] in ([x],[y],[z])")
|
||||
investigate_log("was <font color='red'><b>ignited</b></font> by [key_name(Proj.firer)]","atmos")
|
||||
else
|
||||
message_admins("Plasma statue ignited by [Proj]. No known firer.(<A HREF='?_src_=holder;adminmoreinfo=\ref[Proj.firer]'>?</A>) (<A HREF='?_src_=holder;adminplayerobservefollow=\ref[Proj.firer]'>FLW</A>) in ([x],[y],[z] - <A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[x];Y=[y];Z=[z]'>JMP</a>)",0,1)
|
||||
message_admins("Plasma statue ignited by [Proj]. No known firer.([ADMIN_QUE(Proj.firer,"?")]) ([ADMIN_FLW(Proj.firer,"FLW")]) in ([x],[y],[z] - <A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[x];Y=[y];Z=[z]'>JMP</a>)",0,1)
|
||||
log_game("Plasma statue ignited by [Proj] in ([x],[y],[z]). No known firer.")
|
||||
..()
|
||||
|
||||
/obj/structure/statue/plasma/attackby(obj/item/W, mob/user, params)
|
||||
if(is_hot(W) > 300)//If the temperature of the object is over 300, then ignite
|
||||
message_admins("Plasma statue ignited by [key_name_admin(user)](<A HREF='?_src_=holder;adminmoreinfo=\ref[user]'>?</A>) (<A HREF='?_src_=holder;adminplayerobservefollow=\ref[user]'>FLW</A>) in ([x],[y],[z] - <A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[x];Y=[y];Z=[z]'>JMP</a>)",0,1)
|
||||
message_admins("Plasma statue ignited by [key_name_admin(user)]([ADMIN_QUE(user,"?")]) ([ADMIN_FLW(user,"FLW")]) in ([x],[y],[z] - <A HREF='?_src_=holder;adminplayerobservecoodjump=1;X=[x];Y=[y];Z=[z]'>JMP</a>)",0,1)
|
||||
log_game("Plasma statue ignited by [key_name(user)] in ([x],[y],[z])")
|
||||
investigate_log("was <font color='red'><b>ignited</b></font> by [key_name(user)]","atmos")
|
||||
ignite(is_hot(W))
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
//Alium nests. Essentially beds with an unbuckle delay that only aliums can buckle mobs to.
|
||||
|
||||
/obj/structure/stool/bed/nest
|
||||
/obj/structure/bed/nest
|
||||
name = "alien nest"
|
||||
desc = "It's a gruesome pile of thick, sticky resin shaped like a nest."
|
||||
icon = 'icons/mob/alien.dmi'
|
||||
@@ -9,11 +9,11 @@
|
||||
var/image/nest_overlay
|
||||
comfort = 0
|
||||
|
||||
/obj/structure/stool/bed/nest/New()
|
||||
/obj/structure/bed/nest/New()
|
||||
nest_overlay = image('icons/mob/alien.dmi', "nestoverlay", layer=MOB_LAYER - 0.2)
|
||||
return ..()
|
||||
|
||||
/obj/structure/stool/bed/nest/user_unbuckle_mob(mob/living/user)
|
||||
/obj/structure/bed/nest/user_unbuckle_mob(mob/living/user)
|
||||
if(buckled_mob && buckled_mob.buckled == src)
|
||||
var/mob/living/M = buckled_mob
|
||||
|
||||
@@ -47,7 +47,7 @@
|
||||
add_fingerprint(user)
|
||||
|
||||
|
||||
/obj/structure/stool/bed/nest/user_buckle_mob(mob/living/M, mob/living/user)
|
||||
/obj/structure/bed/nest/user_buckle_mob(mob/living/M, mob/living/user)
|
||||
if( !ismob(M) || (get_dist(src, user) > 1) || (M.loc != src.loc) || user.restrained() || usr.stat || M.buckled || istype(user, /mob/living/silicon/pai) )
|
||||
return
|
||||
|
||||
@@ -65,7 +65,7 @@
|
||||
"<span class='italics'>You hear squelching...</span>")
|
||||
|
||||
|
||||
/obj/structure/stool/bed/nest/post_buckle_mob(mob/living/M)
|
||||
/obj/structure/bed/nest/post_buckle_mob(mob/living/M)
|
||||
if(M == buckled_mob)
|
||||
M.pixel_y = 0
|
||||
M.pixel_x = initial(M.pixel_x) + 2
|
||||
@@ -77,7 +77,7 @@
|
||||
M.layer = initial(M.layer)
|
||||
overlays -= nest_overlay
|
||||
|
||||
/obj/structure/stool/bed/nest/attackby(obj/item/W as obj, mob/user as mob, params)
|
||||
/obj/structure/bed/nest/attackby(obj/item/W as obj, mob/user as mob, params)
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
var/aforce = W.force
|
||||
health = max(0, health - aforce)
|
||||
@@ -85,8 +85,7 @@
|
||||
visible_message("<span class='warning'>[user] hits [src] with [W]!</span>", 1)
|
||||
healthcheck()
|
||||
|
||||
/obj/structure/stool/bed/nest/proc/healthcheck()
|
||||
if(health <=0)
|
||||
density = 0
|
||||
/obj/structure/bed/nest/proc/healthcheck()
|
||||
if(health <= 0)
|
||||
density = FALSE
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
@@ -2,59 +2,52 @@
|
||||
* Contains:
|
||||
* Beds
|
||||
* Roller beds
|
||||
* Dog Beds
|
||||
*/
|
||||
|
||||
/*
|
||||
* Beds
|
||||
*/
|
||||
/obj/structure/stool/bed
|
||||
|
||||
/obj/structure/bed
|
||||
name = "bed"
|
||||
desc = "This is used to lie in, sleep in or strap on."
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "bed"
|
||||
can_buckle = 1
|
||||
buckle_lying = 1
|
||||
can_buckle = TRUE
|
||||
anchored = TRUE
|
||||
buckle_lying = TRUE
|
||||
burn_state = FLAMMABLE
|
||||
burntime = 30
|
||||
buildstackamount = 2
|
||||
var/movable = 0 // For mobility checks
|
||||
var/buildstacktype = /obj/item/stack/sheet/metal
|
||||
var/buildstackamount = 2
|
||||
buckle_offset = -6
|
||||
var/comfort = 2 //defualt comfort
|
||||
var/comfort = 2 // default comfort
|
||||
|
||||
/obj/structure/stool/bed/MouseDrop(atom/over_object)
|
||||
..(over_object, skip_fucking_stool_shit = 1)
|
||||
|
||||
/obj/structure/stool/psychbed
|
||||
/obj/structure/bed/psych
|
||||
name = "psych bed"
|
||||
desc = "For prime comfort during psychiatric evaluations."
|
||||
icon_state = "psychbed"
|
||||
buildstackamount = 5
|
||||
can_buckle = 1
|
||||
buckle_lying = 1
|
||||
can_buckle = TRUE
|
||||
buckle_lying = TRUE
|
||||
|
||||
/obj/structure/stool/bed/dogbed
|
||||
name = "dog bed"
|
||||
icon_state = "dogbed"
|
||||
desc = "A comfy-looking dog bed. You can even strap your pet in, in case the gravity turns off."
|
||||
anchored = 0
|
||||
buildstackamount = 10
|
||||
buildstacktype = /obj/item/stack/sheet/wood
|
||||
buckle_offset = 0
|
||||
comfort = 0.5
|
||||
|
||||
/obj/structure/stool/bed/dogbed/ian
|
||||
name = "Ian's bed"
|
||||
desc = "Ian's bed! Looks comfy."
|
||||
anchored = 1
|
||||
|
||||
/obj/structure/stool/bed/alien
|
||||
/obj/structure/bed/alien
|
||||
name = "resting contraption"
|
||||
desc = "This looks similar to contraptions from Earth. Could aliens be stealing our technology?"
|
||||
icon_state = "abed"
|
||||
comfort = 0.3
|
||||
/obj/structure/stool/bed/proc/handle_rotation()
|
||||
|
||||
/obj/structure/bed/proc/handle_rotation()
|
||||
return
|
||||
|
||||
/obj/structure/stool/bed/attack_animal(mob/living/simple_animal/user)
|
||||
/obj/structure/bed/attackby(obj/item/W as obj, mob/user as mob, params)
|
||||
if(istype(W, /obj/item/wrench))
|
||||
playsound(loc, W.usesound, 50, 1)
|
||||
new buildstacktype(loc, buildstackamount)
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/bed/attack_animal(mob/living/simple_animal/user)
|
||||
if(user.environment_smash)
|
||||
user.do_attack_animation(src)
|
||||
visible_message("<span class='danger'>[user] smashes [src] apart!</span>")
|
||||
@@ -64,15 +57,16 @@
|
||||
/*
|
||||
* Roller beds
|
||||
*/
|
||||
/obj/structure/stool/bed/roller
|
||||
|
||||
/obj/structure/bed/roller
|
||||
name = "roller bed"
|
||||
icon = 'icons/obj/rollerbed.dmi'
|
||||
icon_state = "down"
|
||||
burn_state = FIRE_PROOF
|
||||
anchored = 0
|
||||
anchored = FALSE
|
||||
comfort = 1
|
||||
|
||||
/obj/structure/stool/bed/roller/attackby(obj/item/W as obj, mob/user as mob, params)
|
||||
/obj/structure/bed/roller/attackby(obj/item/W as obj, mob/user as mob, params)
|
||||
if(istype(W, /obj/item/roller_holder))
|
||||
if(buckled_mob)
|
||||
user_unbuckle_mob(user)
|
||||
@@ -80,15 +74,14 @@
|
||||
user.visible_message("<span class='notice'>[user] collapses \the [name].</span>", "<span class='notice'>You collapse \the [name].</span>")
|
||||
new/obj/item/roller(get_turf(src))
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
/obj/structure/stool/bed/roller/post_buckle_mob(mob/living/M)
|
||||
/obj/structure/bed/roller/post_buckle_mob(mob/living/M)
|
||||
if(M == buckled_mob)
|
||||
density = 1
|
||||
density = TRUE
|
||||
icon_state = "up"
|
||||
M.pixel_y = initial(M.pixel_y)
|
||||
else
|
||||
density = 0
|
||||
density = FALSE
|
||||
icon_state = "down"
|
||||
M.pixel_x = M.get_standard_pixel_x_offset(M.lying)
|
||||
M.pixel_y = M.get_standard_pixel_y_offset(M.lying)
|
||||
@@ -101,7 +94,7 @@
|
||||
w_class = WEIGHT_CLASS_BULKY // Can't be put in backpacks.
|
||||
|
||||
/obj/item/roller/attack_self(mob/user)
|
||||
var/obj/structure/stool/bed/roller/R = new /obj/structure/stool/bed/roller(user.loc)
|
||||
var/obj/structure/bed/roller/R = new /obj/structure/bed/roller(user.loc)
|
||||
R.add_fingerprint(user)
|
||||
qdel(src)
|
||||
|
||||
@@ -113,7 +106,7 @@
|
||||
forceMove(RH)
|
||||
RH.held = src
|
||||
|
||||
/obj/structure/stool/bed/roller/MouseDrop(over_object, src_location, over_location)
|
||||
/obj/structure/bed/roller/MouseDrop(over_object, src_location, over_location)
|
||||
..()
|
||||
if(over_object == usr && Adjacent(usr) && (in_range(src, usr) || usr.contents.Find(src)))
|
||||
if(!ishuman(usr))
|
||||
@@ -123,7 +116,6 @@
|
||||
usr.visible_message("<span class='notice'>[usr] collapses \the [name].</span>", "<span class='notice'>You collapse \the [name].</span>")
|
||||
new/obj/item/roller(get_turf(src))
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
/obj/item/roller_holder
|
||||
name = "roller bed rack"
|
||||
@@ -139,9 +131,37 @@
|
||||
/obj/item/roller_holder/attack_self(mob/user as mob)
|
||||
if(!held)
|
||||
to_chat(user, "<span class='info'> The rack is empty.</span>")
|
||||
return
|
||||
|
||||
to_chat(user, "<span class='notice'>You deploy the roller bed.</span>")
|
||||
var/obj/structure/stool/bed/roller/R = new /obj/structure/stool/bed/roller(user.loc)
|
||||
var/obj/structure/bed/roller/R = new /obj/structure/bed/roller(user.loc)
|
||||
R.add_fingerprint(user)
|
||||
QDEL_NULL(held)
|
||||
|
||||
/*
|
||||
* Dog beds
|
||||
*/
|
||||
|
||||
/obj/structure/bed/dogbed
|
||||
name = "dog bed"
|
||||
icon_state = "dogbed"
|
||||
desc = "A comfy-looking dog bed. You can even strap your pet in, just in case the gravity turns off."
|
||||
anchored = FALSE
|
||||
buildstackamount = 10
|
||||
buildstacktype = /obj/item/stack/sheet/wood
|
||||
buckle_offset = 0
|
||||
comfort = 0.5
|
||||
|
||||
/obj/structure/bed/dogbed/ian
|
||||
name = "Ian's bed"
|
||||
desc = "Ian's bed! Looks comfy."
|
||||
anchored = TRUE
|
||||
|
||||
/obj/structure/bed/dogbed/renault
|
||||
desc = "Renault's bed! Looks comfy. A foxy person needs a foxy pet."
|
||||
name = "Renault's bed"
|
||||
anchored = TRUE
|
||||
|
||||
/obj/structure/bed/dogbed/runtime
|
||||
desc = "A comfy-looking cat bed. You can even strap your pet in, in case the gravity turns off."
|
||||
name = "Runtime's bed"
|
||||
anchored = TRUE
|
||||
|
||||
@@ -1,62 +1,100 @@
|
||||
/obj/structure/stool/bed/chair //YES, chairs are a type of bed, which are a type of stool. This works, believe me. -Pete
|
||||
/obj/structure/chair // fuck you Pete
|
||||
name = "chair"
|
||||
desc = "You sit in this. Either by will or force."
|
||||
icon = 'icons/obj/chairs.dmi'
|
||||
icon_state = "chair"
|
||||
buckle_lying = 0 //you sit in a chair, not lay
|
||||
layer = OBJ_LAYER
|
||||
can_buckle = TRUE
|
||||
buckle_lying = FALSE // you sit in a chair, not lay
|
||||
anchored = TRUE
|
||||
burn_state = FIRE_PROOF
|
||||
buildstackamount = 1
|
||||
buckle_offset = 0
|
||||
var/propelled = 0 // Check for fire-extinguisher-driven chairs
|
||||
comfort = 0
|
||||
var/buildstacktype = /obj/item/stack/sheet/metal
|
||||
var/buildstackamount = 1
|
||||
var/item_chair = /obj/item/chair // if null it can't be picked up
|
||||
var/movable = FALSE // For mobility checks
|
||||
var/propelled = FALSE // Check for fire-extinguisher-driven chairs
|
||||
var/comfort = 0
|
||||
|
||||
/obj/structure/stool/bed/chair/New()
|
||||
/obj/structure/chair/New()
|
||||
..()
|
||||
spawn(3) //sorry. i don't think there's a better way to do this.
|
||||
handle_rotation()
|
||||
return
|
||||
|
||||
/obj/structure/stool/bed/chair/narsie_act()
|
||||
/obj/structure/chair/narsie_act()
|
||||
if(prob(20))
|
||||
var/obj/structure/stool/bed/chair/wood/W = new/obj/structure/stool/bed/chair/wood(get_turf(src))
|
||||
W.dir = dir
|
||||
var/obj/structure/chair/wood/W = new/obj/structure/chair/wood(get_turf(src))
|
||||
W.setDir(dir)
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/stool/bed/chair/Move(atom/newloc, direct)
|
||||
/obj/structure/chair/Move(atom/newloc, direct)
|
||||
..()
|
||||
handle_rotation()
|
||||
|
||||
/obj/structure/stool/bed/chair/attackby(obj/item/W as obj, mob/user as mob, params)
|
||||
..()
|
||||
/obj/structure/chair/attackby(obj/item/W as obj, mob/user as mob, params)
|
||||
if(istype(W, /obj/item/assembly/shock_kit))
|
||||
var/obj/item/assembly/shock_kit/SK = W
|
||||
if(!SK.status)
|
||||
to_chat(user, "<span class='notice'>[SK] is not ready to be attached!</span>")
|
||||
return
|
||||
user.drop_item()
|
||||
var/obj/structure/stool/bed/chair/e_chair/E = new /obj/structure/stool/bed/chair/e_chair(src.loc)
|
||||
var/obj/structure/chair/e_chair/E = new /obj/structure/chair/e_chair(src.loc)
|
||||
playsound(src.loc, W.usesound, 50, 1)
|
||||
E.dir = dir
|
||||
E.part = SK
|
||||
SK.loc = E
|
||||
SK.master = E
|
||||
qdel(src)
|
||||
if(istype(W, /obj/item/wrench))
|
||||
playsound(loc, W.usesound, 50, 1)
|
||||
new buildstacktype(loc, buildstackamount)
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/stool/bed/chair/attack_tk(mob/user as mob)
|
||||
/obj/structure/chair/MouseDrop(over_object, src_location, over_location)
|
||||
. = ..()
|
||||
if(over_object == usr && Adjacent(usr))
|
||||
if(!item_chair || has_buckled_mobs())
|
||||
return
|
||||
if(usr.incapacitated())
|
||||
to_chat(usr, "<span class='warning'>You can't do that right now!</span>")
|
||||
return
|
||||
usr.visible_message("<span class='notice'>[usr] grabs \the [src.name].</span>", "<span class='notice'>You grab \the [src.name].</span>")
|
||||
var/C = new item_chair(loc)
|
||||
usr.put_in_hands(C)
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/chair/attack_tk(mob/user as mob)
|
||||
if(buckled_mob)
|
||||
..()
|
||||
else
|
||||
rotate()
|
||||
return
|
||||
|
||||
/obj/structure/stool/bed/chair/handle_rotation() //making this into a seperate proc so office chairs can call it on Move()
|
||||
if(src.dir == NORTH)
|
||||
src.layer = FLY_LAYER
|
||||
else
|
||||
src.layer = OBJ_LAYER
|
||||
/obj/structure/chair/proc/handle_rotation(direction) //making this into a seperate proc so office chairs can call it on Move()
|
||||
handle_layer()
|
||||
if(buckled_mob)
|
||||
buckled_mob.dir = dir
|
||||
|
||||
/obj/structure/stool/bed/chair/verb/rotate()
|
||||
/obj/structure/chair/proc/handle_layer()
|
||||
if(buckled_mob && dir == NORTH)
|
||||
layer = FLY_LAYER
|
||||
else
|
||||
layer = OBJ_LAYER
|
||||
|
||||
/obj/structure/chair/post_buckle_mob(mob/living/M)
|
||||
. = ..()
|
||||
handle_layer()
|
||||
|
||||
/obj/structure/chair/post_unbuckle_mob()
|
||||
. = ..()
|
||||
handle_layer()
|
||||
|
||||
/obj/structure/chair/setDir(newdir)
|
||||
..()
|
||||
handle_rotation(newdir)
|
||||
|
||||
/obj/structure/chair/verb/rotate()
|
||||
set name = "Rotate Chair"
|
||||
set category = "Object"
|
||||
set src in oview(1)
|
||||
@@ -72,7 +110,7 @@
|
||||
setDir(turn(dir, 90))
|
||||
handle_rotation()
|
||||
|
||||
/obj/structure/stool/bed/chair/AltClick(mob/user)
|
||||
/obj/structure/chair/AltClick(mob/user)
|
||||
if(user.incapacitated())
|
||||
to_chat(user, "<span class='warning'>You can't do that right now!</span>")
|
||||
return
|
||||
@@ -81,27 +119,28 @@
|
||||
rotate()
|
||||
|
||||
// Chair types
|
||||
/obj/structure/stool/bed/chair/wood
|
||||
/obj/structure/chair/wood
|
||||
burn_state = FLAMMABLE
|
||||
burntime = 20
|
||||
buildstackamount = 3
|
||||
buildstacktype = /obj/item/stack/sheet/wood
|
||||
// TODO: Special ash subtype that looks like charred chair legs
|
||||
item_chair = /obj/item/chair/wood
|
||||
|
||||
/obj/structure/stool/bed/chair/wood/narsie_act()
|
||||
/obj/structure/chair/wood/narsie_act()
|
||||
return
|
||||
|
||||
/obj/structure/stool/bed/chair/wood/normal
|
||||
/obj/structure/chair/wood/normal
|
||||
icon_state = "wooden_chair"
|
||||
name = "wooden chair"
|
||||
desc = "Old is never too old to not be in fashion."
|
||||
|
||||
/obj/structure/stool/bed/chair/wood/wings
|
||||
/obj/structure/chair/wood/wings
|
||||
icon_state = "wooden_chair_wings"
|
||||
name = "wooden chair"
|
||||
desc = "Old is never too old to not be in fashion."
|
||||
item_chair = /obj/item/chair/wood/wings
|
||||
|
||||
/obj/structure/stool/bed/chair/comfy
|
||||
/obj/structure/chair/comfy
|
||||
name = "comfy chair"
|
||||
desc = "It looks comfy."
|
||||
icon_state = "comfychair"
|
||||
@@ -109,55 +148,69 @@
|
||||
burn_state = FLAMMABLE
|
||||
burntime = 30
|
||||
buildstackamount = 2
|
||||
item_chair = null
|
||||
var/image/armrest = null
|
||||
|
||||
/obj/structure/stool/bed/chair/comfy/New()
|
||||
armrest = image("icons/obj/objects.dmi", "comfychair_armrest")
|
||||
armrest.layer = MOB_LAYER + 0.1
|
||||
|
||||
/obj/structure/chair/comfy/New()
|
||||
armrest = image("icons/obj/chairs.dmi", "comfychair_armrest")
|
||||
armrest.layer = ABOVE_MOB_LAYER
|
||||
return ..()
|
||||
|
||||
/obj/structure/stool/bed/chair/comfy/post_buckle_mob(mob/living/M)
|
||||
/obj/structure/chair/comfy/Destroy()
|
||||
QDEL_NULL(armrest)
|
||||
return ..()
|
||||
|
||||
/obj/structure/chair/comfy/post_buckle_mob(mob/living/M)
|
||||
..()
|
||||
if(buckled_mob)
|
||||
overlays += armrest
|
||||
else
|
||||
overlays -= armrest
|
||||
|
||||
/obj/structure/stool/bed/chair/comfy/brown
|
||||
/obj/structure/chair/comfy/post_unbuckle_mob(mob/living/M)
|
||||
..()
|
||||
if(buckled_mob)
|
||||
overlays -= armrest
|
||||
else
|
||||
overlays += armrest
|
||||
|
||||
/obj/structure/chair/comfy/brown
|
||||
color = rgb(141,70,0)
|
||||
|
||||
/obj/structure/stool/bed/chair/comfy/red
|
||||
/obj/structure/chair/comfy/red
|
||||
color = rgb(218,2,10)
|
||||
|
||||
/obj/structure/stool/bed/chair/comfy/teal
|
||||
/obj/structure/chair/comfy/teal
|
||||
color = rgb(0,234,250)
|
||||
|
||||
/obj/structure/stool/bed/chair/comfy/black
|
||||
/obj/structure/chair/comfy/black
|
||||
color = rgb(60,60,60)
|
||||
|
||||
/obj/structure/stool/bed/chair/comfy/green
|
||||
/obj/structure/chair/comfy/green
|
||||
color = rgb(1,196,8)
|
||||
|
||||
/obj/structure/stool/bed/chair/comfy/purp
|
||||
/obj/structure/chair/comfy/purp
|
||||
color = rgb(112,2,176)
|
||||
|
||||
/obj/structure/stool/bed/chair/comfy/blue
|
||||
/obj/structure/chair/comfy/blue
|
||||
color = rgb(2,9,210)
|
||||
|
||||
/obj/structure/stool/bed/chair/comfy/beige
|
||||
/obj/structure/chair/comfy/beige
|
||||
color = rgb(255,253,195)
|
||||
|
||||
/obj/structure/stool/bed/chair/comfy/lime
|
||||
/obj/structure/chair/comfy/lime
|
||||
color = rgb(255,251,0)
|
||||
|
||||
/obj/structure/stool/bed/chair/office
|
||||
anchored = 0
|
||||
movable = 1
|
||||
/obj/structure/chair/office
|
||||
anchored = FALSE
|
||||
movable = TRUE
|
||||
item_chair = null
|
||||
buildstackamount = 5
|
||||
|
||||
/obj/structure/stool/bed/chair/office/Bump(atom/A)
|
||||
/obj/structure/chair/office/Bump(atom/A)
|
||||
..()
|
||||
if(!buckled_mob) return
|
||||
if(!buckled_mob)
|
||||
return
|
||||
|
||||
if(propelled)
|
||||
var/mob/living/occupant = buckled_mob
|
||||
@@ -175,25 +228,190 @@
|
||||
victim.take_organ_damage(10)
|
||||
occupant.visible_message("<span class='danger'>[occupant] crashed into \the [A]!</span>")
|
||||
|
||||
/obj/structure/stool/bed/chair/office/light
|
||||
/obj/structure/chair/office/light
|
||||
icon_state = "officechair_white"
|
||||
|
||||
/obj/structure/stool/bed/chair/office/dark
|
||||
/obj/structure/chair/office/dark
|
||||
icon_state = "officechair_dark"
|
||||
|
||||
/obj/structure/stool/bed/chair/barber
|
||||
/obj/structure/chair/barber
|
||||
icon_state = "barber_chair"
|
||||
buildstackamount = 1
|
||||
item_chair = null
|
||||
|
||||
/obj/structure/stool/bed/chair/sofa
|
||||
// Sofas
|
||||
|
||||
/obj/structure/chair/sofa
|
||||
name = "sofa"
|
||||
icon_state = "sofamiddle"
|
||||
anchored = 1
|
||||
anchored = TRUE
|
||||
item_chair = null
|
||||
buildstackamount = 1
|
||||
|
||||
/obj/structure/stool/bed/chair/sofa/left
|
||||
/obj/structure/chair/sofa/left
|
||||
icon_state = "sofaend_left"
|
||||
/obj/structure/stool/bed/chair/sofa/right
|
||||
|
||||
/obj/structure/chair/sofa/right
|
||||
icon_state = "sofaend_right"
|
||||
/obj/structure/stool/bed/chair/sofa/corner
|
||||
|
||||
/obj/structure/chair/sofa/corner
|
||||
icon_state = "sofacorner"
|
||||
|
||||
/obj/structure/chair/stool
|
||||
name = "stool"
|
||||
desc = "Apply butt."
|
||||
icon_state = "stool"
|
||||
can_buckle = FALSE
|
||||
item_chair = /obj/item/chair/stool
|
||||
|
||||
/obj/structure/chair/stool/bar
|
||||
name = "bar stool"
|
||||
desc = "It has some unsavory stains on it..."
|
||||
icon_state = "bar"
|
||||
item_chair = /obj/item/chair/stool/bar
|
||||
|
||||
/obj/structure/chair/stool/ex_act(severity)
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
qdel(src)
|
||||
return
|
||||
if(2.0)
|
||||
if(prob(70))
|
||||
new buildstacktype(loc, buildstackamount)
|
||||
qdel(src)
|
||||
return
|
||||
if(3.0)
|
||||
if(prob(50))
|
||||
new buildstacktype(loc, buildstackamount)
|
||||
qdel(src)
|
||||
return
|
||||
|
||||
/obj/structure/chair/stool/blob_act()
|
||||
if(prob(75))
|
||||
new buildstacktype(loc, buildstackamount)
|
||||
qdel(src)
|
||||
|
||||
/obj/item/chair
|
||||
name = "chair"
|
||||
desc = "Bar brawl essential."
|
||||
icon = 'icons/obj/chairs.dmi'
|
||||
icon_state = "chair_toppled"
|
||||
item_state = "chair"
|
||||
lefthand_file = 'icons/mob/inhands/chairs_lefthand.dmi'
|
||||
righthand_file = 'icons/mob/inhands/chairs_righthand.dmi'
|
||||
w_class = WEIGHT_CLASS_HUGE
|
||||
force = 8
|
||||
throwforce = 10
|
||||
throw_range = 3
|
||||
hitsound = 'sound/items/trayhit1.ogg'
|
||||
hit_reaction_chance = 50
|
||||
materials = list(MAT_METAL = 2000)
|
||||
var/break_chance = 5 //Likely hood of smashing the chair.
|
||||
var/obj/structure/chair/origin_type = /obj/structure/chair
|
||||
|
||||
/obj/item/chair/stool
|
||||
name = "stool"
|
||||
icon = 'icons/obj/chairs.dmi'
|
||||
icon_state = "stool_toppled"
|
||||
item_state = "stool"
|
||||
force = 10
|
||||
throwforce = 10
|
||||
w_class = WEIGHT_CLASS_HUGE
|
||||
origin_type = /obj/structure/chair/stool
|
||||
break_chance = 0 //It's too sturdy.
|
||||
var/obj/structure/chair/stool/origin = null
|
||||
|
||||
/obj/item/chair/stool/bar
|
||||
name = "bar stool"
|
||||
icon_state = "bar_toppled"
|
||||
item_state = "stool_bar"
|
||||
origin_type = /obj/structure/chair/stool/bar
|
||||
|
||||
/obj/item/chair/attack_self(mob/user)
|
||||
plant(user)
|
||||
|
||||
/obj/item/chair/proc/plant(mob/user)
|
||||
for(var/obj/A in get_turf(loc))
|
||||
if(istype(A, /obj/structure/chair))
|
||||
to_chat(user, "<span class='danger'>There is already a chair here.</span>")
|
||||
return
|
||||
|
||||
user.visible_message("<span class='notice'>[user] rights \the [src.name].</span>", "<span class='notice'>You right \the [name].</span>")
|
||||
var/obj/structure/chair/C = new origin_type(get_turf(loc))
|
||||
C.setDir(dir)
|
||||
qdel(src)
|
||||
|
||||
/obj/item/chair/proc/smash(mob/living/user)
|
||||
var/stack_type = initial(origin_type.buildstacktype)
|
||||
if(!stack_type)
|
||||
return
|
||||
var/remaining_mats = initial(origin_type.buildstackamount)
|
||||
remaining_mats-- //Part of the chair was rendered completely unusable. It magically dissapears. Maybe make some dirt?
|
||||
if(remaining_mats)
|
||||
for(var/M=1 to remaining_mats)
|
||||
new stack_type(get_turf(loc))
|
||||
qdel(src)
|
||||
|
||||
/obj/item/chair/hit_reaction(mob/living/carbon/human/owner, atom/movable/hitby, attack_text = "the attack", final_block_chance = 0, damage = 0, attack_type = MELEE_ATTACK)
|
||||
if(attack_type == UNARMED_ATTACK && prob(hit_reaction_chance))
|
||||
owner.visible_message("<span class='danger'>[owner] fends off [attack_text] with [src]!</span>")
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/obj/item/chair/afterattack(atom/target, mob/living/carbon/user, proximity)
|
||||
..()
|
||||
if(!proximity)
|
||||
return
|
||||
if(prob(break_chance))
|
||||
user.visible_message("<span class='danger'>[user] smashes \the [src] to pieces against \the [target]</span>")
|
||||
if(iscarbon(target))
|
||||
var/mob/living/carbon/C = target
|
||||
if(C.health < C.maxHealth*0.5)
|
||||
C.apply_effect(6, STUN, 0)
|
||||
C.apply_effect(6, WEAKEN, 0)
|
||||
C.apply_effect(6, STUTTER, 0)
|
||||
playsound(src.loc, 'sound/weapons/punch1.ogg', 50, 1, -1)
|
||||
smash(user)
|
||||
|
||||
/obj/item/chair/stool/attack_self(mob/user as mob)
|
||||
..()
|
||||
origin.loc = get_turf(src)
|
||||
user.unEquip(src)
|
||||
user.visible_message("<span class='notice'>[user] puts [src] down.</span>", "<span class='notice'>You put [src] down.</span>")
|
||||
qdel(src)
|
||||
|
||||
/obj/item/chair/stool/attack(mob/M as mob, mob/user as mob)
|
||||
if(prob(5) && istype(M,/mob/living))
|
||||
user.visible_message("<span class='danger'>[user] breaks [src] over [M]'s back!.</span>")
|
||||
user.unEquip(src)
|
||||
var/obj/item/stack/sheet/metal/m = new/obj/item/stack/sheet/metal
|
||||
m.loc = get_turf(src)
|
||||
qdel(src)
|
||||
var/mob/living/T = M
|
||||
T.Weaken(5)
|
||||
return
|
||||
..()
|
||||
|
||||
/obj/item/chair/wood
|
||||
name = "wooden chair"
|
||||
icon_state = "wooden_chair_toppled"
|
||||
item_state = "woodenchair"
|
||||
resistance_flags = FLAMMABLE
|
||||
max_integrity = 70
|
||||
hitsound = 'sound/weapons/genhit1.ogg'
|
||||
origin_type = /obj/structure/chair/wood
|
||||
materials = null
|
||||
break_chance = 50
|
||||
|
||||
/obj/item/chair/wood/narsie_act()
|
||||
return
|
||||
|
||||
/obj/item/chair/wood/wings
|
||||
icon_state = "wooden_chair_wings_toppled"
|
||||
origin_type = /obj/structure/chair/wood/wings
|
||||
|
||||
/obj/structure/chair/old
|
||||
name = "strange chair"
|
||||
desc = "You sit in this. Either by will or force. Looks REALLY uncomfortable."
|
||||
icon_state = "chairold"
|
||||
item_chair = null
|
||||
|
||||
@@ -1,77 +0,0 @@
|
||||
/obj/structure/stool
|
||||
name = "stool"
|
||||
desc = "Apply butt."
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "stool"
|
||||
anchored = 1.0
|
||||
var/buildstackamount = 1
|
||||
var/buildstacktype = /obj/item/stack/sheet/metal
|
||||
|
||||
/obj/structure/stool/ex_act(severity)
|
||||
switch(severity)
|
||||
if(1.0)
|
||||
qdel(src)
|
||||
return
|
||||
if(2.0)
|
||||
if(prob(70))
|
||||
new buildstacktype(loc, buildstackamount)
|
||||
qdel(src)
|
||||
return
|
||||
if(3.0)
|
||||
if(prob(50))
|
||||
new buildstacktype(loc, buildstackamount)
|
||||
qdel(src)
|
||||
return
|
||||
return
|
||||
|
||||
/obj/structure/stool/blob_act()
|
||||
if(prob(75))
|
||||
new buildstacktype(loc, buildstackamount)
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/stool/attackby(obj/item/W as obj, mob/user as mob, params)
|
||||
if(istype(W, /obj/item/wrench))
|
||||
playsound(loc, W.usesound, 50, 1)
|
||||
new buildstacktype(loc, buildstackamount)
|
||||
qdel(src)
|
||||
|
||||
/obj/structure/stool/MouseDrop(atom/over_object, src_location, over_location, src_control, over_control, params, skip_fucking_stool_shit = 0)
|
||||
if(skip_fucking_stool_shit)
|
||||
return ..(over_object)
|
||||
if(istype(over_object, /mob/living/carbon/human))
|
||||
var/mob/living/carbon/human/H = over_object
|
||||
if(H==usr && !H.restrained() && !H.stat && in_range(src, over_object))
|
||||
var/obj/item/stool/S = new/obj/item/stool()
|
||||
S.origin = src
|
||||
loc = S
|
||||
H.put_in_hands(S)
|
||||
H.visible_message("<span class='warning'>[H] grabs [src] from the floor!</span>", "<span class='warning'>You grab [src] from the floor!</span>")
|
||||
|
||||
/obj/item/stool
|
||||
name = "stool"
|
||||
desc = "Uh-hoh, bar is heating up."
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "stool"
|
||||
force = 10
|
||||
throwforce = 10
|
||||
w_class = WEIGHT_CLASS_HUGE
|
||||
var/obj/structure/stool/origin = null
|
||||
|
||||
/obj/item/stool/attack_self(mob/user as mob)
|
||||
..()
|
||||
origin.loc = get_turf(src)
|
||||
user.unEquip(src)
|
||||
user.visible_message("<span class='notice'>[user] puts [src] down.</span>", "<span class='notice'>You put [src] down.</span>")
|
||||
qdel(src)
|
||||
|
||||
/obj/item/stool/attack(mob/M as mob, mob/user as mob)
|
||||
if(prob(5) && istype(M,/mob/living))
|
||||
user.visible_message("<span class='danger'>[user] breaks [src] over [M]'s back!.</span>")
|
||||
user.unEquip(src)
|
||||
var/obj/item/stack/sheet/metal/m = new/obj/item/stack/sheet/metal
|
||||
m.loc = get_turf(src)
|
||||
qdel(src)
|
||||
var/mob/living/T = M
|
||||
T.Weaken(5)
|
||||
return
|
||||
..()
|
||||
@@ -1,21 +1,20 @@
|
||||
/obj/structure/stool/bed/chair/wheelchair
|
||||
/obj/structure/chair/wheelchair
|
||||
name = "wheelchair"
|
||||
desc = "You sit in this. Either by will or force."
|
||||
icon = 'icons/obj/objects.dmi'
|
||||
icon_state = "wheelchair"
|
||||
anchored = 0
|
||||
movable = 1
|
||||
item_chair = null
|
||||
anchored = FALSE
|
||||
movable = TRUE
|
||||
|
||||
var/move_delay = null
|
||||
|
||||
/obj/structure/stool/bed/chair/wheelchair/handle_rotation()
|
||||
/obj/structure/chair/wheelchair/handle_rotation()
|
||||
overlays = null
|
||||
var/image/O = image(icon = icon, icon_state = "[icon_state]_overlay", layer = FLY_LAYER, dir = src.dir)
|
||||
overlays += O
|
||||
if(buckled_mob)
|
||||
buckled_mob.dir = dir
|
||||
|
||||
/obj/structure/stool/bed/chair/wheelchair/relaymove(mob/user, direction)
|
||||
/obj/structure/chair/wheelchair/relaymove(mob/user, direction)
|
||||
if(propelled)
|
||||
return 0
|
||||
|
||||
@@ -67,9 +66,11 @@
|
||||
else
|
||||
. = 1
|
||||
|
||||
/obj/structure/stool/bed/chair/wheelchair/Bump(atom/A)
|
||||
/obj/structure/chair/wheelchair/Bump(atom/A)
|
||||
..()
|
||||
if(!buckled_mob) return
|
||||
|
||||
if(!buckled_mob)
|
||||
return
|
||||
|
||||
if(istype(A, /obj/machinery/door))
|
||||
A.Bumped(buckled_mob)
|
||||
@@ -93,14 +94,14 @@
|
||||
|
||||
occupant.visible_message("<span class='danger'>[occupant] crashed into \the [A]!</span>")
|
||||
|
||||
/obj/structure/stool/bed/chair/wheelchair/bike
|
||||
/obj/structure/chair/wheelchair/bike
|
||||
name = "bicycle"
|
||||
desc = "Two wheels of FURY!"
|
||||
//placeholder until i get a bike sprite
|
||||
icon = 'icons/vehicles/motorcycle.dmi'
|
||||
icon_state = "motorcycle_4dir"
|
||||
|
||||
/obj/structure/stool/bed/chair/wheelchair/bike/relaymove(mob/user, direction)
|
||||
/obj/structure/chair/wheelchair/bike/relaymove(mob/user, direction)
|
||||
if(propelled)
|
||||
return 0
|
||||
|
||||
|
||||
@@ -50,8 +50,8 @@
|
||||
/obj/structure/table/update_icon()
|
||||
if(smooth && !flipped)
|
||||
icon_state = ""
|
||||
smooth_icon(src)
|
||||
smooth_icon_neighbors(src)
|
||||
queue_smooth(src)
|
||||
queue_smooth_neighbors(src)
|
||||
|
||||
if(flipped)
|
||||
clear_smooth_overlays()
|
||||
|
||||
@@ -115,8 +115,8 @@
|
||||
if(!open)
|
||||
return
|
||||
var/obj/item/reagent_containers/RG = I
|
||||
if(RG.is_open_container())
|
||||
if(RG.reagents.total_volume >= RG.volume)
|
||||
if(RG.is_refillable())
|
||||
if(RG.reagents.holder_full())
|
||||
to_chat(user, "<span class='warning'>[RG] is full.</span>")
|
||||
else
|
||||
RG.reagents.add_reagent("toiletwater", min(RG.volume - RG.reagents.total_volume, RG.amount_per_transfer_from_this))
|
||||
@@ -243,7 +243,7 @@
|
||||
icon_state = "shower"
|
||||
density = 0
|
||||
anchored = 1
|
||||
use_power = 0
|
||||
use_power = NO_POWER_USE
|
||||
var/on = 0
|
||||
var/obj/effect/mist/mymist = null
|
||||
var/ismist = 0 //needs a var so we can make it linger~
|
||||
@@ -278,7 +278,7 @@
|
||||
icon_state = "mist"
|
||||
layer = MOB_LAYER + 1
|
||||
anchored = 1
|
||||
mouse_opacity = 0
|
||||
mouse_opacity = MOUSE_OPACITY_TRANSPARENT
|
||||
|
||||
/obj/machinery/shower/attack_hand(mob/M as mob)
|
||||
on = !on
|
||||
@@ -756,4 +756,3 @@
|
||||
qdel(src)
|
||||
if(prob(50))
|
||||
new /obj/item/stack/sheet/cardboard(T)
|
||||
|
||||
|
||||
@@ -65,7 +65,7 @@ var/global/wcCommon = pick(list("#379963", "#0d8395", "#58b5c3", "#49e46e", "#8f
|
||||
else
|
||||
to_chat(user, "<span class='notice'>The window is <i>unscrewed</i> from the floor, and could be deconstructed by <b>wrenching</b>.</span>")
|
||||
if(!anchored && !fulltile)
|
||||
to_chat(user, "<span class='notice'>Alt-click to rotate it clockwise.</span>")
|
||||
to_chat(user, "<span class='notice'>Alt-click to rotate it.</span>")
|
||||
|
||||
/obj/structure/window/New(Loc, direct)
|
||||
..()
|
||||
@@ -355,7 +355,7 @@ var/global/wcCommon = pick(list("#379963", "#0d8395", "#58b5c3", "#49e46e", "#8f
|
||||
set category = "Object"
|
||||
set src in oview(1)
|
||||
|
||||
if(usr.stat || !usr.canmove || usr.restrained())
|
||||
if(usr.incapacitated())
|
||||
return
|
||||
|
||||
if(anchored)
|
||||
@@ -378,7 +378,7 @@ var/global/wcCommon = pick(list("#379963", "#0d8395", "#58b5c3", "#49e46e", "#8f
|
||||
set category = "Object"
|
||||
set src in oview(1)
|
||||
|
||||
if(usr.stat || !usr.canmove || usr.restrained())
|
||||
if(usr.incapacitated())
|
||||
return
|
||||
|
||||
if(anchored)
|
||||
@@ -397,12 +397,31 @@ var/global/wcCommon = pick(list("#379963", "#0d8395", "#58b5c3", "#49e46e", "#8f
|
||||
return TRUE
|
||||
|
||||
/obj/structure/window/AltClick(mob/user)
|
||||
|
||||
if(user.incapacitated())
|
||||
to_chat(user, "<span class='warning'>You can't do that right now!</span>")
|
||||
return
|
||||
|
||||
if(!Adjacent(user))
|
||||
to_chat(user, "<span class='warning'>Move closer to the window!</span>")
|
||||
return
|
||||
revrotate()
|
||||
|
||||
if(anchored)
|
||||
to_chat(user, "<span class='warning'>[src] cannot be rotated while it is fastened to the floor!</span>")
|
||||
return FALSE
|
||||
|
||||
var/target_dir = turn(dir, 270)
|
||||
|
||||
if(!valid_window_location(loc, target_dir))
|
||||
target_dir = turn(dir, 90)
|
||||
if(!valid_window_location(loc, target_dir))
|
||||
to_chat(user, "<span class='warning'>There is no room to rotate the [src]</span>")
|
||||
return FALSE
|
||||
|
||||
setDir(target_dir)
|
||||
ini_dir = dir
|
||||
add_fingerprint(user)
|
||||
return TRUE
|
||||
|
||||
/obj/structure/window/Destroy()
|
||||
density = FALSE
|
||||
@@ -425,7 +444,7 @@ var/global/wcCommon = pick(list("#379963", "#0d8395", "#58b5c3", "#49e46e", "#8f
|
||||
/obj/structure/window/proc/update_nearby_icons()
|
||||
update_icon()
|
||||
if(smooth)
|
||||
smooth_icon_neighbors(src)
|
||||
queue_smooth_neighbors(src)
|
||||
|
||||
/obj/structure/window/update_icon()
|
||||
if(!QDELETED(src))
|
||||
@@ -434,7 +453,7 @@ var/global/wcCommon = pick(list("#379963", "#0d8395", "#58b5c3", "#49e46e", "#8f
|
||||
var/ratio = obj_integrity / max_integrity
|
||||
ratio = CEILING(ratio*4, 1) * 25
|
||||
if(smooth)
|
||||
smooth_icon(src)
|
||||
queue_smooth(src)
|
||||
overlays -= crack_overlay
|
||||
if(ratio > 75)
|
||||
return
|
||||
@@ -714,4 +733,4 @@ obj/structure/window/full/reinforced/ice
|
||||
dir = FULLTILE_WINDOW_DIR
|
||||
max_integrity = 120
|
||||
level = 3
|
||||
glass_amount = 2
|
||||
glass_amount = 2
|
||||
|
||||
Reference in New Issue
Block a user