Skip to content

Commit

Permalink
Major cult changes
Browse files Browse the repository at this point in the history
The current code for runes is god-awful. Like, seriously terrible. This PR aims to fix that. Rather than having every rune effect defined in a single attack_hand proc, this PR will separate the runes into subtypes, which supports for more modular runes as well as cleans up the code.

It also separates invocation into a two different procs. The first of these will determine if the rune can be invoked; if that passes, the second will cause the rune's effects. There is also a third proc that will cause effects if the rune fails to invoke.

Research words have been removed, and all runes are now available from the start of the round. This is highly subject to change once some feedback is in from actual cult rounds.

Miscellaneous tweaks:

    Blood boil runes now explode when used
    Convert runes can now work solo, but take time
    Armor runes now only provide the basic armor set
    Tomes now do a static 15 burn damage and play a sound
    If the Escape objective is rolled, the amount of people that must escape will scale with the round population to a factor of 5 (i.e. 50 players = 10 cultists)
  • Loading branch information
Xhuis authored and optimumtact committed Sep 15, 2015
1 parent 73db851 commit 1178fbe
Show file tree
Hide file tree
Showing 23 changed files with 1,500 additions and 1,986 deletions.
79 changes: 7 additions & 72 deletions code/game/gamemodes/cult/cult.dm
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@

/datum/game_mode
var/list/datum/mind/cult = list()
var/list/allwords = list("travel","self","see","hell","blood","join","tech","destroy", "other", "hide")
var/list/grantwords = list("travel", "see", "hell", "tech", "destroy", "other", "hide")
var/list/cult_objectives = list()


Expand Down Expand Up @@ -54,9 +52,6 @@

var/finished = 0

var/list/startwords = list("blood","join","self","hell")
var/list/secondwords = list("travel", "see", "tech", "destroy", "other", "hide")

var/eldergod = 1 //for the summon god objective

var/acolytes_needed = 10 //for the survive objective
Expand Down Expand Up @@ -86,6 +81,7 @@
if(config.protect_assistant_from_antagonist)
restricted_jobs += "Assistant"

acolytes_needed = max(2, round(num_players()/5)) //Scales the escape requirement with the amount of people in the round

for(var/cultists_number = 1 to recommended_enemies)
if(!antag_candidates.len)
Expand Down Expand Up @@ -120,10 +116,8 @@

for(var/datum/mind/cult_mind in cult)
equip_cultist(cult_mind.current)
// grant_runeword(cult_mind.current)
// grant_secondword(cult_mind.current)
update_cult_icons_added(cult_mind)
cult_mind.current << "<span class='notice'>You are a member of the cult!</span>"
cult_mind.current << "<span class='userdanger'>You are a member of the cult!</span>"
memorize_cult_objectives(cult_mind)
..()

Expand All @@ -136,24 +130,18 @@
explanation = "Our knowledge must live on. Make sure at least [acolytes_needed] acolytes escape on the shuttle to spread their work on an another station."
if("sacrifice")
if(sacrifice_target)
explanation = "Sacrifice [sacrifice_target.name], the [sacrifice_target.assigned_role]. You will need the sacrifice rune (Hell blood join) and three acolytes to do so."
explanation = "Sacrifice [sacrifice_target.name], the [sacrifice_target.assigned_role]. You will need the Rite of Tribute and three acolytes to do so."
else
explanation = "Free objective."
if("eldergod")
explanation = "Summon Nar-Sie via the use of the appropriate rune (Hell join self). It will only work if nine cultists stand on and around it."
explanation = "Summon Nar-Sie via the use of the Ritual of Dimensional Rending. It will only work if nine cultists stand on and around it."
cult_mind.current << "<B>Objective #[obj_count]</B>: [explanation]"
cult_mind.memory += "<B>Objective #[obj_count]</B>: [explanation]<BR>"
cult_mind.current << "The Geometer of Blood grants you the knowledge to sacrifice non-believers. (Hell Blood Join)"
cult_mind.memory += "The Geometer of Blood grants you the knowledge to sacrifice non-believers. (Hell Blood Join)<BR>"
for(var/startingword in startwords)
grant_runeword(cult_mind.current,startingword)
// grant_runeword(cult_mind.current,"blood")
// grant_runeword(cult_mind.current,"hell")

/datum/game_mode/proc/equip_cultist(mob/living/carbon/human/mob)
if(!istype(mob))
return

