diff --git a/code/defines/obj.dm b/code/defines/obj.dm index 41415499d6b..9784158ebe8 100644 --- a/code/defines/obj.dm +++ b/code/defines/obj.dm @@ -330,12 +330,25 @@ desc = "A hand-held emergency light." icon_state = "flight0" var/on = 0 + var/brightness_on = 4 //luminosity when on + var/icon_on = "flight1" + var/icon_off = "flight0" w_class = 2 item_state = "flight" flags = FPRINT | ONBELT | TABLEPASS | CONDUCT m_amt = 50 g_amt = 20 +/obj/item/device/flashlight/pen + name = "penlight" + desc = "A pen-sized light." + icon_state = "plight0" + flags = FPRINT | TABLEPASS | CONDUCT + item_state = "" + icon_on = "plight1" + icon_off = "plight0" + brightness_on = 3 + /obj/item/device/healthanalyzer name = "Health Analyzer" icon_state = "health" diff --git a/code/defines/obj/clothing.dm b/code/defines/obj/clothing.dm index 800451c4947..35f08c96042 100644 --- a/code/defines/obj/clothing.dm +++ b/code/defines/obj/clothing.dm @@ -286,6 +286,7 @@ icon_state = "hardhat0" flags = FPRINT | TABLEPASS | SUITSPACE item_state = "hardhat0" + var/brightness_on = 4 //luminosity when on var/on = 0 @@ -540,7 +541,7 @@ body_parts_covered = UPPER_TORSO|LOWER_TORSO|ARMS permeability_coefficient = 0.25 heat_transfer_coefficient = 0.75 - allowed = list(/obj/item/device/analyzer,/obj/item/weapon/medical,/obj/item/weapon/dnainjector,/obj/item/weapon/reagent_containers/dropper,/obj/item/weapon/reagent_containers/syringe,/obj/item/weapon/reagent_containers/hypospray,/obj/item/device/healthanalyzer) + allowed = list(/obj/item/device/analyzer,/obj/item/weapon/medical,/obj/item/weapon/dnainjector,/obj/item/weapon/reagent_containers/dropper,/obj/item/weapon/reagent_containers/syringe,/obj/item/weapon/reagent_containers/hypospray,/obj/item/device/healthanalyzer,/obj/item/device/flashlight/pen) /obj/item/clothing/suit/labcoat/cmo name = "chief medical officer's labcoat" diff --git a/code/game/jobs/jobprocs.dm b/code/game/jobs/jobprocs.dm index ae363b840b4..ce79b1b39be 100644 --- a/code/game/jobs/jobprocs.dm +++ b/code/game/jobs/jobprocs.dm @@ -315,6 +315,7 @@ src.equip_if_possible(new /obj/item/clothing/under/rank/geneticist(src), slot_w_uniform) src.equip_if_possible(new /obj/item/clothing/shoes/white(src), slot_shoes) src.equip_if_possible(new /obj/item/clothing/suit/labcoat(src), slot_wear_suit) + src.equip_if_possible(new /obj/item/device/flashlight/pen(src), slot_r_store) if ("Chemist") src.equip_if_possible(new /obj/item/device/radio/headset/headset_med (src), slot_ears) // -- TLE @@ -392,6 +393,7 @@ src.equip_if_possible(new /obj/item/clothing/shoes/white(src), slot_shoes) src.equip_if_possible(new /obj/item/clothing/suit/labcoat(src), slot_wear_suit) src.equip_if_possible(new /obj/item/weapon/storage/firstaid/regular(src), slot_l_hand) + src.equip_if_possible(new /obj/item/device/flashlight/pen(src), slot_r_store) if ("Captain") src.equip_if_possible(new /obj/item/device/radio/headset/headset_com (src), slot_ears) // -- TLE @@ -567,6 +569,7 @@ src.equip_if_possible(new /obj/item/clothing/suit/labcoat(src), slot_wear_suit) src.equip_if_possible(new /obj/item/weapon/pen(src), slot_l_hand) src.equip_if_possible(new /obj/item/weapon/clipboard(src), slot_r_hand) + src.equip_if_possible(new /obj/item/device/flashlight/pen(src), slot_r_store) if ("Chief Medical Officer") src.equip_if_possible(new /obj/item/device/radio/headset/headset_med (src), slot_ears) // -- TLE @@ -576,6 +579,7 @@ src.equip_if_possible(new /obj/item/clothing/under/rank/medical(src), slot_w_uniform) src.equip_if_possible(new /obj/item/clothing/suit/labcoat/cmo(src), slot_wear_suit) src.equip_if_possible(new /obj/item/weapon/storage/firstaid/regular(src), slot_l_hand) + src.equip_if_possible(new /obj/item/device/flashlight/pen(src), slot_r_store) if ("Virologist") src.equip_if_possible(new /obj/item/device/radio/headset/headset_med (src), slot_ears) // -- TLE @@ -584,6 +588,7 @@ src.equip_if_possible(new /obj/item/clothing/under/rank/medical(src), slot_w_uniform) src.equip_if_possible(new /obj/item/clothing/shoes/white(src), slot_shoes) src.equip_if_possible(new /obj/item/clothing/suit/labcoat(src), slot_wear_suit) + src.equip_if_possible(new /obj/item/device/flashlight/pen(src), slot_r_store) else src << "RUH ROH! Your job is [rank] and the game just can't handle it! Please report this bug to an administrator." diff --git a/code/game/objects/devices/flashlight.dm b/code/game/objects/devices/flashlight.dm index 0466bb63363..48ade1b45fd 100644 --- a/code/game/objects/devices/flashlight.dm +++ b/code/game/objects/devices/flashlight.dm @@ -1,13 +1,16 @@ -#define FLASHLIGHT_LUM 4 +//#define FLASHLIGHT_LUM 4 /obj/item/device/flashlight/attack_self(mob/user) on = !on - icon_state = "flight[on]" + if (on) + icon_state = icon_on + else + icon_state = icon_off if(on) - user.sd_SetLuminosity(user.luminosity + FLASHLIGHT_LUM) + user.sd_SetLuminosity(user.luminosity + brightness_on) else - user.sd_SetLuminosity(user.luminosity - FLASHLIGHT_LUM) + user.sd_SetLuminosity(user.luminosity - brightness_on) /obj/item/device/flashlight/attack(mob/M as mob, mob/user as mob) @@ -52,14 +55,14 @@ /obj/item/device/flashlight/pickup(mob/user) if(on) src.sd_SetLuminosity(0) - user.sd_SetLuminosity(user.luminosity + FLASHLIGHT_LUM) + user.sd_SetLuminosity(user.luminosity + brightness_on) /obj/item/device/flashlight/dropped(mob/user) if(on) - user.sd_SetLuminosity(user.luminosity - FLASHLIGHT_LUM) - src.sd_SetLuminosity(FLASHLIGHT_LUM) + user.sd_SetLuminosity(user.luminosity - brightness_on) + src.sd_SetLuminosity(brightness_on) /obj/item/clothing/head/helmet/hardhat/attack_self(mob/user) on = !on @@ -67,18 +70,18 @@ item_state = "hardhat[on]" if(on) - user.sd_SetLuminosity(user.luminosity + FLASHLIGHT_LUM) + user.sd_SetLuminosity(user.luminosity + brightness_on) else - user.sd_SetLuminosity(user.luminosity - FLASHLIGHT_LUM) + user.sd_SetLuminosity(user.luminosity - brightness_on) /obj/item/clothing/head/helmet/hardhat/pickup(mob/user) if(on) src.sd_SetLuminosity(0) - user.sd_SetLuminosity(user.luminosity + FLASHLIGHT_LUM) + user.sd_SetLuminosity(user.luminosity + brightness_on) /obj/item/clothing/head/helmet/hardhat/dropped(mob/user) if(on) - user.sd_SetLuminosity(user.luminosity - FLASHLIGHT_LUM) - src.sd_SetLuminosity(FLASHLIGHT_LUM) \ No newline at end of file + user.sd_SetLuminosity(user.luminosity - brightness_on) + src.sd_SetLuminosity(brightness_on) \ No newline at end of file diff --git a/icons/obj/device.dmi b/icons/obj/device.dmi index fcd10bf0a0a..818e8a1123d 100644 Binary files a/icons/obj/device.dmi and b/icons/obj/device.dmi differ diff --git a/maps/tgstation.2.0.0.dmm b/maps/tgstation.2.0.0.dmm index 4e4352c8e98..aa8c49103e7 100644 --- a/maps/tgstation.2.0.0.dmm +++ b/maps/tgstation.2.0.0.dmm @@ -3351,7 +3351,7 @@ "bmw" = (/obj/secure_closet/medical1,/turf/simulated/floor{icon_state = "white"},/area/medical/research) "bmx" = (/obj/closet/wardrobe/genetics_white,/turf/simulated/floor{icon_state = "white"},/area/medical/research) "bmy" = (/obj/table{dir = 9; icon_state = "tabledir"; pixel_y = 0},/obj/item/weapon/storage/diskbox,/obj/item/weapon/paper{info = "Angela, while it may appear that the lab monkeys are communicating with each other, I assure you it's quite impossible. You claim that one monkey signed the passcode for a supply closet to another and the latter proceeded to open it. As I'm sure you know, there have literally been tens of thousands of studies of primate intelligence and there is no evidence of behavior even remotely that sophisticated. So either you've single handedly trumped the entire field of animal behaviorists or you're badly in need of a vacation."; name = "re: Damn Chimps"},/turf/simulated/floor{icon_state = "white"},/area/medical/research) -"bmz" = (/obj/table{icon_state = "tabledir"; dir = 1},/obj/item/weapon/storage/diskbox,/turf/simulated/floor{icon_state = "white"},/area/medical/research) +"bmz" = (/obj/table{icon_state = "tabledir"; dir = 1},/obj/item/weapon/storage/diskbox,/obj/item/device/flashlight/pen,/turf/simulated/floor{icon_state = "white"},/area/medical/research) "bmA" = (/obj/machinery/atmospherics/pipe/simple,/turf/simulated/wall,/area/chapel/main) "bmB" = (/obj/machinery/light/small,/obj/machinery/atmospherics/unary/vent_pump{on = 1},/turf/simulated/floor{icon_state = "dark"},/area/chapel/main) "bmC" = (/obj/table{icon_state = "tabledir"; dir = 9},/turf/simulated/floor{icon_state = "dark"},/area/chapel/main)