fixes loadout photos not fitting in lockets and sweater underwear (#10188)

This commit is contained in:
Wowzewow (Wezzy)
2020-10-07 23:03:58 +02:00
committed by GitHub
parent 7a04e78cf5
commit 03e29eb265
6 changed files with 63 additions and 22 deletions
+12 -17
View File
@@ -25,10 +25,12 @@ var/global/photo_count = 0
/obj/item/photo
name = "photo"
desc = "An archaic means of visual preservation, kept alive as kitschy memorabilia by paparazzi, conspiracy theorists and teenage girls."
icon = 'icons/obj/bureaucracy.dmi'
icon_state = "photo"
item_state = "paper"
w_class = ITEMSIZE_SMALL
var/picture_desc // Who and/or what's in the picture.
var/id
var/icon/img //Big photo image
var/scribble //Scribble on the back.
@@ -52,11 +54,13 @@ var/global/photo_count = 0
..()
/obj/item/photo/examine(mob/user)
.=..()
if(in_range(user, src))
show(user)
to_chat(user, desc)
to_chat(user, "<span class='notice'>[picture_desc]</span>")
else
to_chat(user, "<span class='notice'>It is too far away.</span>")
to_chat(user, "<span class='notice'>You are too far away to discern its contents.</span>")
/obj/item/photo/proc/show(mob/user as mob)
send_rsc(user, img, "tmp_photo_[id].png")
@@ -65,7 +69,7 @@ var/global/photo_count = 0
return
/obj/item/photo/verb/rename()
set name = "Rename photo"
set name = "Rename Photo"
set category = "Object"
set src in usr
@@ -84,7 +88,7 @@ var/global/photo_count = 0
* photo album *
**************/
/obj/item/storage/photo_album
name = "Photo album"
name = "photo album"
icon = 'icons/obj/bureaucracy.dmi'
icon_state = "album"
item_state = "briefcase"
@@ -186,9 +190,9 @@ var/global/photo_count = 0
holding = "They are holding \a [A.r_hand]"
if(!mob_detail)
mob_detail = "You can see [A] on the photo[A:health < 75 ? " - [A] looks hurt":""].[holding ? " [holding]":"."]. "
mob_detail = "You can see [A] in the photo[A:health < 75 ? " - [A] looks hurt":""].[holding ? " [holding]":"."]. "
else
mob_detail += "You can also see [A] on the photo[A:health < 75 ? " - [A] looks hurt":""].[holding ? " [holding]":"."]."
mob_detail += "You can also see [A] in the photo[A:health < 75 ? " - [A] looks hurt":""].[holding ? " [holding]":"."]."
return mob_detail
/obj/item/device/camera/afterattack(atom/target as mob|obj|turf|area, mob/user as mob, flag)
@@ -248,7 +252,7 @@ var/global/photo_count = 0
p.icon = ic
p.tiny = pc
p.img = photoimage
p.desc = mobs
p.picture_desc = mobs
p.pixel_x = rand(-10, 10)
p.pixel_y = rand(-10, 10)
p.photo_size = size
@@ -267,7 +271,7 @@ var/global/photo_count = 0
p.icon = icon(icon, icon_state)
p.tiny = icon(tiny)
p.img = icon(img)
p.desc = desc
p.picture_desc = picture_desc
p.pixel_x = pixel_x
p.pixel_y = pixel_y
p.photo_size = photo_size
@@ -278,12 +282,3 @@ var/global/photo_count = 0
return p
/obj/item/generic_photo //this is just meant for the custom loadout, so people can rename and change the desc this to whatever they want
name = "photo"
desc = "A photo of some mundane situation."
icon = 'icons/obj/bureaucracy.dmi'
icon_state = "photo"
item_state = "paper"
w_class = ITEMSIZE_SMALL
drop_sound = 'sound/items/drop/paper.ogg'
pickup_sound = 'sound/items/pickup/paper.ogg'