mirror of
https://github.com/ParadiseSS13/Paradise.git
synced 2026-08-25 04:57:12 +01:00
Merge pull request #4392 from Aurorablade/BookClub
Book Club Refactor/butchering
This commit is contained in:
@@ -240,17 +240,6 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
|
||||
if(mind.current.key && copytext(mind.current.key,1,2)!="@") //makes sure we don't accidentally kick any clients
|
||||
to_chat(usr, "<span class='warning'>Another consciousness is in your body...It is resisting you.</span>")
|
||||
return
|
||||
if(mind.current.ajourn && mind.current.stat != DEAD) //check if the corpse is astral-journeying (it's client ghosted using a cultist rune).
|
||||
var/turf/T = get_turf(mind.current)
|
||||
var/found_astral_rune = 0
|
||||
if(T)
|
||||
for(var/obj/effect/rune/R in T.contents) //whilst corpse is alive, we can only reenter the body if it's on the rune
|
||||
if(R.word1 == cultwords["hell"] && R.word2 == cultwords["travel"] && R.word3 == cultwords["self"]) //astral journeying rune
|
||||
found_astral_rune = 1
|
||||
break
|
||||
if(!found_astral_rune)
|
||||
to_chat(usr, "<span class='warning'>The astral cord that ties your body and your spirit has been severed. You are likely to wander the realm beyond until your body is finally dead and thus reunited with you.</span>")
|
||||
return
|
||||
|
||||
mind.current.ajourn=0
|
||||
mind.current.key = key
|
||||
|
||||
@@ -601,15 +601,6 @@ It'll return null if the organ doesn't correspond, so include null checks when u
|
||||
if(E.see_invisible)
|
||||
H.see_invisible = min(H.see_invisible, E.see_invisible)
|
||||
|
||||
|
||||
if(H.seer == 1)
|
||||
var/obj/effect/rune/R = locate() in H.loc
|
||||
if(R && R.word1 == cultwords["see"] && R.word2 == cultwords["hell"] && R.word3 == cultwords["join"])
|
||||
H.see_invisible = SEE_INVISIBLE_OBSERVER
|
||||
else
|
||||
H.see_invisible = SEE_INVISIBLE_LIVING
|
||||
H.seer = 0
|
||||
|
||||
var/lesser_darkview_bonus = INFINITY
|
||||
// my glasses, I can't see without my glasses
|
||||
if(H.glasses)
|
||||
|
||||
@@ -113,6 +113,7 @@
|
||||
handle_sleeping()
|
||||
handle_slowed()
|
||||
handle_drunk()
|
||||
handle_cultslurring()
|
||||
|
||||
|
||||
/mob/living/proc/handle_stunned()
|
||||
@@ -149,6 +150,11 @@
|
||||
AdjustSlur(-1)
|
||||
return slurring
|
||||
|
||||
/mob/living/proc/handle_cultslurring()
|
||||
if(cultslurring)
|
||||
AdjustCultSlur(-1)
|
||||
return cultslurring
|
||||
|
||||
/mob/living/proc/handle_paralysed()
|
||||
if(paralysis)
|
||||
AdjustParalysis(-1, updating = 1, force = 1)
|
||||
|
||||
@@ -675,7 +675,7 @@
|
||||
|
||||
/mob/living/narsie_act()
|
||||
if(client)
|
||||
makeNewConstruct(/mob/living/simple_animal/construct/harvester, src, null, 1)
|
||||
makeNewConstruct(/mob/living/simple_animal/hostile/construct/harvester, src, null, 1)
|
||||
spawn_dust()
|
||||
gib()
|
||||
return
|
||||
|
||||
@@ -79,7 +79,10 @@ proc/get_radio_key_from_channel(var/channel)
|
||||
message = stutter(message)
|
||||
verb = "stammers"
|
||||
speech_problem_flag = 1
|
||||
|
||||
if(cultslurring)
|
||||
message = cultslur(message)
|
||||
verb = "slurs"
|
||||
speech_problem_flag = 1
|
||||
if(!IsVocal())
|
||||
message = ""
|
||||
speech_problem_flag = 1
|
||||
|
||||
@@ -1,5 +1,5 @@
|
||||
|
||||
/mob/living/simple_animal/construct
|
||||
/mob/living/simple_animal/hostile/construct
|
||||
name = "Construct"
|
||||
real_name = "Construct"
|
||||
desc = ""
|
||||
@@ -19,24 +19,31 @@
|
||||
faction = list("cult")
|
||||
flying = 1
|
||||
universal_speak = 1
|
||||
AIStatus = AI_OFF //normal constructs don't have AI
|
||||
var/const_type = "shade"
|
||||
var/list/construct_spells = list()
|
||||
var/playstyle_string = "<b>You are a generic construct! Your job is to not exist, and you should probably adminhelp this.</b>"
|
||||
loot = list(/obj/item/weapon/reagent_containers/food/snacks/ectoplasm)
|
||||
del_on_death = 1
|
||||
deathmessage = "collapses in a shattered heap."
|
||||
|
||||
/mob/living/simple_animal/construct/New()
|
||||
/mob/living/simple_animal/hostile/construct/New()
|
||||
..()
|
||||
name = text("[initial(name)] ([rand(1, 1000)])")
|
||||
real_name = name
|
||||
name = "[ticker.mode.cultdat.get_name(const_type)] ([rand(1, 1000)])"
|
||||
real_name = ticker.mode.cultdat.get_name(const_type)
|
||||
icon_living = ticker.mode.cultdat.get_icon(const_type)
|
||||
icon_state = ticker.mode.cultdat.get_icon(const_type)
|
||||
for(var/spell in construct_spells)
|
||||
AddSpell(new spell(null))
|
||||
updateglow()
|
||||
|
||||
/mob/living/simple_animal/construct/examine(mob/user)
|
||||
if(ticker.mode.cultdat.theme == "blood")
|
||||
updateglow()
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/examine(mob/user)
|
||||
to_chat(user, "<span class='info'>*---------*</span>")
|
||||
..(user)
|
||||
|
||||
var/msg = "<span class='info'>"
|
||||
var/msg = ""
|
||||
if(src.health < src.maxHealth)
|
||||
msg += "<span class='warning'>"
|
||||
if(src.health >= src.maxHealth/2)
|
||||
@@ -48,32 +55,34 @@
|
||||
|
||||
to_chat(user, msg)
|
||||
|
||||
/mob/living/simple_animal/construct/attack_animal(mob/living/simple_animal/M as mob)
|
||||
if(istype(M, /mob/living/simple_animal/construct/builder))
|
||||
health += 5
|
||||
M.custom_emote(1,"mends some of \the <EM>[src]'s</EM> wounds.")
|
||||
else
|
||||
if(M.melee_damage_upper <= 0)
|
||||
M.custom_emote(1, "[M.friendly] \the <EM>[src]</EM>")
|
||||
/mob/living/simple_animal/hostile/construct/attack_animal(mob/living/simple_animal/M)
|
||||
if(istype(M, /mob/living/simple_animal/hostile/construct/builder))
|
||||
if(health < maxHealth)
|
||||
adjustBruteLoss(-5)
|
||||
if(src != M)
|
||||
Beam(M,icon_state="sendbeam",icon='icons/effects/effects.dmi',time=4)
|
||||
M.visible_message("<span class='danger'>[M] repairs some of \the <b>[src]'s</b> dents.</span>", \
|
||||
"<span class='cult'>You repair some of <b>[src]'s</b> dents, leaving <b>[src]</b> at <b>[health]/[maxHealth]</b> health.</span>")
|
||||
else
|
||||
M.visible_message("<span class='danger'>[M] repairs some of its own dents.</span>", \
|
||||
"<span class='cult'>You repair some of your own dents, leaving you at <b>[M.health]/[M.maxHealth]</b> health.</span>")
|
||||
else
|
||||
M.do_attack_animation(src)
|
||||
if(M.attack_sound)
|
||||
playsound(loc, M.attack_sound, 50, 1, 1)
|
||||
for(var/mob/O in viewers(src, null))
|
||||
O.show_message("<span class='attack'>\The <EM>[M]</EM> [M.attacktext] \the <EM>[src]</EM>!</span>", 1)
|
||||
add_logs(M, src, "attacked")
|
||||
var/damage = rand(M.melee_damage_lower, M.melee_damage_upper)
|
||||
adjustBruteLoss(damage)
|
||||
if(src != M)
|
||||
to_chat(M, "<span class='cult'>You cannot repair <b>[src]'s</b> dents, as it has none!</span>")
|
||||
else
|
||||
to_chat(M, "<span class='cult'>You cannot repair your own dents, as you have none!</span>")
|
||||
else if(src != M)
|
||||
..()
|
||||
|
||||
|
||||
/mob/living/simple_animal/construct/narsie_act()
|
||||
/mob/living/simple_animal/hostile/construct/narsie_act()
|
||||
return
|
||||
|
||||
/////////////////Juggernaut///////////////
|
||||
|
||||
|
||||
|
||||
/mob/living/simple_animal/construct/armoured
|
||||
/mob/living/simple_animal/hostile/construct/armoured
|
||||
name = "Juggernaut"
|
||||
real_name = "Juggernaut"
|
||||
desc = "A possessed suit of armour driven by the will of the restless dead"
|
||||
@@ -91,11 +100,19 @@
|
||||
environment_smash = 2
|
||||
attack_sound = 'sound/weapons/punch3.ogg'
|
||||
status_flags = 0
|
||||
const_type = "juggernaut"
|
||||
mob_size = MOB_SIZE_LARGE
|
||||
construct_spells = list(/obj/effect/proc_holder/spell/aoe_turf/conjure/lesserforcewall)
|
||||
force_threshold = 11
|
||||
playstyle_string = "<b>You are a Juggernaut. Though slow, your shell can withstand extreme punishment, \
|
||||
create shield walls, rip apart enemies and walls alike, and even deflect energy weapons.</b>"
|
||||
|
||||
/mob/living/simple_animal/construct/armoured/bullet_act(var/obj/item/projectile/P)
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/armoured/hostile //actually hostile, will move around, hit things
|
||||
AIStatus = AI_ON
|
||||
environment_smash = 1 //only token destruction, don't smash the cult wall NO STOP
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/armoured/bullet_act(var/obj/item/projectile/P)
|
||||
if(istype(P, /obj/item/projectile/energy) || istype(P, /obj/item/projectile/beam))
|
||||
var/reflectchance = 80 - round(P.damage/3)
|
||||
if(prob(reflectchance))
|
||||
@@ -128,7 +145,7 @@
|
||||
|
||||
|
||||
|
||||
/mob/living/simple_animal/construct/wraith
|
||||
/mob/living/simple_animal/hostile/construct/wraith
|
||||
name = "Wraith"
|
||||
real_name = "Wraith"
|
||||
desc = "A wicked bladed shell contraption piloted by a bound spirit"
|
||||
@@ -142,15 +159,19 @@
|
||||
attacktext = "slashes"
|
||||
see_in_dark = 7
|
||||
attack_sound = 'sound/weapons/bladeslice.ogg'
|
||||
const_type = "wraith"
|
||||
construct_spells = list(/obj/effect/proc_holder/spell/targeted/ethereal_jaunt/shift)
|
||||
retreat_distance = 2 //AI wraiths will move in and out of combat
|
||||
playstyle_string = "<b>You are a Wraith. Though relatively fragile, you are fast, deadly, and even able to phase through walls.</b>"
|
||||
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/wraith/hostile //actually hostile, will move around, hit things
|
||||
AIStatus = AI_ON
|
||||
|
||||
/////////////////////////////Artificer/////////////////////////
|
||||
|
||||
|
||||
|
||||
/mob/living/simple_animal/construct/builder
|
||||
/mob/living/simple_animal/hostile/construct/builder
|
||||
name = "Artificer"
|
||||
real_name = "Artificer"
|
||||
desc = "A bulbous construct dedicated to building and maintaining The Cult of Nar-Sie's armies"
|
||||
@@ -165,18 +186,70 @@
|
||||
melee_damage_upper = 5
|
||||
attacktext = "rams"
|
||||
environment_smash = 2
|
||||
retreat_distance = 10
|
||||
minimum_distance = 10 //AI artificers will flee like fuck
|
||||
attack_sound = 'sound/weapons/punch2.ogg'
|
||||
const_type = "builder"
|
||||
construct_spells = list(/obj/effect/proc_holder/spell/aoe_turf/conjure/construct/lesser,
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/wall,
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/floor,
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/pylon,
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/soulstone,
|
||||
/obj/effect/proc_holder/spell/targeted/projectile/magic_missile/lesser)
|
||||
|
||||
playstyle_string = "<b>You are an Artificer. You are incredibly weak and fragile, but you are able to construct fortifications, \
|
||||
use magic missile, repair allied constructs (by clicking on them), \
|
||||
<i>and, most important of all,</i> create new constructs by producing soulstones to capture souls, \
|
||||
and shells to place those soulstones into.</b>"
|
||||
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/builder/Found(atom/A) //what have we found here?
|
||||
if(istype(A, /mob/living/simple_animal/hostile/construct)) //is it a construct?
|
||||
var/mob/living/simple_animal/hostile/construct/C = A
|
||||
if(C.health < C.maxHealth) //is it hurt? let's go heal it if it is
|
||||
return 1
|
||||
else
|
||||
return 0
|
||||
else
|
||||
return 0
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/builder/CanAttack(atom/the_target)
|
||||
if(see_invisible < the_target.invisibility)//Target's invisible to us, forget it
|
||||
return 0
|
||||
if(Found(the_target) || ..()) //If we Found it or Can_Attack it normally, we Can_Attack it as long as it wasn't invisible
|
||||
return 1 //as a note this shouldn't be added to base hostile mobs because it'll mess up retaliate hostile mobs
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/builder/MoveToTarget(var/list/possible_targets)
|
||||
..()
|
||||
if(isliving(target))
|
||||
var/mob/living/L = target
|
||||
if(istype(L, /mob/living/simple_animal/hostile/construct) && L.health >= L.maxHealth) //is this target an unhurt construct? stop trying to heal it
|
||||
LoseTarget()
|
||||
return 0
|
||||
if(L.health <= melee_damage_lower+melee_damage_upper) //ey bucko you're hurt as fuck let's go hit you
|
||||
retreat_distance = null
|
||||
minimum_distance = 1
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/builder/Aggro()
|
||||
..()
|
||||
if(istype(target, /mob/living/simple_animal/hostile/construct)) //oh the target is a construct no need to flee
|
||||
retreat_distance = null
|
||||
minimum_distance = 1
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/builder/LoseAggro()
|
||||
..()
|
||||
retreat_distance = initial(retreat_distance)
|
||||
minimum_distance = initial(minimum_distance)
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/builder/hostile //actually hostile, will move around, hit things, heal other constructs
|
||||
AIStatus = AI_ON
|
||||
environment_smash = 1 //only token destruction, don't smash the cult wall NO STOP
|
||||
|
||||
|
||||
/////////////////////////////Behemoth/////////////////////////
|
||||
|
||||
|
||||
/mob/living/simple_animal/construct/behemoth
|
||||
/mob/living/simple_animal/hostile/construct/behemoth
|
||||
name = "Behemoth"
|
||||
real_name = "Behemoth"
|
||||
desc = "The pinnacle of occult technology, Behemoths are the ultimate weapon in the Cult of Nar-Sie's arsenal."
|
||||
@@ -195,13 +268,22 @@
|
||||
environment_smash = 2
|
||||
attack_sound = 'sound/weapons/punch4.ogg'
|
||||
force_threshold = 11
|
||||
const_type = "behemoth"
|
||||
var/energy = 0
|
||||
var/max_energy = 1000
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/behemoth/hostile //actually hostile, will move around, hit things
|
||||
AIStatus = AI_ON
|
||||
environment_smash = 1 //only token destruction, don't smash the cult wall NO STOP
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/behemoth/Life()
|
||||
weakened = 0
|
||||
return ..()
|
||||
|
||||
|
||||
/////////////////////////////Harvester/////////////////////////
|
||||
|
||||
/mob/living/simple_animal/construct/harvester
|
||||
/mob/living/simple_animal/hostile/construct/harvester
|
||||
name = "Harvester"
|
||||
real_name = "Harvester"
|
||||
desc = "A harbinger of Nar-Sie's enlightenment. It'll be all over soon."
|
||||
@@ -215,16 +297,25 @@
|
||||
attacktext = "prods"
|
||||
speed = 0
|
||||
environment_smash = 1
|
||||
see_in_dark = 7
|
||||
see_in_dark = 8
|
||||
attack_sound = 'sound/weapons/tap.ogg'
|
||||
const_type = "harvester"
|
||||
construct_spells = list(/obj/effect/proc_holder/spell/targeted/smoke/disable)
|
||||
retreat_distance = 2 //AI harvesters will move in and out of combat, like wraiths, but shittier
|
||||
playstyle_string = "<B>You are a Harvester. You are not strong, but your powers of domination will assist you in your role: \
|
||||
Bring those who still cling to this world of illusion back to the master so they may know Truth.</B>"
|
||||
|
||||
/mob/living/simple_animal/construct/harvester/Process_Spacemove(var/movement_dir = 0)
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/harvester/Process_Spacemove(var/movement_dir = 0)
|
||||
return 1
|
||||
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/harvester/hostile //actually hostile, will move around, hit things
|
||||
AIStatus = AI_ON
|
||||
|
||||
|
||||
////////////////Glow////////////////////
|
||||
/mob/living/simple_animal/construct/proc/updateglow()
|
||||
/mob/living/simple_animal/hostile/construct/proc/updateglow()
|
||||
overlays = 0
|
||||
var/overlay_layer = LIGHTING_LAYER + 1
|
||||
if(layer != MOB_LAYER)
|
||||
@@ -233,32 +324,75 @@
|
||||
overlays += image(icon,"glow-[icon_state]",overlay_layer)
|
||||
set_light(2, -2, l_color = "#FFFFFF")
|
||||
|
||||
////////////////Powers//////////////////
|
||||
///ui stuff
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/armoured/handle_hud_icons_health()
|
||||
..()
|
||||
if(healths)
|
||||
switch(health)
|
||||
if(250 to INFINITY) healths.icon_state = "juggernaut_health0"
|
||||
if(208 to 249) healths.icon_state = "juggernaut_health1"
|
||||
if(167 to 207) healths.icon_state = "juggernaut_health2"
|
||||
if(125 to 166) healths.icon_state = "juggernaut_health3"
|
||||
if(84 to 124) healths.icon_state = "juggernaut_health4"
|
||||
if(42 to 83) healths.icon_state = "juggernaut_health5"
|
||||
if(1 to 41) healths.icon_state = "juggernaut_health6"
|
||||
else healths.icon_state = "juggernaut_health7"
|
||||
|
||||
|
||||
/*
|
||||
/client/proc/summon_cultist()
|
||||
set category = "Behemoth"
|
||||
set name = "Summon Cultist (300)"
|
||||
set desc = "Teleport a cultist to your location"
|
||||
if(istype(usr,/mob/living/simple_animal/constructbehemoth))
|
||||
/mob/living/simple_animal/hostile/construct/behemoth/handle_hud_icons_health()
|
||||
..()
|
||||
if(healths)
|
||||
switch(health)
|
||||
if(750 to INFINITY) healths.icon_state = "juggernaut_health0"
|
||||
if(625 to 749) healths.icon_state = "juggernaut_health1"
|
||||
if(500 to 624) healths.icon_state = "juggernaut_health2"
|
||||
if(375 to 499) healths.icon_state = "juggernaut_health3"
|
||||
if(250 to 374) healths.icon_state = "juggernaut_health4"
|
||||
if(125 to 249) healths.icon_state = "juggernaut_health5"
|
||||
if(1 to 124) healths.icon_state = "juggernaut_health6"
|
||||
else healths.icon_state = "juggernaut_health7"
|
||||
|
||||
if(usr.energy<300)
|
||||
to_chat(usr, "\red You do not have enough power stored!")
|
||||
return
|
||||
/mob/living/simple_animal/hostile/construct/builder/handle_hud_icons_health()
|
||||
..()
|
||||
if(healths)
|
||||
switch(health)
|
||||
if(50 to INFINITY) healths.icon_state = "artificer_health0"
|
||||
if(42 to 49) healths.icon_state = "artificer_health1"
|
||||
if(34 to 41) healths.icon_state = "artificer_health2"
|
||||
if(26 to 33) healths.icon_state = "artificer_health3"
|
||||
if(18 to 25) healths.icon_state = "artificer_health4"
|
||||
if(10 to 17) healths.icon_state = "artificer_health5"
|
||||
if(1 to 9) healths.icon_state = "artificer_health6"
|
||||
else healths.icon_state = "artificer_health7"
|
||||
|
||||
if(usr.stat)
|
||||
return
|
||||
|
||||
usr.energy -= 300
|
||||
var/list/mob/living/cultists = new
|
||||
for(var/datum/mind/H in ticker.mode.cult)
|
||||
if(istype(H.current,/mob/living))
|
||||
cultists+=H.current
|
||||
var/mob/cultist = input("Choose the one who you want to summon", "Followers of Geometer") as null|anything in (cultists - usr)
|
||||
if(!cultist)
|
||||
return
|
||||
if(cultist == usr) //just to be sure.
|
||||
return
|
||||
cultist.loc = usr.loc
|
||||
usr.visible_message("/red [cultist] appears in a flash of red light as [usr] glows with power")*/
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/wraith/handle_hud_icons_health()
|
||||
|
||||
..()
|
||||
if(healths)
|
||||
switch(health)
|
||||
if(75 to INFINITY) healths.icon_state = "wraith_health0"
|
||||
if(62 to 74) healths.icon_state = "wraith_health1"
|
||||
if(50 to 61) healths.icon_state = "wraith_health2"
|
||||
if(37 to 49) healths.icon_state = "wraith_health3"
|
||||
if(25 to 36) healths.icon_state = "wraith_health4"
|
||||
if(12 to 24) healths.icon_state = "wraith_health5"
|
||||
if(1 to 11) healths.icon_state = "wraith_health6"
|
||||
else healths.icon_state = "wraith_health7"
|
||||
|
||||
|
||||
/mob/living/simple_animal/hostile/construct/harvester/handle_hud_icons_health()
|
||||
|
||||
..()
|
||||
if(healths)
|
||||
switch(health)
|
||||
if(150 to INFINITY) healths.icon_state = "harvester_health0"
|
||||
if(125 to 149) healths.icon_state = "harvester_health1"
|
||||
if(100 to 124) healths.icon_state = "harvester_health2"
|
||||
if(75 to 99) healths.icon_state = "harvester_health3"
|
||||
if(50 to 74) healths.icon_state = "harvester_health4"
|
||||
if(25 to 49) healths.icon_state = "harvester_health5"
|
||||
if(1 to 24) healths.icon_state = "harvester_health6"
|
||||
else healths.icon_state = "harvester_health7"
|
||||
@@ -67,6 +67,8 @@
|
||||
Your character moves slower.
|
||||
* Slurring *
|
||||
Your character cannot enunciate clearly.
|
||||
* CultSlurring *
|
||||
Your character cannot enunciate clearly while mumbling about elder codes.
|
||||
* Stunned *
|
||||
Your character is unable to move, and drops stuff in their hands. They keep standing, though.
|
||||
* Stuttering *
|
||||
@@ -108,6 +110,7 @@
|
||||
|
||||
/mob // On `/mob` for now, to support legacy code
|
||||
var/confused = 0
|
||||
var/cultslurring = 0
|
||||
var/dizziness = 0
|
||||
var/drowsyness = 0
|
||||
var/druggy = 0
|
||||
@@ -387,6 +390,18 @@
|
||||
var/new_value = directional_bounded_sum(slurring, amount, bound_lower, bound_upper)
|
||||
SetSlur(new_value)
|
||||
|
||||
// CULTSLURRING
|
||||
|
||||
/mob/living/CultSlur(amount)
|
||||
SetSlur(max(slurring, amount))
|
||||
|
||||
/mob/living/SetCultSlur(amount)
|
||||
slurring = max(amount, 0)
|
||||
|
||||
/mob/living/AdjustCultSlur(amount, bound_lower = 0, bound_upper = INFINITY)
|
||||
var/new_value = directional_bounded_sum(cultslurring, amount, bound_lower, bound_upper)
|
||||
SetCultSlur(new_value)
|
||||
|
||||
// STUN
|
||||
|
||||
/mob/living/Stun(amount, updating = 1, force = 0)
|
||||
|
||||
@@ -547,6 +547,47 @@ var/list/intents = list(I_HELP,I_DISARM,I_GRAB,I_HARM)
|
||||
|
||||
rename_character(oldname, newname)
|
||||
|
||||
/proc/cultslur(n) // Inflicted on victims of a stun talisman
|
||||
var/phrase = html_decode(n)
|
||||
var/leng = lentext(phrase)
|
||||
var/counter=lentext(phrase)
|
||||
var/newphrase=""
|
||||
var/newletter=""
|
||||
while(counter>=1)
|
||||
newletter=copytext(phrase,(leng-counter)+1,(leng-counter)+2)
|
||||
if(rand(1,2)==2)
|
||||
if(lowertext(newletter)=="o")
|
||||
newletter="u"
|
||||
if(lowertext(newletter)=="t")
|
||||
newletter="ch"
|
||||
if(lowertext(newletter)=="a")
|
||||
newletter="ah"
|
||||
if(lowertext(newletter)=="u")
|
||||
newletter="oo"
|
||||
if(lowertext(newletter)=="c")
|
||||
newletter=" NAR "
|
||||
if(lowertext(newletter)=="s")
|
||||
newletter=" SIE "
|
||||
if(rand(1,4)==4)
|
||||
if(newletter==" ")
|
||||
newletter=" no hope... "
|
||||
if(newletter=="H")
|
||||
newletter=" IT COMES... "
|
||||
|
||||
switch(rand(1,15))
|
||||
if(1)
|
||||
newletter="'"
|
||||
if(2)
|
||||
newletter+="agn"
|
||||
if(3)
|
||||
newletter="fth"
|
||||
if(4)
|
||||
newletter="nglu"
|
||||
if(5)
|
||||
newletter="glor"
|
||||
newphrase+="[newletter]";counter-=1
|
||||
return newphrase
|
||||
|
||||
/mob/proc/get_preference(toggleflag)
|
||||
if(!client)
|
||||
return FALSE
|
||||
|
||||
@@ -164,11 +164,6 @@
|
||||
|
||||
if(mob.stat==DEAD) return
|
||||
|
||||
// handle possible spirit movement
|
||||
if(istype(mob,/mob/spirit))
|
||||
var/mob/spirit/currentSpirit = mob
|
||||
return currentSpirit.Spirit_Move(direct)
|
||||
|
||||
if(mob.notransform) return//This is sota the goto stop mobs from moving var
|
||||
|
||||
if(isliving(mob))
|
||||
|
||||
@@ -1,32 +0,0 @@
|
||||
/*
|
||||
|
||||
This file contains the code necessary to do the display code for cult spirits.
|
||||
|
||||
It reuses a lot of code from the AIEye cameraNetwork. In order to work properly, some of those files needed to be modified as well.
|
||||
|
||||
*/
|
||||
|
||||
|
||||
/proc/isCultRune(var/viewpoint)
|
||||
var/obj/effect/rune/test_rune = viewpoint
|
||||
if(test_rune)
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
|
||||
/proc/isCultViewpoint(var/viewpoint)
|
||||
var/obj/cult_viewpoint/vp = viewpoint
|
||||
if(vp)
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
/*
|
||||
RUNE JUNK
|
||||
*/
|
||||
|
||||
/obj/effect/rune/proc/can_use()
|
||||
return TRUE
|
||||
|
||||
/obj/effect/rune/proc/can_see()
|
||||
return hear(view_range, get_turf(src))
|
||||
|
||||
@@ -1,227 +0,0 @@
|
||||
/mob/spirit/mask
|
||||
icon = 'icons/mob/spirits/mask.dmi'
|
||||
icon_state = "depressurized"
|
||||
|
||||
/mob/spirit/mask/New()
|
||||
..()
|
||||
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/conjure/create_talisman(null))
|
||||
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/blood_speech(null))
|
||||
AddSpell(new /obj/effect/proc_holder/spell/aoe_turf/shatter_lights(null))
|
||||
|
||||
|
||||
/mob/spirit/mask/verb/go_to_follower()
|
||||
set category = "Mask"
|
||||
set name = "Go to follower"
|
||||
set desc = "Select who you would like to go too."
|
||||
|
||||
var/obj/cult_viewpoint/cultist = pick_cultist()
|
||||
if(cultist)
|
||||
follow_cultist(cultist.owner)
|
||||
cult_log("[key_name_admin(src)] started following [key_name_admin(cultist)].")
|
||||
to_chat(src, "You start following [cultist.get_display_name()].")
|
||||
|
||||
|
||||
/mob/spirit/mask/verb/urge_cultist()
|
||||
set category = "Mask"
|
||||
set name = "Urge cultist"
|
||||
set desc = "Push your cultists to do something."
|
||||
|
||||
var/obj/cult_viewpoint/cultist = pick_cultist()
|
||||
if(cultist)
|
||||
if(cultist.owner)
|
||||
var/newUrge = stripped_input(usr, "", "Set Urge", "")
|
||||
cultist.set_urge(newUrge)
|
||||
to_chat(src, "You urge [cultist.owner.name] to [newUrge].")
|
||||
cult_log("controlled by [key_name_admin(src)] has urged [key_name_admin(cultist.owner)] to [newUrge].")
|
||||
|
||||
/mob/spirit/mask/verb/set_cult_name()
|
||||
set category = "Mask"
|
||||
set name = "Set Cult Name"
|
||||
set desc = "Grant a cultist a name."
|
||||
|
||||
var/obj/cult_viewpoint/cultist = pick_cultist()
|
||||
if(cultist)
|
||||
var/newName = stripped_input(usr, "", "Set Cult Name", "")
|
||||
if(!newName)
|
||||
return
|
||||
cultist.set_cult_name(newName)
|
||||
to_chat(src, "You grant [cultist.owner.name] the secret name of [newName].")
|
||||
if(cultist.owner)
|
||||
cult_log("[key_name_admin(src)] has set [key_name_admin(cultist.owner)] to \'[newName]\'")
|
||||
|
||||
|
||||
/mob/spirit/mask/verb/urge_cult()
|
||||
set category = "Mask"
|
||||
set name = "Urge Cult"
|
||||
set desc = "Set urge on the entire cult."
|
||||
|
||||
var/newUrge = stripped_input(usr, "Please choose an urge.", "Set Urge", "")
|
||||
for(var/obj/cult_viewpoint/viewpoint in cult_viewpoints)
|
||||
viewpoint.set_urge(newUrge)
|
||||
to_chat(src, "You urge the entire cult to [newUrge].")
|
||||
cult_log("[key_name_admin(src)] has urged the entire cult to [newUrge]")
|
||||
|
||||
|
||||
/mob/spirit/mask/verb/set_favor_for_cultist()
|
||||
set category = "Mask"
|
||||
set name = "Show your favor"
|
||||
set desc = "Set the favor for a cultist"
|
||||
|
||||
var/obj/cult_viewpoint/cultist = pick_cultist()
|
||||
if(cultist)
|
||||
if(cultist.owner)
|
||||
var/list/favor = list("Pleased", "Displeased", "Indifference")
|
||||
var/emotion = input("Pick your emotion", "Mask", null, null) in favor
|
||||
switch(emotion)
|
||||
if("Pleased")
|
||||
cultist.set_favor(1)
|
||||
cult_log("[key_name_admin(src)] is pleased with [key_name_admin(cultist.owner)]")
|
||||
if("Displeased")
|
||||
cultist.set_favor(-1)
|
||||
cult_log("[key_name_admin(src)] is displeased with [key_name_admin(cultist.owner)]")
|
||||
if("Indifference")
|
||||
cultist.set_favor(0)
|
||||
cult_log("[key_name_admin(src)] is indifferent too [key_name_admin(cultist.owner)]")
|
||||
|
||||
|
||||
/mob/spirit/mask/proc/set_name()
|
||||
spawn(0)
|
||||
var/newName = stripped_input(src, "Please pick a name.", "Pick Name for Mask", "")
|
||||
name = newName ? newName : "Mask of Nar'sie"
|
||||
to_chat(src, "You have set your name to [name].")
|
||||
|
||||
|
||||
/mob/spirit/mask/proc/pick_cultist()
|
||||
var/list/cultists = list()
|
||||
for(var/obj/cult_viewpoint/viewpoint in cult_viewpoints)
|
||||
cultists[viewpoint.get_display_name()]=viewpoint
|
||||
var/input = input("Please, select a cultist!", "Cult", null, null) as null|anything in cultists
|
||||
var/obj/cult_viewpoint/result = cultists[input]
|
||||
return result
|
||||
|
||||
|
||||
// this proc makes the mask visible very briefly
|
||||
/mob/spirit/mask/proc/flicker()
|
||||
spawn(0)
|
||||
alpha = 127
|
||||
invisibility=0
|
||||
sleep(5)
|
||||
invisibility=initial(invisibility)
|
||||
alpha = 255
|
||||
|
||||
/proc/flicker_mask(mob/spirit/mask/target)
|
||||
if(istype(target))
|
||||
target.flicker()
|
||||
|
||||
// SPELLS
|
||||
/obj/effect/proc_holder/spell/aoe_turf/blood_speech
|
||||
name = "Speak to your Acolytes"
|
||||
desc = "This spell allows you to speak to your flock."
|
||||
school = "unknown evil"
|
||||
charge_type = "recharge"
|
||||
charge_max = 2000
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = 0
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/blood_speech/cast(list/targets)
|
||||
var/input = stripped_input(usr, "Please choose a message to tell your acolytes.", "Voice of Blood", "")
|
||||
if(!input)
|
||||
revert_cast(usr)
|
||||
cult_log("[key_name_admin(usr)]says : [input]")
|
||||
flicker_mask(usr)
|
||||
for(var/datum/mind/H in ticker.mode.cult)
|
||||
if(H.current)
|
||||
to_chat(H.current, "<span class='cultspeech'><font size=3><span class='name'>[usr.name]: </span><span class='message'>[input]</span></font></span>")
|
||||
for(var/mob/spirit/spirit in spirits)
|
||||
to_chat(spirit, "<span class='cultspeech'><font size=3><span class='name'>[usr.name]: </span><span class='message'>[input]</span></font></span>")
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/shatter_lights
|
||||
name = "Spread Shadows"
|
||||
desc = "This spell breaks lights near the mask."
|
||||
school = "unknown evil"
|
||||
charge_type = "recharge"
|
||||
charge_max = 1000
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = 0
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/shatter_lights/cast(list/targets)
|
||||
cult_log("[key_name_admin(usr)] used Spread Shadows.")
|
||||
flicker_mask(usr)
|
||||
spawn(0)
|
||||
for(var/area/A in range(3,get_turf(usr)))
|
||||
for(var/obj/machinery/light/L in A)
|
||||
L.on = 1
|
||||
L.broken()
|
||||
sleep(1)
|
||||
for(var/obj/item/device/flashlight/F in A)
|
||||
F.on = 0
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/create_talisman
|
||||
name = "Create Talisman"
|
||||
desc = "This spell conjures a talisman"
|
||||
|
||||
school = "conjuration"
|
||||
charge_type = "recharge"
|
||||
charge_max = 3000
|
||||
clothes_req = 0
|
||||
invocation = "none"
|
||||
invocation_type = "none"
|
||||
range = 0
|
||||
summon_type = list(/obj/item/weapon/paper/talisman)
|
||||
|
||||
var/list/talismans = list( "Armor"="armor",
|
||||
"Blind"="blind",
|
||||
"Conceal"="conceal",
|
||||
"Communicate"="communicate",
|
||||
"Deafen"="deafen",
|
||||
"EMP"="emp",
|
||||
"Teleport"="teleport",
|
||||
"Tome"="newtome",
|
||||
"Reveal Runes",
|
||||
"Stun"="runestun",
|
||||
"Soul Stone"="soulstone",
|
||||
"Construct"="construct")
|
||||
|
||||
|
||||
/obj/effect/proc_holder/spell/aoe_turf/conjure/create_talisman/cast(list/targets)
|
||||
|
||||
var/talisman = input("Pick a talisman type", "Talisman", null, null) as null|anything in talismans
|
||||
var/imbue_value = talismans[talisman]
|
||||
if(!talisman)
|
||||
to_chat(usr, "You choose not to create a talisman.")
|
||||
revert_cast(usr)
|
||||
return
|
||||
|
||||
cult_log("[key_name_admin(usr,0)] created a talisman of type [talisman].")
|
||||
flicker_mask(usr)
|
||||
|
||||
switch(talisman)
|
||||
|
||||
if("Teleport")
|
||||
var/target_rune = input("Pick a teleport target", "Teleport Rune", null, null) as null|anything in engwords
|
||||
if(!target_rune)
|
||||
to_chat(usr, "You choose not to create a talisman.")
|
||||
revert_cast(usr)
|
||||
return
|
||||
summon_type = list(/obj/item/weapon/paper/talisman)
|
||||
newVars = list("imbue" = "[target_rune]", "info" = "[target_rune]")
|
||||
|
||||
if("Soul Stone")
|
||||
summon_type = list(/obj/item/device/soulstone)
|
||||
newVars = list()
|
||||
|
||||
if("Construct")
|
||||
summon_type = list(/obj/structure/constructshell)
|
||||
newVars = list()
|
||||
|
||||
else
|
||||
summon_type = list(/obj/item/weapon/paper/talisman)
|
||||
newVars = list("imbue" = "[imbue_value]")
|
||||
|
||||
..()
|
||||
@@ -1,20 +0,0 @@
|
||||
/proc/there_can_be_only_one_mask(var/mob/spirit/mask/target)
|
||||
if(!istype(target))
|
||||
return
|
||||
for(var/mob/spirit/mask/currentSpirit in spirits)
|
||||
if(currentSpirit)
|
||||
if(currentSpirit!=target)
|
||||
// create the ghost
|
||||
var/mob/dead/observer/ghost = currentSpirit.ghostize(TRUE)
|
||||
// let the deposed mask respawn immediately, the poor dear
|
||||
ghost.timeofdeath = world.time - 20000
|
||||
ghost.newPlayerType = /mob/new_player/cultist
|
||||
// remove old mask body
|
||||
qdel(currentSpirit)
|
||||
|
||||
|
||||
/mob/new_player/cultist/AttemptLateSpawn(rank)
|
||||
var/mob/newCharacter = ..(rank)
|
||||
if(ticker.mode)
|
||||
if(is_convertable_to_cult(newCharacter.mind))
|
||||
ticker.mode.add_cultist(newCharacter.mind)
|
||||
@@ -1,61 +0,0 @@
|
||||
// spirits are not moved by airflow
|
||||
mob/spirit/Move()
|
||||
return 0
|
||||
|
||||
// this is the main move proc for spirits, it uses their 'setLoc' function to handle all the visibility shenanigans
|
||||
// this, like most movement code for these guys, is cribbed from the AIEye movement code
|
||||
mob/spirit/proc/Spirit_Move(direct)
|
||||
|
||||
var/initial = initial(sprint)
|
||||
var/max_sprint = 50
|
||||
|
||||
// if we haven't moved in a while, we stop sprinting
|
||||
if(cooldown && cooldown < world.timeofday) // 3 seconds
|
||||
sprint = initial
|
||||
|
||||
for(var/i = 0; i < max(sprint, initial); i += 20)
|
||||
var/turf/step = get_turf(get_step(src, direct))
|
||||
if(step)
|
||||
setLoc(step)
|
||||
|
||||
dir = direct // update our sprite
|
||||
|
||||
cooldown = world.timeofday + 5
|
||||
if(acceleration)
|
||||
sprint = min(sprint + 0.5, max_sprint)
|
||||
else
|
||||
sprint = initial
|
||||
|
||||
// if we're trying to move, we want to stop following our target
|
||||
follow_target = null
|
||||
|
||||
|
||||
/mob/spirit/proc/follow_cultist(mob/living/target as mob)
|
||||
if(!istype(target)) return
|
||||
var/obj/cult_viewpoint/currentView = getCultViewpoint(target)
|
||||
var/mob/spirit/U = usr
|
||||
|
||||
if(!currentView)
|
||||
to_chat(U, "As a spirit, you may only track cultists.")
|
||||
|
||||
U.follow_target = target
|
||||
to_chat(U, "Now following [currentView.get_cult_name()].")
|
||||
|
||||
spawn (0)
|
||||
while(U.follow_target == target)
|
||||
if(U.follow_target == null)
|
||||
return
|
||||
U.setLoc(get_turf(target))
|
||||
sleep(10)
|
||||
|
||||
|
||||
mob/spirit/setLoc(var/T)
|
||||
T = get_turf(T)
|
||||
loc = T
|
||||
|
||||
mob/spirit/verb/toggle_acceleration()
|
||||
set category = "Spirit"
|
||||
set name = "Toggle Acceleration"
|
||||
|
||||
acceleration = !acceleration
|
||||
to_chat(usr, "Acceleration has been toggled [acceleration ? "on" : "off"].")
|
||||
@@ -1,70 +0,0 @@
|
||||
/*
|
||||
This mob type is used for entities that exist within the Cult's spirit world. They share the same visibility network and are intangible.
|
||||
*/
|
||||
|
||||
mob/spirit
|
||||
name = "spirit"
|
||||
desc = "A spirit"
|
||||
icon = 'icons/mob/mob.dmi'
|
||||
icon_state = "ghost"
|
||||
layer = 4
|
||||
stat = CONSCIOUS
|
||||
status_flags = GODMODE // spirits cannot be killed
|
||||
density = 0
|
||||
canmove = 0
|
||||
blinded = 0
|
||||
anchored = 1
|
||||
mouse_opacity = 0
|
||||
invisibility = INVISIBILITY_SPIRIT
|
||||
universal_speak = 1
|
||||
|
||||
// pseudo-movement values
|
||||
var/sprint = 10
|
||||
var/cooldown = 0
|
||||
var/acceleration = 1
|
||||
var/follow_target = null
|
||||
|
||||
|
||||
mob/spirit/proc/is_active()
|
||||
if(client && client.inactivity <= 10 * 60 * 10)
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
|
||||
mob/spirit/New()
|
||||
sight |= SEE_TURFS | SEE_MOBS | SEE_OBJS | SEE_SELF
|
||||
see_invisible = SEE_SPIRITS
|
||||
see_in_dark = 100
|
||||
|
||||
loc = pick(latejoin)
|
||||
|
||||
// no nameless spirits
|
||||
if(!name)
|
||||
name = "Boogyman"
|
||||
|
||||
spirits+=src
|
||||
|
||||
..()
|
||||
|
||||
mob/spirit/Destroy()
|
||||
spirits-=src
|
||||
return ..()
|
||||
|
||||
|
||||
mob/spirit/Topic(href, href_list)
|
||||
|
||||
if(usr != src)
|
||||
return
|
||||
..()
|
||||
|
||||
to_chat(usr, "Spirit Href = [href]")
|
||||
for(var/tempref in href_list)
|
||||
to_chat(usr, "Spirit href list [tempref] = [href_list[tempref]]")
|
||||
|
||||
if(href_list["track"])
|
||||
to_chat(usr, "Got to tracking.")
|
||||
var/mob/target = locate(href_list["track"]) in mob_list
|
||||
var/mob/spirit/A = locate(href_list["track2"]) in spirits
|
||||
if(A && target)
|
||||
A.follow_cultist(target)
|
||||
return
|
||||
@@ -1,203 +0,0 @@
|
||||
#define FAVOR_PLEASED 1
|
||||
#define FAVOR_INDIFFERENT 0
|
||||
#define FAVOR_DISPLEASED -1
|
||||
|
||||
|
||||
var/obj/cult_viewpoint/list/cult_viewpoints = list()
|
||||
|
||||
|
||||
/obj/cult_viewpoint
|
||||
var/view_range = 7
|
||||
var/updating = 0
|
||||
var/mob/owner = null
|
||||
var/urge = ""
|
||||
var/favor = FAVOR_INDIFFERENT
|
||||
var/cult_name = null
|
||||
|
||||
|
||||
/obj/cult_viewpoint/New(var/mob/target)
|
||||
owner = target
|
||||
//src.loc = owner
|
||||
cult_viewpoints+=src
|
||||
//handle_missing_mask()
|
||||
..()
|
||||
|
||||
|
||||
/obj/cult_viewpoint/Destroy()
|
||||
processing_objects.Remove(src)
|
||||
cult_viewpoints-=src
|
||||
return ..()
|
||||
|
||||
|
||||
// VERBS
|
||||
/obj/cult_viewpoint/verb/check_urge()
|
||||
set category = "Cult"
|
||||
set desc = "Discover what your god commands of you."
|
||||
set name = "Check Urge"
|
||||
set src in usr
|
||||
if(src.urge)
|
||||
to_chat(owner, "\red \b You feel the urge to [src.urge]")
|
||||
else
|
||||
to_chat(owner, "\b You feel no supernatural compulsions.")
|
||||
|
||||
|
||||
/obj/cult_viewpoint/verb/reach_out()
|
||||
set category = "Cult"
|
||||
set desc = "Reach out for your gods presence."
|
||||
set name = "Reach Out"
|
||||
set src in usr
|
||||
|
||||
for(var/mob/spirit/mask/currentMask in spirits)
|
||||
if(currentMask.is_active())
|
||||
to_chat(owner, "\red \b You feel the reassuring presence of your god.")
|
||||
to_chat(currentMask, "<span class='cultspeech'><span class='name'><a href='byond://?src=[currentMask.UID()];track2=\ref[currentMask];track=\ref[usr]'>[get_display_name()]</a></span><span class='message'> has reached out to you.</span></span>")
|
||||
|
||||
return
|
||||
to_chat(owner, "\b You feel a chilling absence.")
|
||||
handle_missing_mask()
|
||||
|
||||
|
||||
/obj/cult_viewpoint/verb/check_favor()
|
||||
set category = "Cult"
|
||||
set desc = "Check your favor with your god."
|
||||
set name = "Check Favor"
|
||||
set src in usr
|
||||
switch(favor)
|
||||
if(FAVOR_PLEASED)
|
||||
to_chat(owner, "\red \b You bask in your gods favor.")
|
||||
if(FAVOR_INDIFFERENT)
|
||||
to_chat(owner, "\red \b You feel nothing.")
|
||||
if(FAVOR_DISPLEASED)
|
||||
to_chat(owner, "\red \b You cringe at your gods displeasure.")
|
||||
|
||||
|
||||
/obj/cult_viewpoint/verb/pray_to_mask()
|
||||
set category = "Cult"
|
||||
set desc = "Pray to your god"
|
||||
set name = "Pray to Nar'Sie"
|
||||
set src in usr
|
||||
|
||||
var/input = stripped_input(usr, "Please choose a message to say to your god.", "Pray to Nar'Sie", "")
|
||||
if(!input)
|
||||
return
|
||||
|
||||
cult_log("[key_name(usr,0)](Pray):[input]")
|
||||
to_chat(owner, "<span class='cultspeech'><b>You pray to Nar'Sie</b>: [input]</span>")
|
||||
|
||||
for(var/mob/spirit/spirit in spirits)
|
||||
to_chat(spirit, "<span class='cultspeech'><span class='name'><a href='byond://?src=[spirit.UID()];track2=\ref[spirit];track=\ref[usr]'>[get_display_name()]</a> prays : </span><span class='message'>[input]</span></span>")
|
||||
|
||||
|
||||
// PROCS
|
||||
/obj/cult_viewpoint/proc/set_favor(var/newFavor)
|
||||
favor = newFavor
|
||||
check_favor()
|
||||
|
||||
|
||||
/obj/cult_viewpoint/proc/set_urge(var/newUrge)
|
||||
if(!newUrge)
|
||||
src.urge = null
|
||||
src.urge = copytext(newUrge, 1, MAX_MESSAGE_LEN)
|
||||
check_urge()
|
||||
|
||||
|
||||
/obj/cult_viewpoint/proc/can_use()
|
||||
if(owner.stat != DEAD)
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
|
||||
/obj/cult_viewpoint/proc/can_see()
|
||||
return hear(view_range, get_turf(owner))
|
||||
|
||||
|
||||
/obj/cult_viewpoint/proc/get_cult_name()
|
||||
if(cult_name)
|
||||
return cult_name
|
||||
return "An Unknown Servant"
|
||||
|
||||
|
||||
/obj/cult_viewpoint/proc/set_cult_name(var/newName)
|
||||
if(!owner)
|
||||
return FALSE
|
||||
if(newName)
|
||||
cult_name = newName
|
||||
to_chat(owner, "\red \b You have been blessed with the secret name of '[newName]'.")
|
||||
else
|
||||
cult_name = null
|
||||
to_chat(owner, "\red \b Your god has taken your secret name.")
|
||||
|
||||
|
||||
/obj/cult_viewpoint/proc/get_display_name()
|
||||
if(istype(src,/obj/effect/rune))
|
||||
return name
|
||||
if(!owner)
|
||||
return
|
||||
if(cult_name)
|
||||
return cult_name
|
||||
return owner.name
|
||||
|
||||
|
||||
/obj/cult_viewpoint/proc/become_mask()
|
||||
set category = "Cult"
|
||||
set name = "Become Mask"
|
||||
set desc = "Sacrifice your life and become a Mask of Nar'sie."
|
||||
set src in usr
|
||||
|
||||
cult_log("[key_name(usr,0)] has tried to become a Mask of Nar'sie.")
|
||||
|
||||
if(!active_mask())
|
||||
var/confirm = alert(owner.client, "You are about to become a Mask of Nar'sie. This will destroy your body, and you will only be able to guide the other cultists through communication. Are you sure?", "Confirm Your Sacrifice", "Yes", "No")
|
||||
if(confirm == "Yes")
|
||||
var/transformation_type = alert(owner.client, "You are about to become a Mask. Do you want it to be subtle or violent?", "Mask", "Subtle", "Violent")
|
||||
if(!active_mask())
|
||||
cult_log("[key_name(usr,0)] has become a Mask of Nar'sie.")
|
||||
if(transformation_type=="Subtle")
|
||||
log_admin("[key_name_admin(owner)] has subtly become a Mask of Nar'sie")
|
||||
owner.make_into_mask(0,0)
|
||||
else
|
||||
log_admin("[key_name_admin(owner)] has violently become a Mask of Nar'sie")
|
||||
owner.make_into_mask(1,1)
|
||||
else
|
||||
return
|
||||
else
|
||||
to_chat(owner, "\b You cannot become a mask of Nar'Sie because a Mask already exists.")
|
||||
mask_has_been_found()
|
||||
return
|
||||
|
||||
|
||||
/obj/cult_viewpoint/proc/active_mask()
|
||||
for(var/mob/spirit/mask/currentMask in spirits)
|
||||
if(currentMask.is_active())
|
||||
return TRUE
|
||||
return FALSE
|
||||
|
||||
|
||||
/obj/cult_viewpoint/proc/handle_missing_mask()
|
||||
if(active_mask())
|
||||
mask_has_been_found()
|
||||
else
|
||||
mask_is_missing()
|
||||
|
||||
|
||||
/obj/cult_viewpoint/proc/mask_has_been_found()
|
||||
for(var/obj/cult_viewpoint/viewpoint in cult_viewpoints)
|
||||
if(viewpoint.verbs.Find(/obj/cult_viewpoint/proc/become_mask))
|
||||
viewpoint.verbs-=/obj/cult_viewpoint/proc/become_mask
|
||||
|
||||
|
||||
/obj/cult_viewpoint/proc/mask_is_missing()
|
||||
for(var/obj/cult_viewpoint/viewpoint in cult_viewpoints)
|
||||
if(!viewpoint.verbs.Find(/obj/cult_viewpoint/proc/become_mask))
|
||||
viewpoint.verbs+=/obj/cult_viewpoint/proc/become_mask
|
||||
|
||||
|
||||
/proc/getCultViewpoint(var/mob/currentMob)
|
||||
for(var/obj/cult_viewpoint/currentView in currentMob)
|
||||
return currentView
|
||||
return FALSE
|
||||
|
||||
|
||||
#undef FAVOR_PLEASED
|
||||
#undef FAVOR_INDIFFERENT
|
||||
#undef FAVOR_DISPLEASED
|
||||
@@ -171,6 +171,14 @@
|
||||
/mob/proc/AdjustSlur()
|
||||
return
|
||||
|
||||
/mob/proc/CultSlur()
|
||||
return
|
||||
|
||||
/mob/proc/SetCultSlur()
|
||||
return
|
||||
|
||||
/mob/proc/AdjustCultSlur()
|
||||
return
|
||||
|
||||
/mob/proc/Stun()
|
||||
return
|
||||
|
||||
@@ -42,56 +42,6 @@
|
||||
qdel(src)
|
||||
return O
|
||||
|
||||
/mob/living/carbon/human/make_into_mask(var/should_gib = 0)
|
||||
for(var/t in organs)
|
||||
qdel(t)
|
||||
return ..(should_gib)
|
||||
|
||||
|
||||
/mob/proc/make_into_mask(var/should_gib = 0, var/should_remove_items = 0)
|
||||
|
||||
if(!should_gib)
|
||||
icon = null
|
||||
invisibility = 101
|
||||
|
||||
if(!should_remove_items)
|
||||
for(var/obj/item/W in src)
|
||||
unEquip(W)
|
||||
|
||||
var/mob/spirit/mask/new_spirit = new()
|
||||
|
||||
if(mind)
|
||||
new_spirit.mind = mind
|
||||
new_spirit.mind.assigned_role = "Mask"
|
||||
new_spirit.mind.original = new_spirit
|
||||
|
||||
new_spirit.key = key
|
||||
new_spirit.loc=loc
|
||||
|
||||
if(should_gib)
|
||||
spawn(0)
|
||||
src.gib() // gib the body
|
||||
else
|
||||
spawn(0)//To prevent the proc from returning null.
|
||||
src.visible_message( \
|
||||
"[src] disappears into the shadows, never to be seen again.", \
|
||||
"You disappear into the shadows, never to be seen again.", \
|
||||
"You hear strange noise, you can't quite place it.")
|
||||
qdel(src)
|
||||
|
||||
to_chat(new_spirit, "<font color=\"purple\"><b><i>You are a Mask of Nar'sie now. You are a tiny fragment of the unknowable entity that is the god.</b></i></font>")
|
||||
to_chat(new_spirit, "<font color=\"purple\"><b><i>Your job is to help your acolytes complete their goals. Be spooky. Do evil.</b></i></font>")
|
||||
|
||||
new_spirit.set_name()
|
||||
|
||||
// let spirits identify cultists
|
||||
if(ticker.mode)
|
||||
ticker.mode.add_cult_icon_to_spirit(new_spirit)
|
||||
|
||||
// highlander test
|
||||
there_can_be_only_one_mask(new_spirit)
|
||||
|
||||
return new_spirit
|
||||
|
||||
|
||||
//human -> robot
|
||||
|
||||
Reference in New Issue
Block a user