mob.cult_add_comm()
if (mob.mind)
if (mob.mind.assigned_role == "Clown")
mob << "Your training has allowed you to overcome your clownish nature, allowing you to wield weapons without harming yourself."
Expand All @@ -169,10 +157,10 @@
"right hand" = slot_r_hand,
)
var/where = mob.equip_in_one_of_slots(T, slots)
if (!where)
if(!where)
mob << "Unfortunately, you weren't able to get a talisman. This is very bad and you should adminhelp immediately."
else
mob << "You have a talisman in your [where], one that will help you start the cult on this station. Use it well and remember - there are others."
mob << "You have a talisman in your [where], one that will help you start the cult on this station. Use it well, and remember - you are not the only one."
mob.update_icons()
if(where == "backpack")
var/obj/item/weapon/storage/B = mob.back
Expand All @@ -181,58 +169,6 @@
return 1


//datum/game_mode/cult/proc/grant_secondword(mob/living/carbon/human/cult_mob, var/word)
// if (!word)
// if(secondwords.len > 0)
// word=pick(secondwords)
// secondwords -= word
// grant_runeword(cult_mob,word)

//datum/game_mode/cult/grant_runeword(mob/living/carbon/human/cult_mob, var/word)
// if (!word)
// if(startwords.len > 0)
// word=pick(startwords)
// startwords -= word
// return ..(cult_mob,word)

/datum/game_mode/proc/grant_runeword(mob/living/carbon/human/cult_mob, word)
if(!wordtravel)
runerandom()
if (!word)
word=pick(grantwords)
var/wordexp
switch(word)
if("travel")
wordexp = "[wordtravel] is travel..."
if("blood")
wordexp = "[wordblood] is blood..."
if("join")
wordexp = "[wordjoin] is join..."
if("hell")
wordexp = "[wordhell] is Hell..."
if("self")
wordexp = "[wordself] is self..."
if("see")
wordexp = "[wordsee] is see..."
if("tech")
wordexp = "[wordtech] is technology..."
if("destroy")
wordexp = "[worddestr] is destroy..."
if("other")
wordexp = "[wordother] is other..."
// if("hear")
// wordexp = "[wordhear] is hear..."
// if("free")
// wordexp = "[wordfree] is free..."
if("hide")
wordexp = "[wordhide] is hide..."
cult_mob << "<span class='danger'>[pick("You remember something from the dark teachings of your master","You hear a dark voice on the wind","Black blood oozes into your vision and forms into symbols","You catch a brief glimmer of the otherside")]... [wordexp]</span>"
cult_mob.mind.store_memory("<B>You remember that</B> [wordexp]", 0, 0)
cult_mob.mind.cult_words += word
if(cult_mob.mind.cult_words.len == allwords.len)
cult_mob << "\green You feel enlightened, as if you have gained all the secrets of the other side."


/datum/game_mode/proc/add_cultist(datum/mind/cult_mind) //BASE
if (!istype(cult_mind))
return 0
Expand All @@ -258,7 +194,6 @@
cult_mind.current.Paralyse(5)
cult_mind.current << "<span class='userdanger'>An unfamiliar white light flashes through your mind, cleansing the taint of the dark-one and the memories of your time as his servant with it.</span>"
cult_mind.memory = ""
cult_mind.cult_words = initial(cult_mind.cult_words)
update_cult_icons_removed(cult_mind)
cult_mind.current.attack_log += "\[[time_stamp()]\] <span class='danger'>Has renounced the cult!</span>"
if(show_message)
Expand Down
72 changes: 40 additions & 32 deletions code/game/gamemodes/cult/cult_items.dm
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
/obj/item/weapon/melee/cultblade
name = "cult blade"
desc = "An arcane weapon wielded by the followers of Nar-Sie"
name = "eldritch longsword"
desc = "A sword humming with unholy energy. It glows with a dim red light."
icon_state = "cultblade"
item_state = "cultblade"
flags = CONDUCT
Expand All @@ -11,28 +11,31 @@
attack_verb = list("attacked", "slashed", "stabbed", "sliced", "torn", "ripped", "diced", "cut")



