mirror of
https://github.com/PolarisSS13/Polaris.git
synced 2025-12-18 14:12:20 +00:00
Bugfix: Fixed issues with custom item camera sprites
icond/obj/custom_items.dmi: renamed off sprite for blue camera code/modules/paperwork/photography.dm: made cameras use variables item_on and item_off for sprites so that other types of cameras (i.e. custom ones) can use their own sprites without getting messed. /code/modules/customitems/item_defines.dm: set sprites for custom cameras "orange camera" and "old camera" to use item_on and item_off sprites in custom_items.dmi so that they had the correct sprites
This commit is contained in:
@@ -200,6 +200,8 @@ hi
|
||||
icon = 'custom_items.dmi'
|
||||
desc = "A modified detective's camera, painted in bright orange. On the back you see \"Have fun\" written in small accurate letters with something black."
|
||||
icon_state = "orangecamera"
|
||||
icon_on = "orangecamera"
|
||||
icon_off = "camera_off"
|
||||
pictures_left = 30
|
||||
|
||||
/obj/item/device/camera/fluff/oldcamera //magmaram: Maria Crash
|
||||
@@ -207,6 +209,8 @@ hi
|
||||
icon = 'custom_items.dmi'
|
||||
desc = "An old, slightly beat-up digital camera, with a cheap photo printer taped on. It's a nice shade of blue."
|
||||
icon_state = "oldcamera"
|
||||
icon_on = "oldcamera"
|
||||
icon_off = "oldcamera_off"
|
||||
pictures_left = 30
|
||||
|
||||
/obj/item/weapon/card/id/fluff/lifetime //fastler: Fastler Greay; it seemed like something multiple people would have
|
||||
|
||||
@@ -122,6 +122,8 @@
|
||||
var/pictures_max = 10
|
||||
var/pictures_left = 10
|
||||
var/on = 1
|
||||
var/icon_on = "camera"
|
||||
var/icon_off = "camera_off"
|
||||
|
||||
|
||||
/obj/item/device/camera/attack(mob/living/carbon/human/M as mob, mob/user as mob)
|
||||
@@ -130,9 +132,9 @@
|
||||
/obj/item/device/camera/attack_self(mob/user as mob)
|
||||
on = !on
|
||||
if(on)
|
||||
src.icon_state = "camera"
|
||||
src.icon_state = icon_on
|
||||
else
|
||||
src.icon_state = "camera_off"
|
||||
src.icon_state = icon_off
|
||||
user << "You switch the camera [on ? "on" : "off"]."
|
||||
return
|
||||
|
||||
@@ -253,8 +255,8 @@
|
||||
pictures_left--
|
||||
desc = "A polaroid camera. It has [pictures_left] photos left."
|
||||
user << "<span class='notice'>[pictures_left] photos left.</span>"
|
||||
icon_state = "camera_off"
|
||||
icon_state = icon_off
|
||||
on = 0
|
||||
spawn(64)
|
||||
icon_state = "camera"
|
||||
icon_state = icon_on
|
||||
on = 1
|
||||
Binary file not shown.
|
Before Width: | Height: | Size: 41 KiB After Width: | Height: | Size: 41 KiB |
Reference in New Issue
Block a user