diff --git a/aurorastation.dme b/aurorastation.dme index 807fb631331..60cf443be2e 100644 --- a/aurorastation.dme +++ b/aurorastation.dme @@ -748,6 +748,7 @@ #include "code\game\machinery\seed_extractor.dm" #include "code\game\machinery\Sleeper.dm" #include "code\game\machinery\spaceheater.dm" +#include "code\game\machinery\stargazer.dm" #include "code\game\machinery\stasis_bed.dm" #include "code\game\machinery\station_holomap.dm" #include "code\game\machinery\status_display.dm" diff --git a/code/controllers/subsystems/job.dm b/code/controllers/subsystems/job.dm index c95cd5495c0..e3db88722df 100644 --- a/code/controllers/subsystems/job.dm +++ b/code/controllers/subsystems/job.dm @@ -310,9 +310,7 @@ Debug("ER/([H]): Entry, joined_late=[joined_late],megavend=[megavend].") if(SSatlas.current_sector.description) - var/sector_desc = "
Current Sector: [SSatlas.current_sector.name]!
" - sector_desc += "[SSatlas.current_sector.description]
" - to_chat(H, sector_desc) + to_chat(H, SSatlas.current_sector.get_chat_description()) var/datum/job/job = GetJob(rank) var/list/spawn_in_storage = list() diff --git a/code/game/machinery/stargazer.dm b/code/game/machinery/stargazer.dm new file mode 100644 index 00000000000..2fc5c267e19 --- /dev/null +++ b/code/game/machinery/stargazer.dm @@ -0,0 +1,44 @@ +/obj/machinery/stargazer + name = "stargazer system" + icon = 'icons/obj/machines/stargazer.dmi' + icon_state = "stargazer_off" + layer = ABOVE_ALL_MOB_LAYER + pixel_x = -32 + pixel_y = -32 + var/image/star_system_image + +/obj/machinery/stargazer/Initialize(mapload, d, populate_components) + . = ..() + star_system_image = image(icon, null, "stargazer_[SSatlas.current_sector.name]", EFFECTS_ABOVE_LIGHTING_LAYER) + power_change() + +/obj/machinery/stargazer/examine(mob/user) + . = ..() + if(!(stat & BROKEN) && !(stat & NOPOWER)) + to_chat(user, SPAN_NOTICE("\The [src] shows the current sector to be [SSatlas.current_sector.name].")) + +/obj/machinery/stargazer/power_change() + ..() + if(stat & BROKEN) + icon_state = "stargazer_off" + cut_overlays() + set_light(0) + else if(!(stat & NOPOWER)) + icon_state = "stargazer_on" + add_overlay(star_system_image) + set_light(6, 2, LIGHT_COLOR_BLUE) + else + icon_state = "stargazer_off" + cut_overlays() + set_light(0) + +/obj/machinery/stargazer/Topic(href, href_list, datum/topic_state/state) + if((stat & BROKEN) || (stat & NOPOWER)) + return TRUE + if(!isInSight(usr, src)) + return TRUE + if(usr.incapacitated(INCAPACITATION_KNOCKOUT)) + return TRUE + + if(href_list["examine"]) + to_chat(usr, SSatlas.current_sector.get_chat_description()) diff --git a/code/modules/background/space_sectors/space_sector.dm b/code/modules/background/space_sectors/space_sector.dm index 658b620d42a..e204eef94c1 100644 --- a/code/modules/background/space_sectors/space_sector.dm +++ b/code/modules/background/space_sectors/space_sector.dm @@ -5,3 +5,6 @@ var/list/possible_exoplanets = list() var/list/cargo_price_coef = list("nt" = 1, "hpi" = 1, "zhu" = 1, "een" = 1, "get" = 1, "arz" = 1, "blm" = 1, "iac" = 1, "zsc" = 1, "vfc" = 1, "bis" = 1, "xmg" = 1, "npi" = 1) //how much the space sector afffects how expensive is ordering from that cargo supplier + +/datum/space_sector/proc/get_chat_description() + return "
Current Sector: [name]!
[description]
" diff --git a/icons/obj/machines/stargazer.dmi b/icons/obj/machines/stargazer.dmi index 16181cc8e32..d20a61685ae 100644 Binary files a/icons/obj/machines/stargazer.dmi and b/icons/obj/machines/stargazer.dmi differ