/obj/item/weapon/melee/cultblade/attack(mob/living/target, mob/living/carbon/human/user)
if(iscultist(user))
return ..()
else
user.Paralyse(5)
user << "<span class='danger'>An unexplicable force powerfully repels the sword from [target]!</span>"
var/organ = ((user.hand ? "l_":"r_") + "arm")
var/obj/item/organ/limb/affecting = user.get_organ(organ)
if(affecting.take_damage(rand(force/2, force))) //random amount of damage between half of the blade's force and the full force of the blade.
user.update_damage_overlays(0)
return
if(!iscultist(user))
user.Weaken(5)
user.visible_message("<span class='warning'>A powerful force shoves [user] away from [target]!</span>", \
"<span class='cult'>\"You shouldn't play with sharp things. You'll poke someone's eye out.\"</span>")
if(ishuman(user))
var/mob/living/carbon/human/H = user
H.apply_damage(rand(force/2, force), BRUTE, pick("l_arm", "r_arm"))
else
user.adjustBruteLoss(rand(force/2,force))
return
..()

/obj/item/weapon/melee/cultblade/pickup(mob/living/user)
if(!iscultist(user))
user << "<span class='danger'>An overwhelming feeling of dread comes over you as you pick up the cultist's sword. It would be wise to be rid of this blade quickly.</span>"
user << "<span class='cult'>\"I wouldn't advise that.\"</span>"
user << "<span class='warning'>An overwhelming sense of nausea overpowers you!</span>"
user.Dizzy(120)


/obj/item/clothing/head/culthood
name = "cult hood"
name = "ancient cultist hood"
icon_state = "culthood"
desc = "A hood worn by the followers of Nar-Sie."
desc = "A torn, dust-caked hood. Strange letters line the inside."
flags_inv = HIDEFACE
flags_cover = HEADCOVERSEYES
armor = list(melee = 30, bullet = 10, laser = 5,energy = 5, bomb = 0, bio = 0, rad = 0)
Expand All @@ -41,18 +44,9 @@
heat_protection = HEAD
max_heat_protection_temperature = HELMET_MAX_TEMP_PROTECT


/obj/item/clothing/head/culthood/alt
icon_state = "cult_hoodalt"
item_state = "cult_hoodalt"

/obj/item/clothing/suit/cultrobes/alt
icon_state = "cultrobesalt"
item_state = "cultrobesalt"

/obj/item/clothing/suit/cultrobes
name = "cult robes"
desc = "A set of armored robes worn by the followers of Nar-Sie"
name = "ancient cultist robes"
desc = "A ragged, dusty set of robes. Strange letters line the inside."
icon_state = "cultrobes"
item_state = "cultrobes"
body_parts_covered = CHEST|GROIN|LEGS|ARMS
Expand All @@ -64,6 +58,20 @@
heat_protection = CHEST|GROIN|LEGS|ARMS
max_heat_protection_temperature = ARMOR_MAX_TEMP_PROTECT


/obj/item/clothing/head/culthood/alt
name = "cultist hood"
desc = "An armored hood worn by the followers of Nar-Sie."
icon_state = "cult_hoodalt"
item_state = "cult_hoodalt"

/obj/item/clothing/suit/cultrobes/alt
name = "cultist hood"
desc = "An armored set of robes worn by the followers of Nar-Sie."
icon_state = "cultrobesalt"
item_state = "cultrobesalt"


/obj/item/clothing/head/magus
name = "magus helm"
icon_state = "magus"
Expand All @@ -86,18 +94,18 @@


/obj/item/clothing/head/helmet/space/cult
name = "cult helmet"
desc = "A space worthy helmet used by the followers of Nar-Sie"
name = "nar-sian bruiser's helmet"
desc = "A heavily-armored helmet worn by warriors of the Nar-Sian cult. It can withstand hard vacuum."
icon_state = "cult_helmet"
item_state = "cult_helmet"
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 30, bio = 30, rad = 30)

/obj/item/clothing/suit/space/cult
name = "cult armor"
name = "nar-sian bruiser's armor"
icon_state = "cult_armor"
item_state = "cult_armor"
desc = "A bulky suit of armor, bristling with spikes. It looks space proof."
desc = "A heavily-armored exosuit worn by warriors of the Nar-Sian cult. It can withstand hard vacuum."
w_class = 3
allowed = list(/obj/item/weapon/tome,/obj/item/weapon/melee/cultblade,/obj/item/weapon/tank/internals/emergency_oxygen)
allowed = list(/obj/item/weapon/tome,/obj/item/weapon/melee/cultblade,/obj/item/weapon/tank/internals/)
slowdown = 1
armor = list(melee = 60, bullet = 50, laser = 30,energy = 15, bomb = 30, bio = 30, rad = 30)
armor = list(melee = 70, bullet = 50, laser = 30,energy = 15, bomb = 30, bio = 30, rad = 30)
Loading

0 comments on commit 1178fbe

Please sign in to comment.