From d524b4acdeaa574f63503c8212184c5e7e94de84 Mon Sep 17 00:00:00 2001 From: Remie Richards Date: Sat, 24 Oct 2015 00:53:36 +0100 Subject: [PATCH] Adds a special camera that can see ghosts (if the ghost is orbiting something they are skipped, this is to prevent it being used for power/meta gaming) the Chaplain spawns with one and they can be tablecrafted using a camera and holywater --- code/game/jobs/job/civilian_chaplain.dm | 2 + code/modules/crafting/recipes.dm | 12 ++++- code/modules/paperwork/photography.dm | 67 +++++++++++++++++++------ 3 files changed, 66 insertions(+), 15 deletions(-) diff --git a/code/game/jobs/job/civilian_chaplain.dm b/code/game/jobs/job/civilian_chaplain.dm index 261193a8563..8821d603f0c 100644 --- a/code/game/jobs/job/civilian_chaplain.dm +++ b/code/game/jobs/job/civilian_chaplain.dm @@ -23,6 +23,8 @@ Chaplain belt = /obj/item/device/pda/chaplain uniform = /obj/item/clothing/under/rank/chaplain + backpack_contents = list(/obj/item/device/camera/spooky = 1) + /datum/outfit/job/chaplain/post_equip(mob/living/carbon/human/H) ..() diff --git a/code/modules/crafting/recipes.dm b/code/modules/crafting/recipes.dm index 2721f4f8ed3..c6833f2fa99 100644 --- a/code/modules/crafting/recipes.dm +++ b/code/modules/crafting/recipes.dm @@ -229,4 +229,14 @@ /obj/item/stack/packageWrap = 5,) tools = list(/obj/item/weapon/screwdriver) time = 200 - category = CAT_WEAPON \ No newline at end of file + category = CAT_WEAPON + + +/datum/table_recipe/spooky_camera + name = "Camera Obscura" + result = /obj/item/device/camera/spooky + time = 15 + reqs = list(/obj/item/device/camera = 1, + /datum/reagent/water/holywater = 10) + parts = list(/obj/item/device/camera = 1) + category = CAT_MISC diff --git a/code/modules/paperwork/photography.dm b/code/modules/paperwork/photography.dm index 835b33b40fb..d5c4ea284ce 100644 --- a/code/modules/paperwork/photography.dm +++ b/code/modules/paperwork/photography.dm @@ -114,6 +114,22 @@ var/on = 1 var/blueprints = 0 //are blueprints visible in the current photo being created? var/list/aipictures = list() //Allows for storage of pictures taken by AI, in a similar manner the datacore stores info. Keeping this here allows us to share some procs w/ regualar camera + var/see_ghosts = 0 //for the spoop of it + + +/obj/item/device/camera/CheckParts() + var/obj/item/device/camera/C = locate(/obj/item/device/camera) in contents + if(C) + pictures_max = C.pictures_max + pictures_left = C.pictures_left + visible_message("[C] has been imbued with godlike power!") + qdel(C) + + +/obj/item/device/camera/spooky + name = "camera obscura" + desc = "A polaroid camera, some say it can see ghosts!" + see_ghosts = 1 /obj/item/device/camera/siliconcam //camera AI can take pictures with @@ -163,7 +179,14 @@ for(var/turf/T in turfs) atoms.Add(T) for(var/atom/movable/A in T) - if(A.invisibility) continue + if(A.invisibility) + if(see_ghosts) + if(istype(A, /mob/dead/observer)) + var/mob/dead/observer/O = A + if(O.orbiting) //so you dont see ghosts following people like antags, etc. + continue + else + continue atoms.Add(A) var/list/sorted = list() @@ -202,21 +225,37 @@ /obj/item/device/camera/proc/camera_get_mobs(turf/the_turf) var/mob_detail - for(var/mob/living/A in the_turf) - if(A.invisibility) continue - var/holding = null - if(A.l_hand || A.r_hand) - if(A.l_hand) holding = "They are holding \a [A.l_hand]" - if(A.r_hand) - if(holding) - holding += " and \a [A.r_hand]" + for(var/mob/M in the_turf) + if(M.invisibility) + if(see_ghosts && istype(M,/mob/dead/observer)) + var/mob/dead/observer/O = M + if(O.orbiting) + continue + if(!mob_detail) + mob_detail = "You can see a g-g-g-g-ghooooost! " else - holding = "They are holding \a [A.r_hand]" + mob_detail += "You can also see a g-g-g-g-ghooooost!" + else + continue + + var/holding = null + + if(istype(M, /mob/living)) + var/mob/living/L = M + if(L.l_hand || L.r_hand) + if(L.l_hand) holding = "They are holding \a [L.l_hand]" + if(L.r_hand) + if(holding) + holding += " and \a [L.r_hand]" + else + holding = "They are holding \a [L.r_hand]" + + if(!mob_detail) + mob_detail = "You can see [L] on the photo[L.health < 75 ? " - [L] looks hurt":""].[holding ? " [holding]":"."]. " + else + mob_detail += "You can also see [L] on the photo[L.health < 75 ? " - [L] looks hurt":""].[holding ? " [holding]":"."]." + - if(!mob_detail) - mob_detail = "You can see [A] on 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]":"."]." return mob_detail