diff --git a/code/modules/paperwork/filingcabinet.dm b/code/modules/paperwork/filingcabinet.dm
index 00e839170ef..9c73fdd746c 100644
--- a/code/modules/paperwork/filingcabinet.dm
+++ b/code/modules/paperwork/filingcabinet.dm
@@ -21,18 +21,18 @@
/obj/structure/filingcabinet/initialize()
for(var/obj/item/I in loc)
- if(istype(I, /obj/item/weapon/paper) || istype(I, /obj/item/weapon/folder))
+ if(istype(I, /obj/item/weapon/paper) || istype(I, /obj/item/weapon/folder) || istype(I, /obj/item/weapon/photo))
I.loc = src
/obj/structure/filingcabinet/attackby(obj/item/P as obj, mob/user as mob)
- if(istype(P, /obj/item/weapon/paper) || istype(P, /obj/item/weapon/folder))
+ if(istype(P, /obj/item/weapon/paper) || istype(P, /obj/item/weapon/folder) || istype(P, /obj/item/weapon/photo))
user << "You put [P] in [src]."
user.drop_item()
P.loc = src
- spawn()
- icon_state = icon_open
- sleep(5)
- icon_state = icon_closed
+ icon_state = icon_open
+ sleep(5)
+ icon_state = icon_closed
+ updateUsrDialog()
else if(istype(P, /obj/item/weapon/wrench))
playsound(loc, 'sound/items/Ratchet.ogg', 50, 1)
anchored = !anchored
@@ -45,6 +45,7 @@
user << "\The [src] is empty."
return
+ user.machine = src
var/dat = "
"
var/i
for(i=contents.len, i>=1, i--)
@@ -61,12 +62,9 @@
//var/retrieveindex = text2num(href_list["retrieve"])
var/obj/item/P = locate(href_list["retrieve"])//contents[retrieveindex]
- if(!isnull(P) && in_range(src,usr))
- if(!usr.get_active_hand())
- usr.put_in_hands(P)
- else
- P.loc = get_turf_loc(src)
-
+ if(P && in_range(src, usr))
+ usr.put_in_hands(P)
+ updateUsrDialog()
icon_state = icon_open
sleep(5)
icon_state = icon_closed
diff --git a/code/modules/paperwork/folders.dm b/code/modules/paperwork/folders.dm
index 8bd85d7131d..1257f38a362 100644
--- a/code/modules/paperwork/folders.dm
+++ b/code/modules/paperwork/folders.dm
@@ -63,11 +63,7 @@
var/obj/item/P = locate(href_list["remove"])
if(P)
P.loc = usr.loc
- if(ishuman(usr))
- if(!usr.get_active_hand())
- usr.put_in_hands(P)
- else
- P.loc = get_turf(usr)
+ usr.put_in_hands(P)
if(href_list["read"])
var/obj/item/weapon/paper/P = locate(href_list["read"])
diff --git a/code/modules/paperwork/photocopier.dm b/code/modules/paperwork/photocopier.dm
index 2fc8faf6cb9..30dd502e9cf 100644
--- a/code/modules/paperwork/photocopier.dm
+++ b/code/modules/paperwork/photocopier.dm
@@ -11,6 +11,7 @@
active_power_usage = 200
power_channel = EQUIP
var/obj/item/weapon/paper/copy = null //what's in the copier!
+ var/obj/item/weapon/photo/photocopy = null
var/copies = 1 //how many copies to print!
var/toner = 30 //how much toner is left! woooooo~
var/maxcopies = 10 //how many copies can be copied at once- idea shamelessly stolen from bs12's copier!
@@ -25,7 +26,7 @@
user.machine = src
var/dat = "Photocopier
"
- if(copy)
+ if(copy || photocopy)
dat += "Remove Paper
"
if(toner)
dat += "Copy
"
@@ -64,15 +65,36 @@
else
break
updateUsrDialog()
+ else if(photocopy)
+ for(var/i = 0, i < copies, i++)
+ if(toner > 0)
+ var/obj/item/weapon/photo/p = new /obj/item/weapon/photo (src.loc)
+ var/icon/I = icon(photocopy.icon, photocopy.icon_state)
+ if(toner > 10) //plenty of toner, go straight greyscale
+ I.MapColors(rgb(77,77,77), rgb(150,150,150), rgb(28,28,28), rgb(0,0,0)) //I'm not sure how expensive this is, but given the many limitations of photocopying, it shouldn't be an issue.
+ else //not much toner left, lighten the photo
+ I.MapColors(rgb(77,77,77), rgb(150,150,150), rgb(28,28,28), rgb(100,100,100))
+ p.icon = I
+ p.name = photocopy.name
+ p.desc = photocopy.desc
+ toner -= 5 //photos use a lot of ink!
+ sleep(15)
+ else
+ break
+ updateUsrDialog()
else if(href_list["remove"])
if(copy)
- if(ishuman(usr))
- if(!usr.get_active_hand())
- copy.loc = usr.loc
- usr.put_in_hands(copy)
- usr << "You take the paper out of the photocopier."
- copy = null
- updateUsrDialog()
+ copy.loc = usr.loc
+ usr.put_in_hands(copy)
+ usr << "You take the paper out of \the [src]."
+ copy = null
+ updateUsrDialog()
+ else if(photocopy)
+ photocopy.loc = usr.loc
+ usr.put_in_hands(photocopy)
+ usr << "You take the photo out of \the [src]."
+ photocopy = null
+ updateUsrDialog()
else if(href_list["min"])
if(copies > 1)
copies--
@@ -84,7 +106,7 @@
attackby(obj/item/O as obj, mob/user as mob)
if(istype(O, /obj/item/weapon/paper))
- if(!copy)
+ if(!copy && !photocopy)
user.drop_item()
copy = O
O.loc = src
@@ -92,7 +114,17 @@
flick("bigscanner1", src)
updateUsrDialog()
else
- user << "There is already paper in \the [src]."
+ user << "There is already something in \the [src]."
+ else if(istype(O, /obj/item/weapon/photo))
+ if(!copy && !photocopy)
+ user.drop_item()
+ photocopy = O
+ O.loc = src
+ user << "You insert the photo into \the [src]."
+ flick("bigscanner1", src)
+ updateUsrDialog()
+ else
+ user << "There is already something in \the [src]."
else if(istype(O, /obj/item/device/toner))
if(toner == 0)
user.drop_item()
diff --git a/icons/obj/items.dmi b/icons/obj/items.dmi
index 59cf447ef84..235fe97b044 100644
Binary files a/icons/obj/items.dmi and b/icons/obj/items.dmi differ
diff --git a/icons/obj/vending.dmi b/icons/obj/vending.dmi
index 64c0e50d992..9acc0add649 100644
Binary files a/icons/obj/vending.dmi and b/icons/obj/vending.dmi differ