Merge remote-tracking branch 'bay12-upstream/master' into development

This commit is contained in:
skull132
2016-10-07 00:58:39 +03:00
1594 changed files with 53994 additions and 48590 deletions
@@ -4,6 +4,7 @@
icon = 'icons/obj/closet.dmi'
icon_state = "closed"
density = 1
w_class = 5
var/icon_closed = "closed"
var/icon_opened = "open"
var/opened = 0
@@ -11,7 +12,7 @@
var/wall_mounted = 0 //never solid (You can always pass over it)
var/health = 100
var/breakout = 0 //if someone is currently breaking out. mutex
var/storage_capacity = 30 //This is so that someone can't pack hundreds of items in a locker/crate
var/storage_capacity = 2 * MOB_MEDIUM //This is so that someone can't pack hundreds of items in a locker/crate
//then open it in a populated area to crash clients.
var/open_sound = 'sound/machines/click.ogg'
var/close_sound = 'sound/machines/click.ogg'
@@ -20,9 +21,8 @@
var/store_items = 1
var/store_mobs = 1
var/const/default_mob_size = 15
/obj/structure/closet/initialize()
..()
if(!opened) // if closed, any item at the crate's loc is put in the contents
var/obj/item/I
for(I in src.loc)
@@ -53,11 +53,6 @@
else
user << "It is full."
/obj/structure/closet/alter_health()
return get_turf(src)
/obj/structure/closet/CanPass(atom/movable/mover, turf/target, height=0, air_group=0)
if(air_group || (height==0 || wall_mounted)) return 1
return (!density)
@@ -150,14 +145,13 @@
for(var/mob/living/M in src.loc)
if(M.buckled || M.pinned.len)
continue
var/current_mob_size = (M.mob_size ? M.mob_size : default_mob_size)
if(stored_units + added_units + current_mob_size > storage_capacity)
if(stored_units + added_units + M.mob_size > storage_capacity)
break
if(M.client)
M.client.perspective = EYE_PERSPECTIVE
M.client.eye = src
M.forceMove(src)
added_units += current_mob_size
added_units += M.mob_size
return added_units
/obj/structure/closet/proc/toggle(mob/user as mob)
@@ -194,28 +188,15 @@
qdel(src)
/obj/structure/closet/bullet_act(var/obj/item/projectile/Proj)
if(!(Proj.damage_type == BRUTE || Proj.damage_type == BURN))
var/proj_damage = Proj.get_structure_damage()
if(!proj_damage)
return
..()
damage(Proj.damage)
damage(proj_damage)
return
// this should probably use dump_contents()
/obj/structure/closet/blob_act()
if(prob(75))
for(var/atom/movable/A as mob|obj in src)
A.forceMove(src.loc)
qdel(src)
/obj/structure/closet/meteorhit(obj/O as obj)
if(O.icon_state == "flaming")
for(var/mob/M in src)
M.meteorhit(O)
src.dump_contents()
qdel(src)
/obj/structure/closet/attackby(obj/item/weapon/W as obj, mob/user as mob)
if(src.opened)
if(istype(W, /obj/item/weapon/grab))
@@ -237,6 +218,15 @@
M.show_message("<span class='notice'>\The [src] has been cut apart by [user] with \the [WT].</span>", 3, "You hear welding.", 2)
qdel(src)
return
if(istype(W, /obj/item/weapon/storage/laundry_basket) && W.contents.len)
var/obj/item/weapon/storage/laundry_basket/LB = W
var/turf/T = get_turf(src)
for(var/obj/item/I in LB.contents)
LB.remove_from_storage(I, T)
user.visible_message("<span class='notice'>[user] empties \the [LB] into \the [src].</span>", \
"<span class='notice'>You empty \the [LB] into \the [src].</span>", \
"<span class='notice'>You hear rustling of clothes.</span>")
return
if(isrobot(user))
return
if(W.loc != user) // This should stop mounted modules ending up outside the module.
@@ -327,12 +317,6 @@
else
icon_state = icon_opened
/obj/structure/closet/hear_talk(mob/M as mob, text, verb, datum/language/speaking)
for (var/atom/A in src)
if(istype(A,/obj/))
var/obj/O = A
O.hear_talk(M, text, verb, speaking)
/obj/structure/closet/attack_generic(var/mob/user, var/damage, var/attack_message = "destroys", var/wallbreaker)
if(!damage || !wallbreaker)
return
@@ -357,9 +341,9 @@
if(!req_breakout())
return
escapee.setClickCooldown(100)
//okay, so the closet is either welded or locked... resist!!!
escapee.next_move = world.time + 100
escapee.last_special = world.time + 100
escapee << "<span class='warning'>You lean on the back of \the [src] and start pushing the door open. (this will take about [breakout_time] minutes)</span>"
visible_message("<span class='danger'>The [src] begins to shake violently!</span>")
@@ -1,210 +0,0 @@
//I still dont think this should be a closet but whatever
/obj/structure/closet/fireaxecabinet
name = "fire axe cabinet"
desc = "There is small label that reads \"For Emergency use only\" along with details for safe use of the axe. As if."
var/obj/item/weapon/material/twohanded/fireaxe/fireaxe
icon_state = "fireaxe1000"
icon_closed = "fireaxe1000"
icon_opened = "fireaxe1100"
anchored = 1
density = 0
var/localopened = 0 //Setting this to keep it from behaviouring like a normal closet and obstructing movement in the map. -Agouri
opened = 1
var/hitstaken = 0
var/locked = 1
var/smashed = 0
New()
..()
fireaxe = new /obj/item/weapon/material/twohanded/fireaxe(src)
attackby(var/obj/item/O as obj, var/mob/user as mob) //Marker -Agouri
//..() //That's very useful, Erro
var/hasaxe = 0 //gonna come in handy later~
if(fireaxe)
hasaxe = 1
if (isrobot(usr) || src.locked)
if(istype(O, /obj/item/device/multitool))
user << "\red Resetting circuitry..."
playsound(user, 'sound/machines/lockreset.ogg', 50, 1)
if(do_after(user, 20))
src.locked = 0
user << "<span class = 'caution'> You disable the locking modules.</span>"
update_icon()
return
else if(istype(O, /obj/item/weapon))
var/obj/item/weapon/W = O
if(src.smashed || src.localopened)
if(localopened)
localopened = 0
icon_state = text("fireaxe[][][][]closing",hasaxe,src.localopened,src.hitstaken,src.smashed)
spawn(10) update_icon()
return
else
playsound(user, 'sound/effects/Glasshit.ogg', 100, 1) //We don't want this playing every time
if(W.force < 15)
user << "\blue The cabinet's protective glass glances off the hit."
else
src.hitstaken++
if(src.hitstaken == 4)
playsound(user, 'sound/effects/Glassbr3.ogg', 100, 1) //Break cabinet, receive goodies. Cabinet's fucked for life after that.
src.smashed = 1
src.locked = 0
src.localopened = 1
update_icon()
return
if (istype(O, /obj/item/weapon/material/twohanded/fireaxe) && src.localopened)
if(!fireaxe)
if(O:wielded)
user << "\red Unwield the axe first."
return
fireaxe = O
user.remove_from_mob(O)
src.contents += O
user << "\blue You place the fire axe back in the [src.name]."
update_icon()
else
if(src.smashed)
return
else
localopened = !localopened
if(localopened)
icon_state = text("fireaxe[][][][]opening",hasaxe,src.localopened,src.hitstaken,src.smashed)
spawn(10) update_icon()
else
icon_state = text("fireaxe[][][][]closing",hasaxe,src.localopened,src.hitstaken,src.smashed)
spawn(10) update_icon()
else
if(src.smashed)
return
if(istype(O, /obj/item/device/multitool))
if(localopened)
localopened = 0
icon_state = text("fireaxe[][][][]closing",hasaxe,src.localopened,src.hitstaken,src.smashed)
spawn(10) update_icon()
return
else
user << "\red Resetting circuitry..."
sleep(50)
src.locked = 1
user << "\blue You re-enable the locking modules."
playsound(user, 'sound/machines/lockenable.ogg', 50, 1)
if(do_after(user,20))
src.locked = 1
user << "<span class = 'caution'> You re-enable the locking modules.</span>"
return
else
localopened = !localopened
if(localopened)
icon_state = text("fireaxe[][][][]opening",hasaxe,src.localopened,src.hitstaken,src.smashed)
spawn(10) update_icon()
else
icon_state = text("fireaxe[][][][]closing",hasaxe,src.localopened,src.hitstaken,src.smashed)
spawn(10) update_icon()
attack_hand(mob/user as mob)
var/hasaxe = 0
if(fireaxe)
hasaxe = 1
if(src.locked)
user <<"\red The cabinet won't budge!"
return
if(localopened)
if(fireaxe)
user.put_in_hands(fireaxe)
fireaxe = null
user << "\blue You take the fire axe from the [name]."
src.add_fingerprint(user)
update_icon()
else
if(src.smashed)
return
else
localopened = !localopened
if(localopened)
src.icon_state = text("fireaxe[][][][]opening",hasaxe,src.localopened,src.hitstaken,src.smashed)
spawn(10) update_icon()
else
src.icon_state = text("fireaxe[][][][]closing",hasaxe,src.localopened,src.hitstaken,src.smashed)
spawn(10) update_icon()
else
localopened = !localopened //I'm pretty sure we don't need an if(src.smashed) in here. In case I'm wrong and it fucks up teh cabinet, **MARKER**. -Agouri
if(localopened)
src.icon_state = text("fireaxe[][][][]opening",hasaxe,src.localopened,src.hitstaken,src.smashed)
spawn(10) update_icon()
else
src.icon_state = text("fireaxe[][][][]closing",hasaxe,src.localopened,src.hitstaken,src.smashed)
spawn(10) update_icon()
attack_tk(mob/user as mob)
if(localopened && fireaxe)
fireaxe.forceMove(loc)
user << "<span class='notice'>You telekinetically remove the fire axe.</span>"
fireaxe = null
update_icon()
return
attack_hand(user)
verb/toggle_openness() //nice name, huh? HUH?! -Erro //YEAH -Agouri
set name = "Open/Close"
set category = "Object"
if (isrobot(usr) || src.locked || src.smashed)
if(src.locked)
usr << "\red The cabinet won't budge!"
else if(src.smashed)
usr << "\blue The protective glass is broken!"
return
localopened = !localopened
update_icon()
verb/remove_fire_axe()
set name = "Remove Fire Axe"
set category = "Object"
if (isrobot(usr))
return
if (localopened)
if(fireaxe)
usr.put_in_hands(fireaxe)
fireaxe = null
usr << "\blue You take the Fire axe from the [name]."
else
usr << "\blue The [src.name] is empty."
else
usr << "\blue The [src.name] is closed."
update_icon()
attack_ai(mob/user as mob)
if(src.smashed)
user << "\red The security of the cabinet is compromised."
return
else
locked = !locked
if(locked)
user << "\red Cabinet locked."
else
user << "\blue Cabinet unlocked."
return
update_icon() //Template: fireaxe[has fireaxe][is opened][hits taken][is smashed]. If you want the opening or closing animations, add "opening" or "closing" right after the numbers
var/hasaxe = 0
if(fireaxe)
hasaxe = 1
icon_state = text("fireaxe[][][][]",hasaxe,src.localopened,src.hitstaken,src.smashed)
open()
return
close()
return
@@ -68,7 +68,7 @@
new /obj/item/weapon/cartridge/janitor(src)
new /obj/item/clothing/gloves/black(src)
new /obj/item/clothing/head/soft/purple(src)
new /obj/item/clothing/head/beret/jan(src)
new /obj/item/clothing/head/beret/purple(src)
new /obj/item/device/flashlight(src)
new /obj/item/weapon/caution(src)
new /obj/item/weapon/caution(src)
@@ -11,16 +11,16 @@
New()
..()
new /obj/item/weapon/reagent_containers/food/drinks/cans/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/cans/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/cans/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/cans/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/cans/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/cans/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/cans/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/cans/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/cans/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/cans/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/bottle/small/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/bottle/small/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/bottle/small/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/bottle/small/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/bottle/small/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/bottle/small/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/bottle/small/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/bottle/small/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/bottle/small/beer( src )
new /obj/item/weapon/reagent_containers/food/drinks/bottle/small/beer( src )
return
/obj/structure/closet/secure_closet/bar/update_icon()
@@ -148,5 +148,5 @@
new /obj/item/clothing/suit/storage/hazardvest(src)
new /obj/item/clothing/mask/gas(src)
new /obj/item/weapon/cartridge/atmos(src)
new /obj/item/taperoll/engineering(src)
new /obj/item/taperoll/atmos(src)
return
@@ -96,6 +96,7 @@
new /obj/item/clothing/shoes/white(src)
// new /obj/item/weapon/cartridge/medical(src)
new /obj/item/device/radio/headset/headset_med(src)
new /obj/item/taperoll/medical(src)
return
@@ -83,23 +83,27 @@
src.registered_name = I.registered_name
src.desc = "Owned by [I.registered_name]."
else
user << "\red Access Denied"
else if( (istype(W, /obj/item/weapon/card/emag)||istype(W, /obj/item/weapon/melee/energy/blade)) && !src.broken)
broken = 1
locked = 0
desc = "It appears to be broken."
icon_state = src.icon_broken
if(istype(W, /obj/item/weapon/melee/energy/blade))
user << "<span class='warning'>Access Denied</span>"
else if(istype(W, /obj/item/weapon/melee/energy/blade))
if(emag_act(INFINITY, user, "The locker has been sliced open by [user] with \an [W]!", "You hear metal being sliced and sparks flying."))
var/datum/effect/effect/system/spark_spread/spark_system = new /datum/effect/effect/system/spark_spread()
spark_system.set_up(5, 0, src.loc)
spark_system.start()
playsound(src.loc, 'sound/weapons/blade1.ogg', 50, 1)
playsound(src.loc, "sparks", 50, 1)
for(var/mob/O in viewers(user, 3))
O.show_message("\blue The locker has been sliced open by [user] with an energy blade!", 1, "\red You hear metal being sliced and sparks flying.", 2)
else
user << "\red Access Denied"
user << "<span class='warning'>Access Denied</span>"
return
/obj/structure/closet/secure_closet/personal/emag_act(var/remaining_charges, var/mob/user, var/visual_feedback, var/audible_feedback)
if(!broken)
broken = 1
locked = 0
desc = "It appears to be broken."
icon_state = src.icon_broken
if(visual_feedback)
visible_message("<span class='warning'>[visual_feedback]</span>", "<span class='warning'>[audible_feedback]</span>")
return 1
/obj/structure/closet/secure_closet/personal/verb/reset()
set src in oview(1) // One square distance
@@ -110,9 +114,9 @@
if(ishuman(usr))
src.add_fingerprint(usr)
if (src.locked || !src.registered_name)
usr << "\red You need to unlock it first."
usr << "<span class='warning'>You need to unlock it first.</span>"
else if (src.broken)
usr << "\red It appears to be broken."
usr << "<span class='warning'>It appears to be broken.</span>"
else
if (src.opened)
if(!src.close())
@@ -41,7 +41,7 @@
open()
else
src.req_access = list()
src.req_access += pick(get_all_accesses())
src.req_access += pick(get_all_station_access())
..()
/obj/structure/closet/secure_closet/proc/togglelock(mob/user as mob)
@@ -65,6 +65,8 @@
/obj/structure/closet/secure_closet/attackby(obj/item/weapon/W as obj, mob/user as mob)
if(src.opened)
if(istype(W, /obj/item/weapon/storage/laundry_basket))
return ..(W,user)
if(istype(W, /obj/item/weapon/grab))
var/obj/item/weapon/grab/G = W
if(src.large)
@@ -78,28 +80,34 @@
user.drop_item()
if(W)
W.forceMove(src.loc)
else if((istype(W, /obj/item/weapon/card/emag)||istype(W, /obj/item/weapon/melee/energy/blade)) && !src.broken)
broken = 1
locked = 0
desc = "It appears to be broken."
icon_state = icon_off
flick(icon_broken, src)
if(istype(W, /obj/item/weapon/melee/energy/blade))
else if(istype(W, /obj/item/weapon/melee/energy/blade))
if(emag_act(INFINITY, user, "<span class='danger'>The locker has been sliced open by [user] with \an [W]</span>!", "<span class='danger'>You hear metal being sliced and sparks flying.</span>"))
var/datum/effect/effect/system/spark_spread/spark_system = new /datum/effect/effect/system/spark_spread()
spark_system.set_up(5, 0, src.loc)
spark_system.start()
playsound(src.loc, 'sound/weapons/blade1.ogg', 50, 1)
playsound(src.loc, "sparks", 50, 1)
for(var/mob/O in viewers(user, 3))
O.show_message("<span class='warning'>The locker has been sliced open by [user] with an energy blade!</span>", 1, "You hear metal being sliced and sparks flying.", 2)
else
for(var/mob/O in viewers(user, 3))
O.show_message("<span class='warning'>The locker has been broken by [user] with an electromagnetic card!</span>", 1, "You hear a faint electrical spark.", 2)
else if(istype(W,/obj/item/weapon/packageWrap) || istype(W,/obj/item/weapon/weldingtool))
return ..(W,user)
else
togglelock(user)
/obj/structure/closet/secure_closet/emag_act(var/remaining_charges, var/mob/user, var/emag_source, var/visual_feedback = "", var/audible_feedback = "")
if(!broken)
broken = 1
locked = 0
desc = "It appears to be broken."
icon_state = icon_off
flick(icon_broken, src)
if(visual_feedback)
visible_message(visual_feedback, audible_feedback)
else if(user && emag_source)
visible_message("<span class='warning'>\The [src] has been broken by \the [user] with \an [emag_source]!</span>", "You hear a faint electrical spark.")
else
visible_message("<span class='warning'>\The [src] sparks and breaks open!</span>", "You hear a faint electrical spark.")
return 1
/obj/structure/closet/secure_closet/attack_hand(mob/user as mob)
src.add_fingerprint(user)
if(src.locked)
@@ -16,11 +16,11 @@
new /obj/item/weapon/storage/backpack/satchel_cap(src)
new /obj/item/clothing/suit/captunic(src)
new /obj/item/clothing/suit/captunic/capjacket(src)
new /obj/item/clothing/head/helmet/cap(src)
new /obj/item/clothing/head/caphat/cap(src)
new /obj/item/clothing/under/rank/captain(src)
new /obj/item/clothing/suit/storage/vest(src)
new /obj/item/clothing/suit/armor/vest(src)
new /obj/item/weapon/cartridge/captain(src)
new /obj/item/clothing/head/helmet/swat(src)
new /obj/item/clothing/head/helmet(src)
new /obj/item/clothing/shoes/brown(src)
new /obj/item/device/radio/headset/heads/captain(src)
new /obj/item/clothing/gloves/captain(src)
@@ -28,7 +28,7 @@
new /obj/item/clothing/suit/armor/captain(src)
new /obj/item/weapon/melee/telebaton(src)
new /obj/item/clothing/under/dress/dress_cap(src)
new /obj/item/clothing/head/helmet/formalcaptain(src)
new /obj/item/clothing/head/caphat/formal(src)
new /obj/item/clothing/under/captainformal(src)
return
@@ -47,13 +47,12 @@
New()
..()
new /obj/item/clothing/glasses/sunglasses(src)
new /obj/item/clothing/suit/storage/vest(src)
new /obj/item/clothing/suit/armor/vest(src)
new /obj/item/clothing/head/helmet(src)
new /obj/item/weapon/cartridge/hop(src)
new /obj/item/device/radio/headset/heads/hop(src)
new /obj/item/weapon/storage/box/ids(src)
new /obj/item/weapon/storage/box/ids( src )
new /obj/item/weapon/gun/energy/gun(src)
new /obj/item/weapon/gun/projectile/sec/flash(src)
new /obj/item/device/flash(src)
return
@@ -82,7 +81,7 @@
new /obj/item/clothing/shoes/leather(src)
new /obj/item/clothing/shoes/white(src)
new /obj/item/clothing/under/rank/head_of_personnel_whimsy(src)
new /obj/item/clothing/head/helmet/hop(src)
new /obj/item/clothing/head/caphat/hop(src)
return
@@ -103,13 +102,14 @@
new /obj/item/weapon/storage/backpack/security(src)
else
new /obj/item/weapon/storage/backpack/satchel_sec(src)
new /obj/item/clothing/head/helmet/HoS(src)
new /obj/item/clothing/head/HoS(src)
new /obj/item/clothing/suit/armor/vest/security(src)
new /obj/item/clothing/suit/storage/vest/hos(src)
new /obj/item/clothing/under/rank/head_of_security/jensen(src)
new /obj/item/clothing/under/rank/head_of_security/corp(src)
new /obj/item/clothing/suit/armor/hos/jensen(src)
new /obj/item/clothing/suit/armor/hos(src)
new /obj/item/clothing/head/helmet/HoS/dermal(src)
new /obj/item/clothing/head/HoS/dermal(src)
new /obj/item/weapon/cartridge/hos(src)
new /obj/item/device/radio/headset/heads/hos(src)
new /obj/item/clothing/glasses/sunglasses/sechud(src)
@@ -122,7 +122,8 @@
new /obj/item/weapon/gun/energy/gun(src)
new /obj/item/clothing/accessory/holster/waist(src)
new /obj/item/weapon/melee/telebaton(src)
new /obj/item/clothing/head/beret/sec/hos(src)
new /obj/item/clothing/head/beret/sec/corporate/hos(src)
new /obj/item/clothing/accessory/badge/hos(src)
return
@@ -144,22 +145,25 @@
new /obj/item/weapon/storage/backpack/security(src)
else
new /obj/item/weapon/storage/backpack/satchel_sec(src)
new /obj/item/clothing/suit/armor/vest/security(src)
new /obj/item/clothing/suit/storage/vest/warden(src)
new /obj/item/clothing/under/rank/warden(src)
new /obj/item/clothing/under/rank/warden/corp(src)
new /obj/item/clothing/suit/armor/vest/warden(src)
new /obj/item/clothing/head/helmet/warden(src)
new /obj/item/clothing/head/warden(src)
new /obj/item/weapon/cartridge/security(src)
new /obj/item/device/radio/headset/headset_sec(src)
new /obj/item/clothing/glasses/sunglasses/sechud(src)
new /obj/item/taperoll/police(src)
new /obj/item/weapon/storage/box/flashbangs(src)
new /obj/item/weapon/storage/box/teargas(src)
new /obj/item/weapon/storage/belt/security(src)
new /obj/item/weapon/reagent_containers/spray/pepper(src)
new /obj/item/weapon/melee/baton/loaded(src)
new /obj/item/weapon/gun/energy/gun(src)
new /obj/item/weapon/storage/box/holobadge(src)
new /obj/item/clothing/head/beret/sec/warden(src)
new /obj/item/clothing/head/beret/sec/corporate/warden(src)
new /obj/item/clothing/accessory/badge/warden(src)
return
@@ -180,14 +184,14 @@
new /obj/item/weapon/storage/backpack/security(src)
else
new /obj/item/weapon/storage/backpack/satchel_sec(src)
new /obj/item/clothing/suit/storage/vest/officer(src)
new /obj/item/clothing/suit/armor/vest/security(src)
new /obj/item/clothing/head/helmet(src)
// new /obj/item/weapon/cartridge/security(src)
new /obj/item/device/radio/headset/headset_sec(src)
new /obj/item/weapon/storage/belt/security(src)
new /obj/item/device/flash(src)
new /obj/item/weapon/reagent_containers/spray/pepper(src)
new /obj/item/weapon/grenade/flashbang(src)
new /obj/item/weapon/grenade/chem_grenade/teargas(src)
new /obj/item/weapon/melee/baton/loaded(src)
new /obj/item/clothing/glasses/sunglasses/sechud(src)
new /obj/item/taperoll/police(src)
@@ -195,7 +199,6 @@
new /obj/item/clothing/accessory/storage/black_vest(src)
new /obj/item/clothing/head/soft/sec/corp(src)
new /obj/item/clothing/under/rank/security/corp(src)
new /obj/item/ammo_magazine/c45m/rubber(src)
new /obj/item/weapon/gun/energy/taser(src)
return
@@ -246,19 +249,19 @@
New()
..()
new /obj/item/clothing/under/det(src)
new /obj/item/clothing/under/det/grey(src)
new /obj/item/clothing/under/det/black(src)
new /obj/item/clothing/under/det/slob(src)
new /obj/item/clothing/suit/storage/det_suit(src)
new /obj/item/clothing/suit/storage/det_suit/black(src)
new /obj/item/clothing/suit/storage/det_trench(src)
new /obj/item/clothing/suit/storage/det_trench/grey(src)
new /obj/item/clothing/suit/storage/forensics/blue(src)
new /obj/item/clothing/suit/storage/forensics/red(src)
new /obj/item/clothing/gloves/black(src)
new /obj/item/clothing/head/det_hat(src)
new /obj/item/clothing/head/det_hat/black(src)
new /obj/item/clothing/shoes/brown(src)
new /obj/item/clothing/head/det(src)
new /obj/item/clothing/head/det/grey(src)
new /obj/item/clothing/shoes/laceup(src)
new /obj/item/weapon/storage/box/evidence(src)
new /obj/item/device/radio/headset/headset_sec(src)
new /obj/item/clothing/suit/storage/vest/detective(src)
new /obj/item/clothing/suit/armor/vest/detective(src)
new /obj/item/ammo_magazine/c45m/rubber(src)
new /obj/item/ammo_magazine/c45m/rubber(src)
new /obj/item/taperoll/police(src)
@@ -307,7 +310,7 @@
/obj/structure/closet/secure_closet/courtroom
name = "courtroom locker"
req_access = list(access_court)
req_access = list(access_lawyer)
New()
..()
@@ -80,12 +80,15 @@
/obj/structure/closet/statue/toggle()
return
/obj/structure/closet/statue/bullet_act(var/obj/item/projectile/Proj)
health -= Proj.damage
/obj/structure/closet/statue/proc/check_health()
if(health <= 0)
for(var/mob/M in src)
shatter(M)
/obj/structure/closet/statue/bullet_act(var/obj/item/projectile/Proj)
health -= Proj.get_structure_damage()
check_health()
return
/obj/structure/closet/statue/attack_generic(var/mob/user, damage, attacktext, environment_smash)
@@ -93,23 +96,17 @@
for(var/mob/M in src)
shatter(M)
/obj/structure/closet/statue/blob_act()
/obj/structure/closet/statue/ex_act(severity)
for(var/mob/M in src)
shatter(M)
/obj/structure/closet/statue/meteorhit(obj/O as obj)
if(O.icon_state == "flaming")
for(var/mob/M in src)
M.meteorhit(O)
shatter(M)
M.ex_act(severity)
health -= 60 / severity
check_health()
/obj/structure/closet/statue/attackby(obj/item/I as obj, mob/user as mob)
health -= I.force
user.do_attack_animation(src)
visible_message("<span class='danger'>[user] strikes [src] with [I].</span>")
if(health <= 0)
for(var/mob/M in src)
shatter(M)
check_health()
/obj/structure/closet/statue/MouseDrop_T()
return
@@ -42,11 +42,11 @@
/obj/structure/closet/syndicate/nuclear/New()
..()
new /obj/item/ammo_magazine/a12mm(src)
new /obj/item/ammo_magazine/a12mm(src)
new /obj/item/ammo_magazine/a12mm(src)
new /obj/item/ammo_magazine/a12mm(src)
new /obj/item/ammo_magazine/a12mm(src)
new /obj/item/ammo_magazine/a10mm(src)
new /obj/item/ammo_magazine/a10mm(src)
new /obj/item/ammo_magazine/a10mm(src)
new /obj/item/ammo_magazine/a10mm(src)
new /obj/item/ammo_magazine/a10mm(src)
new /obj/item/weapon/storage/box/handcuffs(src)
new /obj/item/weapon/storage/box/flashbangs(src)
new /obj/item/weapon/gun/energy/gun(src)
@@ -22,7 +22,7 @@
/obj/structure/closet/emcloset/New()
..()
switch (pickweight(list("small" = 55, "aid" = 25, "tank" = 10, "both" = 10, "nothing" = 0, "delete" = 0)))
switch (pickweight(list("small" = 55, "aid" = 25, "tank" = 10, "both" = 10)))
if ("small")
new /obj/item/weapon/tank/emergency_oxygen(src)
new /obj/item/weapon/tank/emergency_oxygen(src)
@@ -51,17 +51,6 @@
new /obj/item/clothing/suit/space/emergency(src)
new /obj/item/clothing/head/helmet/space/emergency(src)
new /obj/item/clothing/head/helmet/space/emergency(src)
if ("nothing")
// doot
// teehee - Ah, tg coders...
if ("delete")
qdel(src)
//If you want to re-add fire, just add "fire" = 15 to the pick list.
/*if ("fire")
new /obj/structure/closet/firecloset(src.loc)
qdel(src)*/
/obj/structure/closet/emcloset/legacy/New()
..()
@@ -1,6 +1,6 @@
/obj/structure/closet/wardrobe
name = "wardrobe"
desc = "It's a storage unit for standard-issue Nanotrasen attire."
desc = "It's a storage unit for standard-issue attire."
icon_state = "blue"
icon_closed = "blue"
@@ -26,9 +26,9 @@
new /obj/item/clothing/head/beret/sec(src)
new /obj/item/clothing/head/beret/sec(src)
new /obj/item/clothing/head/beret/sec(src)
new /obj/item/clothing/head/beret/sec/alt(src)
new /obj/item/clothing/head/beret/sec/alt(src)
new /obj/item/clothing/head/beret/sec/alt(src)
new /obj/item/clothing/head/beret/sec/corporate/officer(src)
new /obj/item/clothing/head/beret/sec/corporate/officer(src)
new /obj/item/clothing/head/beret/sec/corporate/officer(src)
return
@@ -68,7 +68,7 @@
/obj/structure/closet/wardrobe/chaplain_black
name = "chapel wardrobe"
desc = "It's a storage unit for Nanotrasen-approved religious attire."
desc = "It's a storage unit for approved religious attire."
icon_state = "black"
icon_closed = "black"
@@ -85,6 +85,7 @@
new /obj/item/weapon/storage/backpack/cultpack (src)
new /obj/item/weapon/storage/fancy/candle_box(src)
new /obj/item/weapon/storage/fancy/candle_box(src)
new /obj/item/weapon/deck/tarot(src)
return
@@ -120,7 +121,7 @@
/obj/structure/closet/wardrobe/orange
name = "prison wardrobe"
desc = "It's a storage unit for Nanotrasen-regulation prisoner attire."
desc = "It's a storage unit for regulation prisoner attire."
icon_state = "orange"
icon_closed = "orange"
@@ -167,9 +168,9 @@
new /obj/item/clothing/head/hardhat/red(src)
new /obj/item/clothing/head/hardhat/red(src)
new /obj/item/clothing/head/hardhat/red(src)
new /obj/item/clothing/head/beret/eng(src)
new /obj/item/clothing/head/beret/eng(src)
new /obj/item/clothing/head/beret/eng(src)
new /obj/item/clothing/head/beret/engineering(src)
new /obj/item/clothing/head/beret/engineering(src)
new /obj/item/clothing/head/beret/engineering(src)
return
@@ -190,9 +191,9 @@
new /obj/item/clothing/head/hardhat(src)
new /obj/item/clothing/head/hardhat(src)
new /obj/item/clothing/head/hardhat(src)
new /obj/item/clothing/head/beret/eng(src)
new /obj/item/clothing/head/beret/eng(src)
new /obj/item/clothing/head/beret/eng(src)
new /obj/item/clothing/head/beret/engineering(src)
new /obj/item/clothing/head/beret/engineering(src)
new /obj/item/clothing/head/beret/engineering(src)
return
@@ -69,20 +69,7 @@
/obj/structure/closet/crate/attackby(obj/item/weapon/W as obj, mob/user as mob)
if(opened)
if(isrobot(user))
return
if(W.loc != user) // This should stop mounted modules ending up outside the module.
return
if(W.abstract) //Prevents 'abstract' items (such as grabs) from creeping into the material realm.
if(istype(W, /obj/item/weapon/grab))
var/obj/item/weapon/grab/G = W
user << "<span class='notice'>[G.affecting] just doesn't fit!</span>"
else
user << "<span class='notice'>[W] does not belong there!</span>"
return
user.drop_item()
if(W)
W.forceMove(src.loc)
return ..()
else if(istype(W, /obj/item/weapon/packageWrap))
return
else if(istype(W, /obj/item/stack/cable_coil))
@@ -199,7 +186,15 @@
/obj/structure/closet/crate/secure/attackby(obj/item/weapon/W as obj, mob/user as mob)
if(is_type_in_list(W, list(/obj/item/weapon/packageWrap, /obj/item/stack/cable_coil, /obj/item/device/radio/electropack, /obj/item/weapon/wirecutters)))
return ..()
if(locked && (istype(W, /obj/item/weapon/card/emag)||istype(W, /obj/item/weapon/melee/energy/blade)))
if(istype(W, /obj/item/weapon/melee/energy/blade))
emag_act(INFINITY, user)
if(!opened)
src.togglelock(user)
return
return ..()
/obj/structure/closet/crate/secure/emag_act(var/remaining_charges, var/mob/user)
if(!broken)
overlays.Cut()
overlays += emag
overlays += sparks
@@ -208,11 +203,7 @@
src.locked = 0
src.broken = 1
user << "<span class='notice'>You unlock \the [src].</span>"
return
if(!opened)
src.togglelock(user)
return
return ..()
return 1
/obj/structure/closet/crate/secure/emp_act(severity)
for(var/obj/O in src)
@@ -234,7 +225,7 @@
open()
else
src.req_access = list()
src.req_access += pick(get_all_accesses())
src.req_access += pick(get_all_station_access())
..()
/obj/structure/closet/crate/plastic
@@ -13,8 +13,8 @@
if(istype(W, /obj/item/weapon/crowbar))
new /obj/item/stack/material/wood(src)
var/turf/T = get_turf(src)
for(var/atom/movable/M in contents)
M.forceMove(T)
for(var/atom/movable/AM in contents)
if(AM.simulated) AM.forceMove(T)
user.visible_message("<span class='notice'>[user] pries \the [src] open.</span>", \
"<span class='notice'>You pry open \the [src].</span>", \
"<span class='notice'>You hear splitting wood.</span>")