Files
CHOMPStation2/code/modules/admin/secrets/fun_secrets/ghost_mode.dm
Neerti 12abb2d6f2 Ports a large chunk of the map datum system that europa/bay uses.
Links many map-specific details such as the station name, z-level information, and allowed jobs from global vars to map datum vars, which should help us maintain multiple maps at once in the future, which will be needed for the future Southern Cross.
Note that a config change will be needed to change GENERATE_ASTEROID to GENERATE_MAP, otherwise no changes should be required to continue normal map usage.
To change to a different map, it's suggested to tick the file that ticks all the other needed files, which for the Northern Star is called northern_star.dm.
2017-02-27 07:36:41 -05:00

49 lines
1.6 KiB
Plaintext

/datum/admin_secret_item/fun_secret/ghost_mode
name = "Ghost Mode"
var/list/affected_mobs
/datum/admin_secret_item/fun_secret/ghost_mode/New()
..()
affected_mobs = list()
/datum/admin_secret_item/fun_secret/ghost_mode/execute(var/mob/user)
. = ..()
if(!.)
return
var/list/affected_areas = list()
for(var/mob/M in living_mob_list)
if(M.stat == CONSCIOUS && !(M in affected_mobs))
affected_mobs |= M
switch(rand(1,4))
if(1)
M.show_message(text("<span class='notice'>You shudder as if cold...</span>"), 1)
if(2)
M.show_message(text("<span class='notice'>You feel something gliding across your back...</span>"), 1)
if(3)
M.show_message(text("<span class='notice'>Your eyes twitch, you feel like something you can't see is here...</span>"), 1)
if(4)
M.show_message(text("<span class='notice'>You notice something moving out of the corner of your eye, but nothing is there...</span>"), 1)
for(var/obj/W in orange(5,M))
if(prob(25) && !W.anchored)
step_rand(W)
var/area/A = get_area(M)
if(A.requires_power && !A.always_unpowered && A.power_light && (A.z in using_map.player_levels))
affected_areas |= get_area(M)
affected_mobs |= user
for(var/area/AffectedArea in affected_areas)
AffectedArea.power_light = 0
AffectedArea.power_change()
spawn(rand(25,50))
AffectedArea.power_light = 1
AffectedArea.power_change()
sleep(100)
for(var/mob/M in affected_mobs)
M.show_message(text("<span class='notice'>The chilling wind suddenly stops...</span>"), 1)
affected_mobs.Cut()
affected_areas.Cut()