Added cult major loss if Narsie is destroyed. (#48251)

* Added cult major loss if Narsie is destroyed.

* Minor corrections.

* Why did this compile?

* Minor fixes.

* Not bool

* Changed to defines as requested
This commit is contained in:
Buggy123
2020-01-14 18:22:49 -05:00
committed by moo
parent 16dc544919
commit 5efd5df30d
4 changed files with 73 additions and 13 deletions
+1
View File
@@ -11,3 +11,4 @@
#define CINEMATIC_NUKE_FAR 11
#define CINEMATIC_NUKE_CLOWNOP 12
#define CINEMATIC_CULT_NUKE 13
#define CINEMATIC_CULT_FAIL 14
+14
View File
@@ -203,6 +203,20 @@
special()
screen.icon_state = "summary_cult"
/datum/cinematic/cult_fail
id = CINEMATIC_CULT_FAIL
/datum/cinematic/cult_fail/content()
screen.icon_state = "station_intact"
sleep(20)
cinematic_sound(sound('sound/creatures/narsie_rises.ogg'))
sleep(60)
cinematic_sound(sound('sound/effects/explosion_distant.ogg'))
sleep(10)
cinematic_sound(sound('sound/magic/demon_dies.ogg'))
sleep(30)
special()
/datum/cinematic/nuke_annihilation
id = CINEMATIC_ANNIHILATION
+15 -4
View File
@@ -1,4 +1,7 @@
#define SUMMON_POSSIBILITIES 3
#define CULT_VICTORY 1
#define CULT_LOSS 0
#define CULT_NARSIE_KILLED -1
/datum/antagonist/cult
name = "Cultist"
@@ -351,6 +354,7 @@
/datum/objective/eldergod
var/summoned = FALSE
var/killed = FALSE
var/list/summon_spots = list()
/datum/objective/eldergod/New()
@@ -367,18 +371,25 @@
explanation_text = "Summon Nar'Sie by invoking the rune 'Summon Nar'Sie'. <b>The summoning can only be accomplished in [english_list(summon_spots)] - where the veil is weak enough for the ritual to begin.</b>"
/datum/objective/eldergod/check_completion()
if(killed)
return CULT_NARSIE_KILLED // You failed so hard that even the code went backwards.
return summoned || completed
/datum/team/cult/proc/check_cult_victory()
for(var/datum/objective/O in objectives)
if(!O.check_completion())
return FALSE
return TRUE
if(O.check_completion() == CULT_NARSIE_KILLED)
return CULT_NARSIE_KILLED
else if(!O.check_completion())
return CULT_LOSS
return CULT_VICTORY
/datum/team/cult/roundend_report()
var/list/parts = list()
var/victory = check_cult_victory()
if(check_cult_victory())
if(victory == CULT_NARSIE_KILLED) // Epic failure, you summoned your god and then someone killed it.
parts += "<span class='redtext big'>Nar'sie has been killed! The cult will haunt the universe no longer!</span>"
else if(victory)
parts += "<span class='greentext big'>The cult has succeeded! Nar'Sie has snuffed out another torch in the void!</span>"
else
parts += "<span class='redtext big'>The staff managed to stop the cult! Dark words and heresy are no match for Nanotrasen's finest!</span>"
+43 -9
View File
@@ -66,34 +66,68 @@
if(player.stat != DEAD && player.loc && is_station_level(player.loc.z) && !iscultist(player) && !isanimal(player))
souls_needed[player] = TRUE
soul_goal = round(1 + LAZYLEN(souls_needed) * 0.75)
INVOKE_ASYNC(src, .proc/begin_the_end)
INVOKE_ASYNC(GLOBAL_PROC, .proc/begin_the_end)
/obj/singularity/narsie/large/cult/proc/begin_the_end()
/proc/begin_the_end()
sleep(50)
if(QDELETED(GLOB.cult_narsie)) // uno
priority_announce("Status report? We detected a anomaly, but it disappeared almost immediately.","Central Command Higher Dimensional Affairs", 'sound/misc/notice1.ogg')
GLOB.cult_narsie = null
sleep(20)
INVOKE_ASYNC(GLOBAL_PROC, .proc/cult_ending_helper, 2)
return
priority_announce("An acausal dimensional event has been detected in your sector. Event has been flagged EXTINCTION-CLASS. Directing all available assets toward simulating solutions. SOLUTION ETA: 60 SECONDS.","Central Command Higher Dimensional Affairs", 'sound/misc/airraid.ogg')
sleep(500)
if(QDELETED(GLOB.cult_narsie)) // dos
priority_announce("Simulations aborted, sensors report that the acasual event is normalizing. Good work, crew.","Central Command Higher Dimensional Affairs", 'sound/misc/notice1.ogg')
GLOB.cult_narsie = null
sleep(20)
INVOKE_ASYNC(GLOBAL_PROC, .proc/cult_ending_helper, 2)
return
priority_announce("Simulations on acausal dimensional event complete. Deploying solution package now. Deployment ETA: ONE MINUTE. ","Central Command Higher Dimensional Affairs")
sleep(50)
set_security_level("delta")
SSshuttle.registerHostileEnvironment(src)
SSshuttle.registerHostileEnvironment(GLOB.cult_narsie)
SSshuttle.lockdown = TRUE
sleep(600)
if(resolved == FALSE)
resolved = TRUE
if(QDELETED(GLOB.cult_narsie)) // tres
priority_announce("Normalization detected! Abort the solution package!","Central Command Higher Dimensional Affairs", 'sound/misc/notice1.ogg')
GLOB.cult_narsie = null
sleep(20)
set_security_level("red")
SSshuttle.clearHostileEnvironment()
SSshuttle.lockdown = FALSE
INVOKE_ASYNC(GLOBAL_PROC, .proc/cult_ending_helper, 2)
return
if(GLOB.cult_narsie.resolved == FALSE)
GLOB.cult_narsie.resolved = TRUE
sound_to_playing_players('sound/machines/alarm.ogg')
addtimer(CALLBACK(GLOBAL_PROC, .proc/cult_ending_helper), 120)
/obj/singularity/narsie/large/cult/Destroy()
GLOB.cult_narsie = null
send_to_playing_players("<span class='narsie'>\"<b>[pick("Nooooo...", "Not die. How-", "Die. Mort-", "Sas tyen re-")]\"</b></span>")
sound_to_playing_players('sound/magic/demon_dies.ogg', 50)
var/list/all_cults = list()
for(var/datum/antagonist/cult/C in GLOB.antagonists)
if(!C.owner)
continue
all_cults |= C.cult_team
for(var/datum/team/cult/T in all_cults)
var/datum/objective/eldergod/summon_objective = locate() in T.objectives
if(summon_objective)
summon_objective.summoned = FALSE
summon_objective.killed = TRUE
return ..()
/proc/ending_helper()
SSticker.force_ending = 1
/proc/cult_ending_helper(var/no_explosion = 0)
if(no_explosion)
/proc/cult_ending_helper(var/ending_type = 0)
if(ending_type == 2) //narsie fukkin died
Cinematic(CINEMATIC_CULT_FAIL,world,CALLBACK(GLOBAL_PROC,/proc/ending_helper))
else if(ending_type) //no explosion
Cinematic(CINEMATIC_CULT,world,CALLBACK(GLOBAL_PROC,/proc/ending_helper))
else
else // explosion
Cinematic(CINEMATIC_CULT_NUKE,world,CALLBACK(GLOBAL_PROC,/proc/ending_helper))
//ATTACK GHOST IGNORING PARENT RETURN VALUE