mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-24 05:23:22 +01:00
Revenant Gameplay Enhancement (#11049)
This commit is contained in:
@@ -17,6 +17,13 @@
|
||||
var/spawn_index = 1 // used to add a numerical identifier to the revenant. increases by 1 per spawn
|
||||
var/has_fired = FALSE
|
||||
|
||||
var/first_rift_done = FALSE
|
||||
|
||||
/datum/ghostspawner/revenant/cant_spawn(mob/user)
|
||||
. = ..()
|
||||
if(!. && revenants.rifts_left <= 0)
|
||||
return "The final rift has been closed."
|
||||
|
||||
/datum/ghostspawner/revenant/spawn_mob(mob/user)
|
||||
var/turf/T = select_spawnlocation()
|
||||
var/mob/living/carbon/human/revenant/R
|
||||
@@ -34,8 +41,11 @@
|
||||
R.ckey = user.ckey
|
||||
|
||||
revenants.add_antagonist(R.mind, TRUE, TRUE, FALSE, TRUE, TRUE)
|
||||
if(R.client)
|
||||
to_chat(R, FONT_LARGE(SPAN_CULT("You can now speak with all revenants in the game world by using \"[R.client.prefs.language_prefixes[1]]rs\" before a message.")))
|
||||
if(!has_fired)
|
||||
INVOKE_ASYNC(src, .proc/play_ambience, R)
|
||||
INVOKE_ASYNC(src, .proc/check_rift)
|
||||
|
||||
return R
|
||||
|
||||
@@ -46,4 +56,30 @@
|
||||
continue
|
||||
M.playsound_simple(get_turf(M), 'sound/ambience/tension/tension.ogg', 75, FALSE)
|
||||
to_chat(M, FONT_LARGE(SPAN_CULT("A faint hum coming from the station walls fills your ears...")))
|
||||
has_fired = TRUE
|
||||
has_fired = TRUE
|
||||
|
||||
/datum/ghostspawner/revenant/proc/check_rift()
|
||||
if(revenants.revenant_rift || revenants.rifts_left <= 0)
|
||||
return
|
||||
var/kills_needed = ((initial(revenants.rifts_left) - revenants.rifts_left) + 1) * 5
|
||||
if(revenants.kill_count > kills_needed)
|
||||
var/turf/rift_turf
|
||||
var/list/possible_landmarks = list()
|
||||
for(var/thing in landmarks_list)
|
||||
var/obj/effect/landmark/landmark = thing
|
||||
if(landmark.name == "RevenantRift")
|
||||
possible_landmarks += landmark
|
||||
if(length(possible_landmarks))
|
||||
var/obj/effect/landmark/L = pick(possible_landmarks)
|
||||
rift_turf = get_turf(L)
|
||||
if(rift_turf)
|
||||
new /obj/effect/portal/revenant(rift_turf)
|
||||
if(!first_rift_done)
|
||||
command_announcement.Announce("Aurora, we're detecting energy signatures eerily similar to a bluespace rift breach inside your hull. [SScargo.shuttle ? "We're sending you a bluespace neutralizer via the cargo shuttle. " : ""]Locate the rift and shut it down.", "Bluespace Breach Alert")
|
||||
first_rift_done = TRUE
|
||||
if(SScargo.shuttle)
|
||||
var/turf/T = pick_area_turf(pick(SScargo.shuttle.shuttle_area), list(/proc/not_turf_contains_dense_objects))
|
||||
if(T)
|
||||
var/obj/structure/closet/crate/C = new /obj/structure/closet/crate(T)
|
||||
C.name += " (Neutralizer)"
|
||||
new /obj/item/bluespace_neutralizer(C)
|
||||
Reference in New Issue
Block a user