Merge pull request #3356 from Citadel-Station-13/upstream-merge-31565

[MIRROR] Stargazers are now station-restricted, and cogged APCs are now quiet
This commit is contained in:
LetterJay
2017-10-13 00:20:54 -04:00
committed by GitHub
4 changed files with 12 additions and 4 deletions

View File

@@ -450,7 +450,7 @@ GLOBAL_LIST_EMPTY(teleportlocs)
if(!L.client.played)
SEND_SOUND(L, sound(sound, repeat = 0, wait = 0, volume = 25, channel = CHANNEL_AMBIENCE))
L.client.played = TRUE
addtimer(CALLBACK(L.client, /client/proc/ResetAmbiencePlayed), 600)
addtimer(CALLBACK(L.client, /client/proc/ResetAmbiencePlayed), 600)
/client/proc/ResetAmbiencePlayed()
played = FALSE

View File

@@ -31,8 +31,5 @@
if(cell && (cell.charge / cell.maxcharge > COG_MAX_SIPHON_THRESHOLD))
cell.use(1)
adjust_clockwork_power(1) //Power is shared, so only do it once; this runs very quickly so it's about 1W/second
if(prob(1))
playsound(apc, 'sound/machines/clockcult/steam_whoosh.ogg', 10, TRUE)
new/obj/effect/temp_visual/steam(get_turf(apc), pick(GLOB.cardinals))
#undef COG_MAX_SIPHON_THRESHOLD

View File

@@ -231,6 +231,13 @@
quickbind = TRUE
quickbind_desc = "Creates a stargazer, which generates power when near starlight."
/datum/clockwork_scripture/create_object/stargazer/check_special_requirements()
var/area/A = get_area(invoker)
if(A.outdoors || A.map_name == "Space" || !A.blob_allowed)
to_chat(invoker, "<span class='danger'>Stargazers can't be built off-station.</span>")
return
return TRUE
//Integration Cog: Creates an integration cog that can be inserted into APCs to passively siphon power.
/datum/clockwork_scripture/create_object/integration_cog

View File

@@ -50,6 +50,10 @@
if(isspaceturf(T))
has_starlight = TRUE
break
if(has_starlight && anchored)
var/area/A = get_area(src)
if(A.outdoors || A.map_name == "Space" || !A.blob_allowed)
has_starlight = FALSE
if(old_status != has_starlight)
if(has_starlight)
visible_message("<span class='nzcrentr_small'>[src] hums and shines brilliantly!</span>")