mirror of
https://github.com/yogstation13/Yogstation.git
synced 2025-02-26 09:04:50 +00:00
Removes Hand of God gamemode.
This commit is contained in:
@@ -30,16 +30,14 @@
|
||||
#define ANTAG_HUD_OPS 8
|
||||
#define ANTAG_HUD_WIZ 9
|
||||
#define ANTAG_HUD_SHADOW 10
|
||||
#define ANTAG_HUD_HOG_BLUE 11
|
||||
#define ANTAG_HUD_HOG_RED 12
|
||||
#define ANTAG_HUD_TRAITOR 13
|
||||
#define ANTAG_HUD_NINJA 14
|
||||
#define ANTAG_HUD_CHANGELING 15
|
||||
#define ANTAG_HUD_ABDUCTOR 16
|
||||
#define ANTAG_HUD_DEVIL 17
|
||||
#define ANTAG_HUD_SINTOUCHED 18
|
||||
#define ANTAG_HUD_SOULLESS 19
|
||||
#define ANTAG_HUD_CLOCKWORK 20
|
||||
#define ANTAG_HUD_TRAITOR 11
|
||||
#define ANTAG_HUD_NINJA 12
|
||||
#define ANTAG_HUD_CHANGELING 13
|
||||
#define ANTAG_HUD_ABDUCTOR 14
|
||||
#define ANTAG_HUD_DEVIL 15
|
||||
#define ANTAG_HUD_SINTOUCHED 16
|
||||
#define ANTAG_HUD_SOULLESS 17
|
||||
#define ANTAG_HUD_CLOCKWORK 18
|
||||
|
||||
// Notification action types
|
||||
#define NOTIFY_JUMP "jump"
|
||||
|
||||
@@ -21,8 +21,6 @@
|
||||
#define ROLE_GANG "gangster"
|
||||
#define ROLE_ABDUCTOR "abductor"
|
||||
#define ROLE_REVENANT "revenant"
|
||||
#define ROLE_HOG_GOD "hand of god: god"
|
||||
#define ROLE_HOG_CULTIST "hand of god: cultist"
|
||||
#define ROLE_DEVIL "devil"
|
||||
#define ROLE_SERVANT_OF_RATVAR "servant of Ratvar"
|
||||
|
||||
@@ -45,8 +43,6 @@ var/global/list/special_roles = list(
|
||||
ROLE_GANG = /datum/game_mode/gang,
|
||||
ROLE_REVENANT,
|
||||
ROLE_ABDUCTOR = /datum/game_mode/abduction,
|
||||
ROLE_HOG_GOD = /datum/game_mode/hand_of_god,
|
||||
ROLE_HOG_CULTIST = /datum/game_mode/hand_of_god,
|
||||
ROLE_DEVIL = /datum/game_mode/devil,
|
||||
ROLE_SERVANT_OF_RATVAR = /datum/game_mode/clockwork_cult,
|
||||
)
|
||||
|
||||
@@ -11,31 +11,3 @@
|
||||
if(client && !hud_used)
|
||||
hud_used = new /datum/hud/brain(src)
|
||||
|
||||
/datum/hud/hog_god/New(mob/owner)
|
||||
..()
|
||||
healths = new /obj/screen/healths/deity()
|
||||
infodisplay += healths
|
||||
|
||||
deity_power_display = new /obj/screen/deity_power_display()
|
||||
infodisplay += deity_power_display
|
||||
|
||||
deity_follower_display = new /obj/screen/deity_follower_display()
|
||||
infodisplay += deity_follower_display
|
||||
|
||||
|
||||
/mob/camera/god/create_mob_hud()
|
||||
if(client && !hud_used)
|
||||
hud_used = new /datum/hud/hog_god(src)
|
||||
|
||||
/obj/screen/deity_power_display
|
||||
name = "Faith"
|
||||
icon_state = "deity_power"
|
||||
screen_loc = ui_deitypower
|
||||
layer = HUD_LAYER
|
||||
|
||||
/obj/screen/deity_follower_display
|
||||
name = "Followers"
|
||||
icon_state = "deity_followers"
|
||||
screen_loc = ui_deityfollowers
|
||||
layer = HUD_LAYER
|
||||
|
||||
|
||||
@@ -12,8 +12,6 @@ var/datum/atom_hud/huds = list( \
|
||||
ANTAG_HUD_OPS = new/datum/atom_hud/antag(), \
|
||||
ANTAG_HUD_WIZ = new/datum/atom_hud/antag(), \
|
||||
ANTAG_HUD_SHADOW = new/datum/atom_hud/antag(), \
|
||||
ANTAG_HUD_HOG_BLUE = new/datum/atom_hud/antag(),\
|
||||
ANTAG_HUD_HOG_RED = new/datum/atom_hud/antag(),\
|
||||
ANTAG_HUD_TRAITOR = new/datum/atom_hud/antag/hidden(),\
|
||||
ANTAG_HUD_NINJA = new/datum/atom_hud/antag/hidden(),\
|
||||
ANTAG_HUD_CHANGELING = new/datum/atom_hud/antag/hidden(),\
|
||||
|
||||
@@ -174,16 +174,6 @@
|
||||
ticker.mode.remove_gangster(src,0,1,1)
|
||||
remove_objectives()
|
||||
|
||||
/datum/mind/proc/remove_hog_follower_prophet()
|
||||
ticker.mode.red_deity_followers -= src
|
||||
ticker.mode.red_deity_prophets -= src
|
||||
ticker.mode.blue_deity_prophets -= src
|
||||
ticker.mode.blue_deity_followers -= src
|
||||
ticker.mode.update_hog_icons_removed(src, "red")
|
||||
ticker.mode.update_hog_icons_removed(src, "blue")
|
||||
|
||||
|
||||
|
||||
/datum/mind/proc/remove_antag_equip()
|
||||
var/list/Mob_Contents = current.get_contents()
|
||||
for(var/obj/item/I in Mob_Contents)
|
||||
@@ -221,12 +211,6 @@
|
||||
else if(is_gangster(creator))
|
||||
ticker.mode.add_gangster(src, creator.mind.gang_datum, TRUE)
|
||||
|
||||
else if(is_handofgod_redcultist(creator) || is_handofgod_redprophet(creator))
|
||||
ticker.mode.add_hog_follower(src, "Red")
|
||||
|
||||
else if(is_handofgod_bluecultist(creator) || is_handofgod_blueprophet(creator))
|
||||
ticker.mode.add_hog_follower(src, "Blue")
|
||||
|
||||
else if(is_revolutionary_in_general(creator))
|
||||
ticker.mode.add_revolutionary(src)
|
||||
|
||||
@@ -490,38 +474,6 @@
|
||||
|
||||
sections["traitor"] = text
|
||||
|
||||
/** HAND OF GOD **/
|
||||
text = "hand of god"
|
||||
if(ticker.mode.config_tag == "handofgod")
|
||||
text = uppertext(text)
|
||||
text = "<i><b>[text]</b></i>: "
|
||||
if (src in ticker.mode.red_deities)
|
||||
text += "<b>RED GOD</b>|<a href='?src=\ref[src];handofgod=red prophet'>red prophet</a>|<a href='?src=\ref[src];handofgod=red follower'>red follower</a>|<a href='?src=\ref[src];handofgod=clear'>employee</a>|<a href='?src=\ref[src];handofgod=blue god'>blue god</a>|<a href='?src=\ref[src];handofgod=blue prophet'>blue prophet</a>|<a href='?src=\ref[src];handofgod=blue follower'>blue follower</a>"
|
||||
else if(src in ticker.mode.red_deity_prophets)
|
||||
text += "<a href='?src=\ref[src];handofgod=red god'>red god</a>|<b>RED PROPHET</b>|<a href='?src=\ref[src];handofgod=red follower'>red follower</a>|<a href='?src=\ref[src];handofgod=clear'>employee</a>|<a href='?src=\ref[src];handofgod=blue god'>blue god</a>|<a href='?src=\ref[src];handofgod=blue prophet'>blue prophet</a>|<a href='?src=\ref[src];handofgod=blue follower'>blue follower</a>"
|
||||
else if (src in ticker.mode.red_deity_followers)
|
||||
text += "<a href='?src=\ref[src];handofgod=red god'>red god</a>|<a href='?src=\ref[src];handofgod=red prophet'>red prophet</a>|<b>RED FOLLOWER</b>|<a href='?src=\ref[src];handofgod=clear'>employee</a>|<a href='?src=\ref[src];handofgod=blue god'>blue god</a>|<a href='?src=\ref[src];handofgod=blue prophet'>blue prophet</a>|<a href='?src=\ref[src];handofgod=blue follower'>blue follower</a>"
|
||||
else if (src in ticker.mode.blue_deities)
|
||||
text += "<a href='?src=\ref[src];handofgod=red god'>red god</a>|<a href='?src=\ref[src];handofgod=red prophet'>red prophet</a>|<a href='?src=\ref[src];handofgod=red follower'>red follower</a>|<a href='?src=\ref[src];handofgod=clear'>employee</a>|<b>BLUE GOD</b>|<a href='?src=\ref[src];handofgod=blue prophet'>blue prophet</a>|<a href='?src=\ref[src];handofgod=blue follower'>blue follower</a>"
|
||||
else if (src in ticker.mode.blue_deity_prophets)
|
||||
text += "<a href='?src=\ref[src];handofgod=red god'>red god</a>|<a href='?src=\ref[src];handofgod=red prophet'>red prophet</a>|<a href='?src=\ref[src];handofgod=red follower'>red follower</a>|<a href='?src=\ref[src];handofgod=clear'>employee</a>|<a href='?src=\ref[src];handofgod=blue god'>blue god</a>|<b>BLUE PROPHET</b>|<a href='?src=\ref[src];handofgod=blue follower'>blue follower</a>"
|
||||
else if (src in ticker.mode.blue_deity_followers)
|
||||
text += "<a href='?src=\ref[src];handofgod=red god'>red god</a>|<a href='?src=\ref[src];handofgod=red prophet'>red prophet</a>|<a href='?src=\ref[src];handofgod=red follower'>red follower</a>|<a href='?src=\ref[src];handofgod=clear'>employee</a>|<a href='?src=\ref[src];handofgod=blue god'>blue god</a>|<a href='?src=\ref[src];handofgod=blue prophet'>blue prophet</a>|<b>BLUE FOLLOWER</b>"
|
||||
else
|
||||
text += "<a href='?src=\ref[src];handofgod=red god'>red god</a>|<a href='?src=\ref[src];handofgod=red prophet'>red prophet</a>|<a href='?src=\ref[src];handofgod=red follower'>red follower</a>|<B>EMPLOYEE</b>|<a href='?src=\ref[src];handofgod=blue god'>blue god</a>|<a href='?src=\ref[src];handofgod=blue prophet'>blue prophet</a>|<a href='?src=\ref[src];handofgod=blue follower'>blue follower</a>"
|
||||
|
||||
if(current && current.client && (ROLE_HOG_GOD in current.client.prefs.be_special))
|
||||
text += "|HOG God Enabled in Prefs"
|
||||
else
|
||||
text += "|HOG God Disabled in Prefs"
|
||||
|
||||
if(current && current.client && (ROLE_HOG_CULTIST in current.client.prefs.be_special))
|
||||
text += "|HOG Cultist Enabled in Prefs"
|
||||
else
|
||||
text += "|HOG Disabled in Prefs"
|
||||
|
||||
sections["follower"] = text
|
||||
|
||||
if(ishuman(current) || ismonkey(current))
|
||||
|
||||
/** CHANGELING ***/
|
||||
@@ -696,7 +648,7 @@
|
||||
if(!def_value)//If it's a custom objective, it will be an empty string.
|
||||
def_value = "custom"
|
||||
|
||||
var/new_obj_type = input("Select objective type:", "Objective type", def_value) as null|anything in list("assassinate", "maroon", "debrain", "protect", "destroy", "prevent", "hijack", "escape", "survive", "martyr", "steal", "download", "nuclear", "capture", "absorb", "custom","follower block (HOG)","build (HOG)","deicide (HOG)", "follower escape (HOG)", "sacrifice prophet (HOG)")
|
||||
var/new_obj_type = input("Select objective type:", "Objective type", def_value) as null|anything in list("assassinate", "maroon", "debrain", "protect", "destroy", "prevent", "hijack", "escape", "survive", "martyr", "steal", "download", "nuclear", "capture", "absorb", "custom")
|
||||
if (!new_obj_type)
|
||||
return
|
||||
|
||||
@@ -798,22 +750,6 @@
|
||||
new_objective.owner = src
|
||||
new_objective.target_amount = target_number
|
||||
|
||||
if("follower block (HOG)")
|
||||
new_objective = new /datum/objective/follower_block
|
||||
new_objective.owner = src
|
||||
if("build (HOG)")
|
||||
new_objective = new /datum/objective/build
|
||||
new_objective.owner = src
|
||||
if("deicide (HOG)")
|
||||
new_objective = new /datum/objective/deicide
|
||||
new_objective.owner = src
|
||||
if("follower escape (HOG)")
|
||||
new_objective = new /datum/objective/escape_followers
|
||||
new_objective.owner = src
|
||||
if("sacrifice prophet (HOG)")
|
||||
new_objective = new /datum/objective/sacrifice_prophet
|
||||
new_objective.owner = src
|
||||
|
||||
if ("custom")
|
||||
var/expl = stripped_input(usr, "Custom objective:", "Objective", objective ? objective.explanation_text : "")
|
||||
if (!expl)
|
||||
@@ -850,46 +786,6 @@
|
||||
objective.completed = !objective.completed
|
||||
log_admin("[key_name(usr)] toggled the win state for [current]'s objective: [objective.explanation_text]")
|
||||
|
||||
else if (href_list["handofgod"])
|
||||
switch(href_list["handofgod"])
|
||||
if("clear") //wipe handofgod status
|
||||
if((src in ticker.mode.red_deity_followers) || (src in ticker.mode.blue_deity_followers) || (src in ticker.mode.red_deity_prophets) || (src in ticker.mode.blue_deity_prophets))
|
||||
remove_hog_follower_prophet()
|
||||
current << "<span class='danger'><B>You have been brainwashed... again! Your faith is no more!</B></span>"
|
||||
message_admins("[key_name_admin(usr)] has de-hand of god'ed [current].")
|
||||
log_admin("[key_name(usr)] has de-hand of god'ed [current].")
|
||||
|
||||
if("red follower")
|
||||
make_Handofgod_follower("red")
|
||||
message_admins("[key_name_admin(usr)] has red follower'ed [current].")
|
||||
log_admin("[key_name(usr)] has red follower'ed [current].")
|
||||
|
||||
if("red prophet")
|
||||
make_Handofgod_prophet("red")
|
||||
message_admins("[key_name_admin(usr)] has red prophet'ed [current].")
|
||||
log_admin("[key_name(usr)] has red prophet'ed [current].")
|
||||
|
||||
if("blue follower")
|
||||
make_Handofgod_follower("blue")
|
||||
message_admins("[key_name_admin(usr)] has blue follower'ed [current].")
|
||||
log_admin("[key_name(usr)] has blue follower'ed [current].")
|
||||
|
||||
if("blue prophet")
|
||||
make_Handofgod_prophet("blue")
|
||||
message_admins("[key_name_admin(usr)] has blue prophet'ed [current].")
|
||||
log_admin("[key_name(usr)] has blue prophet'ed [current].")
|
||||
|
||||
if("red god")
|
||||
make_Handofgod_god("red")
|
||||
message_admins("[key_name_admin(usr)] has red god'ed [current].")
|
||||
log_admin("[key_name(usr)] has red god'ed [current].")
|
||||
|
||||
if("blue god")
|
||||
make_Handofgod_god("blue")
|
||||
message_admins("[key_name_admin(usr)] has blue god'ed [current].")
|
||||
log_admin("[key_name(usr)] has blue god'ed [current].")
|
||||
|
||||
|
||||
else if (href_list["revolution"])
|
||||
switch(href_list["revolution"])
|
||||
if("clear")
|
||||
@@ -1563,119 +1459,6 @@
|
||||
L = agent_landmarks[team]
|
||||
H.loc = L.loc
|
||||
|
||||
|
||||
/datum/mind/proc/make_Handofgod_follower(colour)
|
||||
. = 0
|
||||
switch(colour)
|
||||
if("red")
|
||||
//Remove old allegiances
|
||||
if(src in ticker.mode.blue_deity_followers || src in ticker.mode.blue_deity_prophets)
|
||||
current << "<span class='danger'><B>You are no longer a member of the Blue cult!<B></span>"
|
||||
|
||||
ticker.mode.blue_deity_followers -= src
|
||||
ticker.mode.blue_deity_prophets -= src
|
||||
current.faction |= "red god"
|
||||
current.faction -= "blue god"
|
||||
|
||||
if(src in ticker.mode.red_deity_prophets)
|
||||
current << "<span class='danger'><B>You have lost the connection with your deity, but you still believe in their grand design, You are no longer a prophet!</b></span>"
|
||||
ticker.mode.red_deity_prophets -= src
|
||||
|
||||
ticker.mode.red_deity_followers |= src
|
||||
current << "<span class='danger'><B>You are now a follower of the red cult's god!</b></span>"
|
||||
|
||||
special_role = "Hand of God: Red Follower"
|
||||
. = 1
|
||||
if("blue")
|
||||
//Remove old allegiances
|
||||
if(src in ticker.mode.red_deity_followers || src in ticker.mode.red_deity_prophets)
|
||||
current << "<span class='danger'><B>You are no longer a member of the Red cult!<B></span>"
|
||||
|
||||
ticker.mode.red_deity_followers -= src
|
||||
ticker.mode.red_deity_prophets -= src
|
||||
current.faction -= "red god"
|
||||
current.faction |= "blue god"
|
||||
|
||||
if(src in ticker.mode.blue_deity_prophets)
|
||||
current << "<span class='danger'><B>You have lost the connection with your deity, but you still believe in their grand design, You are no longer a prophet!</b></span>"
|
||||
ticker.mode.blue_deity_prophets -= src
|
||||
|
||||
ticker.mode.blue_deity_followers |= src
|
||||
current << "<span class='danger'><B>You are now a follower of the blue cult's god!</b></span>"
|
||||
|
||||
special_role = "Hand of God: Blue Follower"
|
||||
. = 1
|
||||
else
|
||||
return 0
|
||||
|
||||
ticker.mode.update_hog_icons_removed(src,"red")
|
||||
ticker.mode.update_hog_icons_removed(src,"blue")
|
||||
//ticker.mode.greet_hog_follower(src,colour)
|
||||
ticker.mode.update_hog_icons_added(src, colour)
|
||||
|
||||
/datum/mind/proc/make_Handofgod_prophet(colour)
|
||||
. = 0
|
||||
switch(colour)
|
||||
if("red")
|
||||
//Remove old allegiances
|
||||
|
||||
if(src in ticker.mode.blue_deity_followers || src in ticker.mode.blue_deity_prophets)
|
||||
current << "<span class='danger'><B>You are no longer a member of the Blue cult!<B></span>"
|
||||
current.faction -= "blue god"
|
||||
current.faction |= "red god"
|
||||
|
||||
ticker.mode.blue_deity_followers -= src
|
||||
ticker.mode.blue_deity_prophets -= src
|
||||
ticker.mode.red_deity_followers -= src
|
||||
|
||||
ticker.mode.red_deity_prophets |= src
|
||||
current << "<span class='danger'><B>You are now a prophet of the red cult's god!</b></span>"
|
||||
|
||||
special_role = "Hand of God: Red Prophet"
|
||||
. = 1
|
||||
if("blue")
|
||||
//Remove old allegiances
|
||||
|
||||
if(src in ticker.mode.red_deity_followers || src in ticker.mode.red_deity_prophets)
|
||||
current << "<span class='danger'><B>You are no longer a member of the Red cult!<B></span>"
|
||||
current.faction -= "red god"
|
||||
current.faction |= "blue god"
|
||||
|
||||
ticker.mode.red_deity_followers -= src
|
||||
ticker.mode.red_deity_prophets -= src
|
||||
ticker.mode.blue_deity_followers -= src
|
||||
|
||||
ticker.mode.blue_deity_prophets |= src
|
||||
current << "<span class='danger'><B>You are now a prophet of the blue cult's god!</b></span>"
|
||||
|
||||
special_role = "Hand of God: Blue Prophet"
|
||||
. = 1
|
||||
|
||||
else
|
||||
return 0
|
||||
|
||||
ticker.mode.update_hog_icons_removed(src,"red")
|
||||
ticker.mode.update_hog_icons_removed(src,"blue")
|
||||
ticker.mode.greet_hog_follower(src,colour)
|
||||
ticker.mode.update_hog_icons_added(src, colour)
|
||||
|
||||
/datum/mind/proc/make_Handofgod_god(colour)
|
||||
switch(colour)
|
||||
if("red")
|
||||
current.become_god("red")
|
||||
ticker.mode.add_god(src,"red")
|
||||
if("blue")
|
||||
current.become_god("blue")
|
||||
ticker.mode.add_god(src,"blue")
|
||||
else
|
||||
return 0
|
||||
ticker.mode.forge_deity_objectives(src)
|
||||
ticker.mode.remove_hog_follower(src,0)
|
||||
ticker.mode.update_hog_icons_added(src, colour)
|
||||
// ticker.mode.greet_hog_follower(src,colour)
|
||||
return 1
|
||||
|
||||
|
||||
/datum/mind/proc/AddSpell(obj/effect/proc_holder/spell/S)
|
||||
spell_list += S
|
||||
S.action.Grant(current)
|
||||
|
||||
@@ -539,7 +539,6 @@
|
||||
ticker.mode.remove_cultist(newborgie, 0, 0)
|
||||
ticker.mode.remove_revolutionary(newborgie, 0)
|
||||
ticker.mode.remove_gangster(newborgie, 0, remove_bosses=1)
|
||||
ticker.mode.remove_hog_follower(newborgie, 0)
|
||||
remove_servant_of_ratvar(newborgie.current, TRUE)
|
||||
|
||||
|
||||
|
||||
@@ -1,476 +0,0 @@
|
||||
|
||||
var/global/list/global_handofgod_traptypes = list()
|
||||
var/global/list/global_handofgod_structuretypes = list()
|
||||
|
||||
#define CONDUIT_RANGE 15
|
||||
|
||||
|
||||
/datum/game_mode
|
||||
var/list/datum/mind/red_deities = list()
|
||||
var/list/datum/mind/red_deity_prophets = list()
|
||||
var/list/datum/mind/red_deity_followers = list()
|
||||
|
||||
var/list/datum/mind/blue_deities = list()
|
||||
var/list/datum/mind/blue_deity_prophets = list()
|
||||
var/list/datum/mind/blue_deity_followers = list()
|
||||
|
||||
var/list/datum/mind/unassigned_followers = list() //for roundstart team assigning
|
||||
var/list/datum/mind/assigned_to_red = list()
|
||||
var/list/datum/mind/assigned_to_blue = list()
|
||||
|
||||
|
||||
/datum/game_mode/hand_of_god
|
||||
name = "hand of god"
|
||||
config_tag = "handofgod"
|
||||
antag_flag = ROLE_HOG_CULTIST //Followers use ROLE_HOG_CULTIST, Gods are picked later on with ROLE_HOG_GOD
|
||||
|
||||
required_players = 25
|
||||
required_enemies = 8
|
||||
recommended_enemies = 8
|
||||
restricted_jobs = list("Chaplain","AI", "Cyborg", "Security Officer", "Warden", "Detective", "Head of Security", "Captain", "Head of Personnel")
|
||||
|
||||
announce_span = "danger"
|
||||
announce_text = "Two cults are trying to overthrow one another!\n\
|
||||
<span class='warning'>Gods</span>: Protect your nexus and eliminate the enemy god.\n\
|
||||
<span class='danger'><i>Prophets</i></span>: Lead your cult by your deity's will.\n\
|
||||
<span class='danger'>Followers</span>: Follow your prophet's orders and lead your deity to victory.\n\
|
||||
<span class='notice'>Crew</span>: Destroy both cults before they can grow in strength."
|
||||
|
||||
|
||||
/////////////
|
||||
//Pre setup//
|
||||
/////////////
|
||||
|
||||
/datum/game_mode/hand_of_god/pre_setup()
|
||||
if(config.protect_roles_from_antagonist)
|
||||
restricted_jobs += protected_jobs
|
||||
|
||||
if(config.protect_assistant_from_antagonist)
|
||||
restricted_jobs += "Assistant"
|
||||
|
||||
for(var/F in 1 to recommended_enemies)
|
||||
if(!antag_candidates.len)
|
||||
break
|
||||
var/datum/mind/follower = pick_n_take(antag_candidates)
|
||||
unassigned_followers += follower
|
||||
follower.restricted_roles = restricted_jobs
|
||||
log_game("[follower.key] (ckey) has been selected as a follower, however teams have not been decided yet.")
|
||||
|
||||
while(unassigned_followers.len > (required_enemies / 2))
|
||||
var/datum/mind/chosen = pick_n_take(unassigned_followers)
|
||||
add_hog_follower(chosen,"red")
|
||||
|
||||
while(unassigned_followers.len)
|
||||
var/datum/mind/chosen = pick_n_take(unassigned_followers)
|
||||
add_hog_follower(chosen,"blue")
|
||||
|
||||
return 1
|
||||
|
||||
|
||||
//////////////
|
||||
//Post Setup//
|
||||
//////////////
|
||||
|
||||
//Pick a follower to uplift into a god
|
||||
/datum/game_mode/hand_of_god/post_setup()
|
||||
|
||||
//Find viable red god
|
||||
var/list/red_god_possibilities = get_players_for_role(ROLE_HOG_GOD)
|
||||
red_god_possibilities &= red_deity_followers //followers only
|
||||
if(!red_god_possibilities.len) //No candidates? just pick any follower regardless of prefs
|
||||
red_god_possibilities = red_deity_followers
|
||||
|
||||
//Make red god
|
||||
var/datum/mind/red_god = pick_n_take(red_god_possibilities)
|
||||
if(red_god)
|
||||
red_god.current.become_god("red")
|
||||
remove_hog_follower(red_god,0)
|
||||
add_god(red_god,"red")
|
||||
|
||||
//Find viable blue god
|
||||
var/list/blue_god_possibilities = get_players_for_role(ROLE_HOG_GOD)
|
||||
blue_god_possibilities &= blue_deity_followers //followers only
|
||||
if(!blue_god_possibilities.len) //No candidates? just pick any follower regardless of prefs
|
||||
blue_god_possibilities = blue_deity_followers
|
||||
|
||||
//Make blue god
|
||||
var/datum/mind/blue_god = pick_n_take(blue_god_possibilities)
|
||||
if(blue_god)
|
||||
blue_god.current.become_god("blue")
|
||||
remove_hog_follower(blue_god,0)
|
||||
add_god(blue_god,"blue")
|
||||
|
||||
|
||||
//Forge objectives
|
||||
//This is done here so that both gods exist
|
||||
if(red_god)
|
||||
ticker.mode.forge_deity_objectives(red_god)
|
||||
if(blue_god)
|
||||
ticker.mode.forge_deity_objectives(blue_god)
|
||||
|
||||
|
||||
..()
|
||||
|
||||
///////////////////
|
||||
//Objective Procs//
|
||||
///////////////////
|
||||
|
||||
/datum/game_mode/proc/forge_deity_objectives(datum/mind/deity)
|
||||
switch(rand(1,100))
|
||||
if(1 to 30)
|
||||
var/datum/objective/deicide/deicide = new
|
||||
deicide.owner = deity
|
||||
if(deicide.find_target())//Hard to kill the other god if there is none
|
||||
deity.objectives += deicide
|
||||
|
||||
if(!(locate(/datum/objective/escape_followers) in deity.objectives))
|
||||
var/datum/objective/escape_followers/recruit = new
|
||||
recruit.owner = deity
|
||||
deity.objectives += recruit
|
||||
recruit.gen_amount_goal(8, 12)
|
||||
|
||||
if(31 to 60)
|
||||
var/datum/objective/sacrifice_prophet/sacrifice = new
|
||||
sacrifice.owner = deity
|
||||
deity.objectives += sacrifice
|
||||
|
||||
if(!(locate(/datum/objective/escape_followers) in deity.objectives))
|
||||
var/datum/objective/escape_followers/recruit = new
|
||||
recruit.owner = deity
|
||||
deity.objectives += recruit
|
||||
recruit.gen_amount_goal(8, 12)
|
||||
|
||||
if(61 to 85)
|
||||
var/datum/objective/build/build = new
|
||||
build.owner = deity
|
||||
deity.objectives += build
|
||||
build.gen_amount_goal(8, 16)
|
||||
|
||||
var/datum/objective/sacrifice_prophet/sacrifice = new
|
||||
sacrifice.owner = deity
|
||||
deity.objectives += sacrifice
|
||||
|
||||
if(!(locate(/datum/objective/escape_followers) in deity.objectives))
|
||||
var/datum/objective/escape_followers/recruit = new
|
||||
recruit.owner = deity
|
||||
deity.objectives += recruit
|
||||
recruit.gen_amount_goal(8, 12)
|
||||
|
||||
else
|
||||
if (!locate(/datum/objective/follower_block) in deity.objectives)
|
||||
var/datum/objective/follower_block/block = new
|
||||
block.owner = deity
|
||||
deity.objectives += block
|
||||
|
||||
///////////////
|
||||
//Greet procs//
|
||||
///////////////
|
||||
|
||||
/datum/game_mode/proc/greet_hog_follower(datum/mind/follower_mind,colour)
|
||||
if(follower_mind in blue_deity_prophets || follower_mind in red_deity_prophets)
|
||||
follower_mind.current << "<span class='danger'><B>You have been appointed as the prophet of the [colour] deity! You are the only one who can communicate with your deity at will. Guide your followers, but be wary, for many will want you dead.</span>"
|
||||
else if(colour)
|
||||
follower_mind.current << "<span class='danger'><B>You are a follower of the [colour] cult's deity!</span>"
|
||||
else
|
||||
follower_mind.current << "<span class='danger'><B>You are a follower of a cult's deity!</span>"
|
||||
|
||||
|
||||
/////////////////
|
||||
//Convert procs//
|
||||
/////////////////
|
||||
|
||||
/datum/game_mode/proc/add_hog_follower(datum/mind/follower_mind, colour = "No Colour")
|
||||
var/mob/living/carbon/human/H = follower_mind.current
|
||||
if(isloyal(H))
|
||||
H << "<span class='danger'>Your mindshield implant blocked the influence of the [colour] deity. </span>"
|
||||
return 0
|
||||
if((follower_mind in red_deity_followers) || (follower_mind in red_deity_prophets) || (follower_mind in blue_deity_followers) || (follower_mind in blue_deity_prophets))
|
||||
H << "<span class='danger'>You already belong to a deity. Your strong faith has blocked out the conversion attempt by the followers of the [colour] deity.</span>"
|
||||
return 0
|
||||
var/obj/item/weapon/nullrod/N = H.null_rod_check()
|
||||
if(N)
|
||||
H << "<span class='danger'>Your holy weapon prevented the [colour] deity from brainwashing you.</span>"
|
||||
return 0
|
||||
|
||||
if(colour == "red")
|
||||
red_deity_followers += follower_mind
|
||||
if(colour == "blue")
|
||||
blue_deity_followers += follower_mind
|
||||
|
||||
H.faction |= "[colour] god"
|
||||
follower_mind.current << "<span class='danger'><FONT size = 3>You are now a follower of the [colour] deity! Follow your deity's prophet in order to complete your deity's objectives. Convert crewmembers to your cause by using your deity's nexus. And remember - there is no you, there is only the cult.</FONT></span>"
|
||||
update_hog_icons_added(follower_mind, colour)
|
||||
follower_mind.special_role = "Hand of God: [capitalize(colour)] Follower"
|
||||
follower_mind.current.attack_log += "\[[time_stamp()]\] <font color='red'>Has been converted to the [colour] follower cult!</font>"
|
||||
return 1
|
||||
|
||||
|
||||
/datum/game_mode/proc/add_god(datum/mind/god_mind, colour = "No Colour")
|
||||
remove_hog_follower(god_mind, announce = 0)
|
||||
if(colour == "red")
|
||||
red_deities += god_mind
|
||||
if(colour == "blue")
|
||||
blue_deities += god_mind
|
||||
god_mind.current.attack_log += "\[[time_stamp()]\] <font color='red'>Has been made into a [colour] deity!</font>"
|
||||
god_mind.special_role = "Hand of God: [colour] God"
|
||||
update_hog_icons_added(god_mind, colour)
|
||||
|
||||
//////////////////
|
||||
//Deconvert proc//
|
||||
//////////////////
|
||||
|
||||
/datum/game_mode/proc/remove_hog_follower(datum/mind/follower_mind, announce = 1)//deconverts both
|
||||
if(follower_mind.current)
|
||||
if(is_handofgod_cultist(follower_mind.current) || is_handofgod_prophet(follower_mind.current))
|
||||
follower_mind.remove_hog_follower_prophet()
|
||||
update_hog_icons_removed(follower_mind,"red")
|
||||
update_hog_icons_removed(follower_mind,"blue")
|
||||
|
||||
var/mob/living/carbon/human/H = follower_mind.current
|
||||
H.faction -= "red god"
|
||||
H.faction -= "blue god"
|
||||
|
||||
if(announce)
|
||||
follower_mind.current.attack_log += "\[[time_stamp()]\] <font color='red'>Has been deconverted from a deity's cult!</font>"
|
||||
follower_mind.current << "<span class='danger'><b>Your mind has been cleared from the brainwashing the followers have done to you. Now you serve yourself and the crew.</b></span>"
|
||||
for(var/mob/living/M in view(follower_mind.current))
|
||||
M << "[follower_mind.current] looks like their faith is shattered. They're no longer a cultist!"
|
||||
|
||||
|
||||
|
||||
//////////////////////
|
||||
// Mob helper procs //
|
||||
//////////////////////
|
||||
|
||||
/proc/is_handofgod_god(A)
|
||||
if(istype(A, /mob/camera/god))
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
/proc/is_handofgod_bluecultist(A)
|
||||
if(ishuman(A))
|
||||
var/mob/living/carbon/human/H = A
|
||||
if(H.mind)
|
||||
if(H.mind in ticker.mode.blue_deity_followers|ticker.mode.blue_deity_prophets)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
/proc/is_handofgod_redcultist(A)
|
||||
if(ishuman(A))
|
||||
var/mob/living/carbon/human/H = A
|
||||
if(H.mind)
|
||||
if(H.mind in ticker.mode.red_deity_followers|ticker.mode.red_deity_prophets)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
/proc/is_handofgod_blueprophet(A)
|
||||
if(ishuman(A))
|
||||
var/mob/living/carbon/human/H = A
|
||||
if(H.mind)
|
||||
if(H.mind in ticker.mode.blue_deity_prophets)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
/proc/is_handofgod_redprophet(A)
|
||||
if(ishuman(A))
|
||||
var/mob/living/carbon/human/H = A
|
||||
if(H.mind)
|
||||
if(H.mind in ticker.mode.red_deity_prophets)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
|
||||
/proc/is_handofgod_cultist(A) //any of them what so ever, blue, red, hot pink, whatever.
|
||||
if(is_handofgod_redcultist(A))
|
||||
return 1
|
||||
if(is_handofgod_bluecultist(A))
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
/proc/is_handofgod_prophet(A) //any of them what so ever, blue, red, hot pink, whatever
|
||||
if(ishuman(A))
|
||||
var/mob/living/carbon/human/H = A
|
||||
if(H.mind)
|
||||
if(H.mind in ticker.mode.blue_deity_prophets|ticker.mode.red_deity_prophets)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
/mob/camera/god/proc/is_handofgod_myprophet(A)
|
||||
if(!ishuman(A))
|
||||
return 0
|
||||
var/mob/living/carbon/human/H = A
|
||||
if(!H.mind)
|
||||
return 0
|
||||
if(side == "red")
|
||||
if(H.mind in ticker.mode.red_deity_prophets)
|
||||
return 1
|
||||
else if(side == "blue")
|
||||
if(H.mind in ticker.mode.blue_deity_prophets)
|
||||
return 1
|
||||
|
||||
|
||||
/mob/camera/god/proc/is_handofgod_myfollowers(mob/A)
|
||||
if(!ishuman(A))
|
||||
return 0
|
||||
var/mob/living/carbon/human/H = A
|
||||
if(!H.mind)
|
||||
return 0
|
||||
if(side == "red")
|
||||
if(H.mind in ticker.mode.red_deity_prophets|ticker.mode.red_deity_followers)
|
||||
return 1
|
||||
else if(side == "blue")
|
||||
if(H.mind in ticker.mode.blue_deity_prophets|ticker.mode.blue_deity_followers)
|
||||
return 1
|
||||
|
||||
//////////////////////
|
||||
//Roundend Reporting//
|
||||
//////////////////////
|
||||
|
||||
|
||||
/datum/game_mode/hand_of_god/declare_completion()
|
||||
if(red_deities.len)
|
||||
var/text = "<BR><font size=3 color='red'><B>The red cult:</b></font>"
|
||||
for(var/datum/mind/red_god in red_deities)
|
||||
var/godwin = 1
|
||||
|
||||
text += "<BR><B>[red_god.key]</B> was the red deity, <B>[red_god.name]</B> ("
|
||||
if(red_god.current)
|
||||
if(red_god.current.stat == DEAD)
|
||||
text += "died"
|
||||
else
|
||||
text += "survived"
|
||||
else
|
||||
text += "ceased existing"
|
||||
text += ")"
|
||||
if(red_deity_prophets.len)
|
||||
for(var/datum/mind/red_prophet in red_deity_prophets)
|
||||
text += "<BR>The red prophet was <B>[red_prophet.name]</B> (<B>[red_prophet.key]</B>)"
|
||||
else
|
||||
text += "<BR>the red prophet was killed for their beliefs."
|
||||
|
||||
text += "<BR><B>Red follower count: </B> [red_deity_followers.len]"
|
||||
text += "<BR><B>Red followers:</B> "
|
||||
for(var/datum/mind/player in red_deity_followers)
|
||||
text += "[player.name] ([player.key]), "
|
||||
|
||||
var/objectives = ""
|
||||
if(red_god.objectives.len)
|
||||
var/count = 1
|
||||
for(var/datum/objective/O in red_god.objectives)
|
||||
if(O.check_completion())
|
||||
objectives += "<BR><B>Objective #[count]</B>: [O.explanation_text] <font color='green'><B>Success!</B></font>"
|
||||
feedback_add_details("god_objective","[O.type]|SUCCESS")
|
||||
else
|
||||
objectives += "<BR><B>Objective #[count]</B>: [O.explanation_text] <font color='red'><B>Fail.</B></font>"
|
||||
feedback_add_details("god_objective","[O.type]|FAIL")
|
||||
godwin = 0
|
||||
count++
|
||||
|
||||
text += objectives
|
||||
|
||||
if(godwin)
|
||||
text += "<BR><font color='green'><B>The red cult and deity were successful!</B></font>"
|
||||
feedback_add_details("god_success","SUCCESS")
|
||||
else
|
||||
text += "<br><font color='red'><B>The red cult and deity have failed!</B></font>"
|
||||
feedback_add_details("god_success","FAIL")
|
||||
|
||||
text += "<BR>"
|
||||
|
||||
world << text
|
||||
|
||||
if(blue_deities.len)
|
||||
var/text = "<BR><font size=3 color='red'><B>The blue cult:</b></font>"
|
||||
for(var/datum/mind/blue_god in blue_deities)
|
||||
var/godwin = 1
|
||||
|
||||
text += "<BR><B>[blue_god.key]</B> was the blue deity, <B>[blue_god.name]</B> ("
|
||||
if(blue_god.current)
|
||||
if(blue_god.current.stat == DEAD)
|
||||
text += "died"
|
||||
else
|
||||
text += "survived"
|
||||
else
|
||||
text += "ceased existing"
|
||||
text += ")"
|
||||
if(blue_deity_prophets.len)
|
||||
for(var/datum/mind/blue_prophet in blue_deity_prophets)
|
||||
text += "<BR>The blue prophet was <B>[blue_prophet.name]</B> (<B>[blue_prophet.key]</B>)"
|
||||
else
|
||||
text += "<BR>the blue prophet was killed for their beliefs."
|
||||
|
||||
text += "<BR><B>Blue follower count: </B> [blue_deity_followers.len]"
|
||||
text += "<BR><B>Blue followers:</B> "
|
||||
for(var/datum/mind/player in blue_deity_followers)
|
||||
text += "[player.name] ([player.key])"
|
||||
|
||||
var/objectives = ""
|
||||
if(blue_god.objectives.len)
|
||||
var/count = 1
|
||||
for(var/datum/objective/O in blue_god.objectives)
|
||||
if(O.check_completion())
|
||||
objectives += "<BR><B>Objective #[count]</B>: [O.explanation_text] <font color='green'><B>Success!</B></font>"
|
||||
feedback_add_details("god_objective","[O.type]|SUCCESS")
|
||||
else
|
||||
objectives += "<BR><B>Objective #[count]</B>: [O.explanation_text] <font color='red'><B>Fail.</B></font>"
|
||||
feedback_add_details("god_objective","[O.type]|FAIL")
|
||||
godwin = 0
|
||||
count++
|
||||
|
||||
text += objectives
|
||||
|
||||
if(godwin)
|
||||
text += "<BR><font color='green'><B>The blue cult and deity were successful!</B></font>"
|
||||
feedback_add_details("god_success","SUCCESS")
|
||||
else
|
||||
text += "<BR><font color='red'><B>The blue cult and deity have failed!</B></font>"
|
||||
feedback_add_details("god_success","FAIL")
|
||||
|
||||
text += "<BR>"
|
||||
|
||||
world << text
|
||||
|
||||
..()
|
||||
return 1
|
||||
|
||||
|
||||
/datum/game_mode/proc/update_hog_icons_added(datum/mind/hog_mind,side)
|
||||
var/hud_key
|
||||
var/rank = 0
|
||||
if(side == "red")
|
||||
hud_key = ANTAG_HUD_HOG_RED
|
||||
if(is_handofgod_redprophet(hog_mind.current))
|
||||
rank = 1
|
||||
|
||||
else if(side == "blue")
|
||||
hud_key = ANTAG_HUD_HOG_BLUE
|
||||
if(is_handofgod_blueprophet(hog_mind.current))
|
||||
rank = 1
|
||||
|
||||
if(is_handofgod_god(hog_mind.current))
|
||||
rank = 2
|
||||
|
||||
if(hud_key)
|
||||
var/datum/atom_hud/antag/hog_hud = huds[hud_key]
|
||||
hog_hud.join_hud(hog_mind.current)
|
||||
set_antag_hud(hog_mind.current, "hog-[side]-[rank]")
|
||||
|
||||
|
||||
/datum/game_mode/proc/update_hog_icons_removed(datum/mind/hog_mind,side)
|
||||
var/hud_key
|
||||
if(side == "red")
|
||||
hud_key = ANTAG_HUD_HOG_RED
|
||||
else if(side == "blue")
|
||||
hud_key = ANTAG_HUD_HOG_BLUE
|
||||
|
||||
if(hud_key)
|
||||
var/datum/atom_hud/antag/hog_hud = huds[hud_key]
|
||||
hog_hud.leave_hud(hog_mind.current)
|
||||
set_antag_hud(hog_mind.current,null)
|
||||
@@ -1,28 +0,0 @@
|
||||
/* Prophet's innate godspeak */
|
||||
/datum/action/innate/godspeak
|
||||
name = "Godspeak"
|
||||
button_icon_state = "godspeak"
|
||||
check_flags = AB_CHECK_CONSCIOUS
|
||||
var/mob/camera/god/god = null
|
||||
|
||||
/datum/action/innate/godspeak/IsAvailable()
|
||||
if(..())
|
||||
if(god)
|
||||
return 1
|
||||
return 0
|
||||
|
||||
/datum/action/innate/godspeak/Activate()
|
||||
var/msg = input(owner,"Speak to your god","Godspeak","") as null|text
|
||||
if(!msg)
|
||||
return
|
||||
var/rendered = "<font color='[god.side]'><span class='game say'><i>Prophet [owner]:</i> <span class='message'>[msg]</span></span>"
|
||||
god << rendered
|
||||
owner << rendered
|
||||
for(var/mob/M in mob_list)
|
||||
if(isobserver(M))
|
||||
var/link = FOLLOW_LINK(M, owner)
|
||||
M << "[link] [rendered]"
|
||||
|
||||
/datum/action/innate/godspeak/Destroy()
|
||||
god = null
|
||||
return ..()
|
||||
@@ -1,290 +0,0 @@
|
||||
|
||||
/mob/camera/god
|
||||
name = "deity" //Auto changes to the player's deity name/random name
|
||||
real_name = "deity"
|
||||
icon = 'icons/mob/mob.dmi'
|
||||
icon_state = "marker"
|
||||
invisibility = 60
|
||||
see_in_dark = 0
|
||||
see_invisible = 55
|
||||
sight = SEE_TURFS | SEE_MOBS | SEE_OBJS | SEE_SELF
|
||||
languages_spoken = ALL
|
||||
languages_understood = ALL
|
||||
hud_possible = list(ANTAG_HUD)
|
||||
mouse_opacity = 0 //can't be clicked
|
||||
|
||||
var/faith = 100 //For initial prophet appointing/stupid purchase
|
||||
var/max_faith = 100
|
||||
var/side = "neutral" //Red or Blue for the gamemode
|
||||
var/obj/structure/divine/nexus/god_nexus = null //The source of the god's power in this realm, kill it and the god is kill
|
||||
var/nexus_required = FALSE //If the god dies from losing it's nexus, defaults to off so that gods don't instantly die at roundstart
|
||||
var/followers_required = 0 //Same as above
|
||||
var/alive_followers = 0
|
||||
var/list/structures = list()
|
||||
var/list/conduits = list()
|
||||
var/prophets_sacrificed_in_name = 0
|
||||
var/image/ghostimage = null //For observer with darkness off visiblity
|
||||
var/list/prophets = list()
|
||||
var/datum/action/innate/godspeak/speak2god
|
||||
|
||||
/mob/camera/god/New()
|
||||
..()
|
||||
update_icons()
|
||||
build_hog_construction_lists()
|
||||
|
||||
//Force nexuses after 15 minutes in hand of god mode
|
||||
if(ticker && ticker.mode && ticker.mode.name == "hand of god")
|
||||
addtimer(src, "forceplacenexus", 9000, FALSE)
|
||||
|
||||
|
||||
//Rebuilds the list based on the gamemode's lists
|
||||
//As they are the most accurate each tick
|
||||
/mob/camera/god/proc/get_my_followers()
|
||||
switch(side)
|
||||
if("red")
|
||||
. = ticker.mode.red_deity_followers|ticker.mode.red_deity_prophets
|
||||
if("blue")
|
||||
. = ticker.mode.blue_deity_followers|ticker.mode.blue_deity_prophets
|
||||
else
|
||||
. = list()
|
||||
|
||||
|
||||
/mob/camera/god/Destroy()
|
||||
var/list/followers = get_my_followers()
|
||||
for(var/datum/mind/F in followers)
|
||||
if(F.current)
|
||||
F.current << "<span class='danger'>Your god is DEAD!</span>"
|
||||
for(var/X in prophets)
|
||||
speak2god.Remove(X)
|
||||
ghost_darkness_images -= ghostimage
|
||||
updateallghostimages()
|
||||
return ..()
|
||||
|
||||
|
||||
|
||||
/mob/camera/god/proc/forceplacenexus()
|
||||
if(god_nexus)
|
||||
return
|
||||
|
||||
if(ability_cost(0,1,0))
|
||||
place_nexus()
|
||||
|
||||
else
|
||||
if(blobstart.len) //we're on invalid turf, try to pick from blobstart
|
||||
loc = pick(blobstart)
|
||||
place_nexus() //if blobstart fails, places on dense turf, but better than nothing
|
||||
src << "<span class='danger'>You failed to place your nexus, and it has been placed for you!</span>"
|
||||
|
||||
|
||||
/mob/camera/god/update_icons()
|
||||
icon_state = "[initial(icon_state)]-[side]"
|
||||
|
||||
if(ghostimage)
|
||||
ghost_darkness_images -= ghostimage
|
||||
|
||||
ghostimage = image(src.icon,src,src.icon_state)
|
||||
ghost_darkness_images |= ghostimage
|
||||
updateallghostimages()
|
||||
|
||||
|
||||
/mob/camera/god/Stat()
|
||||
..()
|
||||
if(statpanel("Status"))
|
||||
if(god_nexus)
|
||||
stat("Nexus health: ", god_nexus.health)
|
||||
stat("Followers: ", alive_followers)
|
||||
stat("Faith: ", "[faith]/[max_faith]")
|
||||
|
||||
|
||||
/mob/camera/god/Login()
|
||||
..()
|
||||
sync_mind()
|
||||
src << "<span class='notice'>You are a deity!</span>"
|
||||
src << "You are a deity and are worshipped by a cult! You are rather weak right now, but that will change as you gain more followers."
|
||||
src << "You will need to place an anchor to this world, a <b>Nexus</b>, in two minutes. If you don't, one will be placed immediately below you."
|
||||
src << "Your <b>Follower</b> count determines how many people believe in you and are a part of your cult."
|
||||
src << "Your <b>Nexus Integrity</b> tells you the condition of your nexus. If your nexus is destroyed, you will die. Place your Nexus on a safe, isolated place, that is still accessible to your followers."
|
||||
src << "Your <b>Faith</b> is used to interact with the world. This will regenerate on its own, and it goes faster when you have more followers and power pylons."
|
||||
src << "The first thing you should do after placing your nexus is to <b>appoint a prophet</b>. Only prophets can hear you talk, unless you use an expensive power."
|
||||
update_health_hud()
|
||||
|
||||
|
||||
/mob/camera/god/update_health_hud()
|
||||
if(god_nexus && hud_used && hud_used.healths)
|
||||
hud_used.healths.maptext = "<div align='center' valign='middle' style='position:relative; top:0px; left:6px'> <font color='lime'>[god_nexus.health] </font></div>"
|
||||
|
||||
|
||||
/mob/camera/god/proc/add_faith(faith_amt)
|
||||
if(faith_amt)
|
||||
faith = round(Clamp(faith+faith_amt, 0, max_faith))
|
||||
if(hud_used && hud_used.deity_power_display)
|
||||
hud_used.deity_power_display.maptext = "<div align='center' valign='middle' style='position:relative; top:0px; left:6px'> <font color='cyan'>[faith] </font></div>"
|
||||
|
||||
|
||||
|
||||
/mob/camera/god/proc/place_nexus()
|
||||
if(god_nexus || (z != 1))
|
||||
return 0
|
||||
|
||||
var/obj/structure/divine/nexus/N = new(get_turf(src))
|
||||
N.assign_deity(src)
|
||||
god_nexus = N
|
||||
nexus_required = TRUE
|
||||
verbs -= /mob/camera/god/verb/constructnexus
|
||||
//verbs += /mob/camera/god/verb/movenexus //Translocators have no sprite
|
||||
update_health_hud()
|
||||
|
||||
var/area/A = get_area(src)
|
||||
if(A)
|
||||
var/areaname = A.name
|
||||
var/list/followers = get_my_followers()
|
||||
for(var/datum/mind/F in followers)
|
||||
if(F.current)
|
||||
F.current << "<span class='boldnotice'>Your god's nexus is in \the [areaname]</span>"
|
||||
|
||||
|
||||
/mob/camera/god/verb/freeturret()
|
||||
set category = "Deity"
|
||||
set name = "Free Turret (0)"
|
||||
set desc = "Place a single turret, for 0 faith."
|
||||
|
||||
if(!ability_cost(0,1,1))
|
||||
return
|
||||
var/obj/structure/divine/defensepylon/DP = new(get_turf(src))
|
||||
DP.assign_deity(src)
|
||||
verbs -= /mob/camera/god/verb/freeturret
|
||||
|
||||
|
||||
|
||||
/mob/camera/god/proc/update_followers()
|
||||
alive_followers = 0
|
||||
var/list/all_followers = get_my_followers()
|
||||
for(var/datum/mind/F in all_followers)
|
||||
if(F.current && F.current.stat != DEAD)
|
||||
alive_followers++
|
||||
|
||||
if(hud_used && hud_used.deity_follower_display)
|
||||
hud_used.deity_follower_display.maptext = "<div align='center' valign='middle' style='position:relative; top:0px; left:6px'> <font color='red'>[alive_followers] </font></div>"
|
||||
|
||||
|
||||
/mob/camera/god/proc/check_death()
|
||||
if(!alive_followers)
|
||||
src << "<span class='userdanger'>You no longer have any followers. You shudder as you feel your existence cease...</span>"
|
||||
if(god_nexus && !qdeleted(god_nexus))
|
||||
god_nexus.visible_message("<span class='danger'>\The [src] suddenly disappears!</span>")
|
||||
qdel(god_nexus)
|
||||
qdel(src)
|
||||
|
||||
|
||||
/mob/camera/god/say(msg)
|
||||
if(!msg)
|
||||
return
|
||||
if(client)
|
||||
if(client.prefs.muted & MUTE_IC)
|
||||
src << "You cannot send IC messages (muted)."
|
||||
return
|
||||
if(src.client.handle_spam_prevention(msg,MUTE_IC))
|
||||
return
|
||||
if(stat)
|
||||
return
|
||||
|
||||
god_speak(msg)
|
||||
|
||||
|
||||
/mob/camera/god/proc/god_speak(msg)
|
||||
log_say("Hand of God: [capitalize(side)] God/[key_name(src)] : [msg]")
|
||||
msg = trim(copytext(sanitize(msg), 1, MAX_MESSAGE_LEN))
|
||||
if(!msg)
|
||||
return
|
||||
|
||||
msg = say_quote(msg, get_spans())
|
||||
var/rendered = "<font color='[src.side]'><i><span class='game say'>Divine Telepathy,</i> <span class='name'>[name]</span> <span class='message'>[msg]</span></span></font>"
|
||||
src << rendered
|
||||
|
||||
for(var/mob/M in mob_list)
|
||||
if(is_handofgod_myfollowers(M))
|
||||
M << rendered
|
||||
if(isobserver(M))
|
||||
var/link = FOLLOW_LINK(M, src)
|
||||
M << "[link] [rendered]"
|
||||
|
||||
|
||||
/mob/camera/god/emote(act,m_type = 1 ,msg = null)
|
||||
return
|
||||
|
||||
|
||||
/mob/camera/god/Move(NewLoc, Dir = 0)
|
||||
loc = NewLoc
|
||||
|
||||
|
||||
|
||||
/mob/camera/god/Topic(href, href_list)
|
||||
if(href_list["create_structure"])
|
||||
if(!ability_cost(75,1,1))
|
||||
return
|
||||
|
||||
var/obj/structure/divine/construct_type = text2path(href_list["create_structure"]) //it's a path but we need to initial() some vars
|
||||
if(!construct_type)
|
||||
return
|
||||
|
||||
add_faith(-75)
|
||||
var/obj/structure/divine/construction_holder/CH = new(get_turf(src))
|
||||
CH.assign_deity(src)
|
||||
CH.setup_construction(construct_type)
|
||||
CH.visible_message("<span class='notice'>[src] has created a transparent, unfinished [initial(construct_type.name)]. It can be finished by adding materials.</span>")
|
||||
src << "<span class='boldnotice'>You may click a construction site to cancel it, but only faith is refunded.</span>"
|
||||
structure_construction_ui(src)
|
||||
return
|
||||
|
||||
if(href_list["place_trap"])
|
||||
if(!ability_cost(20,1,1))
|
||||
return
|
||||
|
||||
var/atom/trap_type = text2path(href_list["place_trap"])
|
||||
if(!trap_type)
|
||||
return
|
||||
|
||||
src << "You lay \a [initial(trap_type.name)]"
|
||||
add_faith(-20)
|
||||
new trap_type(get_turf(src))
|
||||
return
|
||||
|
||||
..()
|
||||
|
||||
|
||||
/mob/camera/god/proc/structure_construction_ui(mob/camera/god/user)
|
||||
var/dat = ""
|
||||
for(var/t in global_handofgod_structuretypes)
|
||||
if(global_handofgod_structuretypes[t])
|
||||
var/obj/structure/divine/apath = global_handofgod_structuretypes[t]
|
||||
dat += "<center><B>[capitalize(t)]</B></center><BR>"
|
||||
var/imgstate = initial(apath.autocolours) ? "[initial(apath.icon_state)]-[side]" : "[initial(apath.icon_state)]"
|
||||
var/icon/I = icon('icons/obj/hand_of_god_structures.dmi',imgstate)
|
||||
var/img_component = lowertext(t)
|
||||
//I hate byond, but atleast it autocaches these so it's only 1*number_of_structures worth of actual calls
|
||||
user << browse_rsc(I,"hog_structure-[img_component].png")
|
||||
dat += "<center><img src='hog_structure-[img_component].png' height=64 width=64></center>"
|
||||
dat += "Description: [initial(apath.desc)]<BR>"
|
||||
dat += "<center><a href='?src=\ref[src];create_structure=[apath]'>Construct [capitalize(t)]</a></center><BR><BR>"
|
||||
|
||||
var/datum/browser/popup = new(src, "structures","Construct Structure",350,500)
|
||||
popup.set_content(dat)
|
||||
popup.open()
|
||||
|
||||
|
||||
/mob/camera/god/proc/trap_construction_ui(mob/camera/god/user)
|
||||
var/dat = ""
|
||||
for(var/t in global_handofgod_traptypes)
|
||||
if(global_handofgod_traptypes[t])
|
||||
var/obj/structure/divine/trap/T = global_handofgod_traptypes[t]
|
||||
dat += "<center><B>[capitalize(t)]</B></center><BR>"
|
||||
var/icon/I = icon('icons/obj/hand_of_god_structures.dmi',"[initial(T.icon_state)]")
|
||||
var/img_component = lowertext(t)
|
||||
user << browse_rsc(I,"hog_trap-[img_component].png")
|
||||
dat += "<center><img src='hog_trap-[img_component].png' height=64 width=64></center>"
|
||||
dat += "Description: [initial(T.desc)]<BR>"
|
||||
dat += "<center><a href='?src=\ref[src];place_trap=[T]'>Place [capitalize(t)]</a></center><BR><BR>"
|
||||
|
||||
var/datum/browser/popup = new(src, "traps", "Place Trap",350,500)
|
||||
popup.set_content(dat)
|
||||
popup.open()
|
||||
@@ -1,129 +0,0 @@
|
||||
|
||||
/datum/objective/build
|
||||
dangerrating = 15
|
||||
martyr_compatible = 1
|
||||
|
||||
|
||||
/datum/objective/build/proc/gen_amount_goal(lower, upper)
|
||||
target_amount = rand(lower, upper)
|
||||
explanation_text = "Build [target_amount] shrines."
|
||||
return target_amount
|
||||
|
||||
|
||||
/datum/objective/build/check_completion()
|
||||
if(!owner || !owner.current)
|
||||
return 0
|
||||
|
||||
var/shrines = 0
|
||||
if(is_handofgod_god(owner.current))
|
||||
var/mob/camera/god/G = owner.current
|
||||
for(var/obj/structure/divine/shrine/S in G.structures)
|
||||
S++
|
||||
|
||||
return (shrines >= target_amount)
|
||||
|
||||
|
||||
|
||||
/datum/objective/deicide
|
||||
dangerrating = 20
|
||||
martyr_compatible = 1
|
||||
|
||||
/datum/objective/deicide/check_completion()
|
||||
if(target)
|
||||
if(target.current) //Gods are deleted when they lose
|
||||
return 0
|
||||
return 1
|
||||
|
||||
|
||||
/datum/objective/deicide/find_target()
|
||||
if(!owner || !owner.current)
|
||||
return
|
||||
|
||||
if(is_handofgod_god(owner.current))
|
||||
var/mob/camera/god/G = owner.current
|
||||
if(G.side == "red")
|
||||
if(ticker.mode.blue_deities.len)
|
||||
target = ticker.mode.blue_deities[1]
|
||||
if(G.side == "blue")
|
||||
if(ticker.mode.red_deities.len)
|
||||
target = ticker.mode.red_deities[1]
|
||||
if(!target)
|
||||
return 0
|
||||
update_explanation_text()
|
||||
|
||||
/datum/objective/deicide/update_explanation_text()
|
||||
..()
|
||||
if(target && target.current)
|
||||
explanation_text = "Phase [target.name], the false god, out of this plane of existence.."
|
||||
else
|
||||
explanation_text = "Free Objective"
|
||||
|
||||
|
||||
|
||||
/datum/objective/follower_block
|
||||
explanation_text = "Do not allow any followers of the false god to escape on the station's shuttle alive."
|
||||
dangerrating = 25
|
||||
martyr_compatible = 1
|
||||
|
||||
/datum/objective/follower_block/check_completion()
|
||||
var/side = "ABORT"
|
||||
if(is_handofgod_redcultist(owner.current))
|
||||
side = "red"
|
||||
else if(is_handofgod_bluecultist(owner.current))
|
||||
side = "blue"
|
||||
if(side == "ABORT")
|
||||
return 0
|
||||
|
||||
var/area/A = SSshuttle.emergency.areaInstance
|
||||
|
||||
for(var/mob/living/player in player_list)
|
||||
if(player.mind && player.stat != DEAD && get_area(player) == A)
|
||||
if(side == "red")
|
||||
if(is_handofgod_bluecultist(player))
|
||||
return 0
|
||||
else if(side == "blue")
|
||||
if(is_handofgod_redcultist(player))
|
||||
return 0
|
||||
return 1
|
||||
|
||||
|
||||
|
||||
/datum/objective/escape_followers
|
||||
dangerrating = 5
|
||||
|
||||
|
||||
/datum/objective/escape_followers/proc/gen_amount_goal(lower,upper)
|
||||
target_amount = rand(lower,upper)
|
||||
explanation_text = "Your will must surpass this station. Having [target_amount] followers escape on the shuttle or pods will allow that."
|
||||
return target_amount
|
||||
|
||||
|
||||
/datum/objective/escape_followers/check_completion()
|
||||
var/escaped = 0
|
||||
if(is_handofgod_god(owner.current))
|
||||
var/mob/camera/god/G = owner.current
|
||||
if(G.side == "red")
|
||||
for(var/datum/mind/follower_mind in ticker.mode.red_deity_followers)
|
||||
if(follower_mind.current && follower_mind.current.stat != DEAD)
|
||||
if(follower_mind.current.onCentcom())
|
||||
escaped++
|
||||
|
||||
if(G.side == "blue")
|
||||
for(var/datum/mind/follower_mind in ticker.mode.blue_deity_followers)
|
||||
if(follower_mind.current && follower_mind.current.stat != DEAD)
|
||||
if(follower_mind.current.onCentcom())
|
||||
escaped++
|
||||
|
||||
return (escaped >= target_amount)
|
||||
|
||||
|
||||
/datum/objective/sacrifice_prophet
|
||||
explanation_text = "A false prophet is preaching their god's faith on the station. Sacrificing them will show the mortals who the true god is."
|
||||
dangerrating = 10
|
||||
|
||||
|
||||
/datum/objective/sacrifice_prophet/check_completion()
|
||||
var/mob/camera/god/G = owner.current
|
||||
if(istype(G))
|
||||
return G.prophets_sacrificed_in_name
|
||||
return 0
|
||||
@@ -1,363 +0,0 @@
|
||||
/mob/camera/god/proc/ability_cost(cost = 0,structures = 0, requires_conduit = 0, can_place_near_enemy_nexus = 0)
|
||||
if(faith < cost)
|
||||
src << "<span class='danger'>You lack the faith!</span>"
|
||||
return 0
|
||||
|
||||
if(structures)
|
||||
if(!isturf(loc) || istype(loc, /turf/open/space))
|
||||
src << "<span class='danger'>Your structure would just float away, you need stable ground!</span>"
|
||||
return 0
|
||||
|
||||
var/turf/T = get_turf(src)
|
||||
if(T)
|
||||
if(T.density)
|
||||
src << "<span class='danger'>There is something blocking your structure!</span>"
|
||||
return 0
|
||||
|
||||
for(var/atom/movable/AM in T)
|
||||
if(AM == src)
|
||||
continue
|
||||
if(AM.density)
|
||||
src << "<span class='danger'>There is something blocking your structure!</span>"
|
||||
return 0
|
||||
|
||||
if(requires_conduit)
|
||||
//Organised this way as there can be multiple conduits, so it's more likely to be a conduit check.
|
||||
var/valid = 0
|
||||
|
||||
for(var/obj/structure/divine/conduit/C in conduits)
|
||||
if(get_dist(src, C) <= CONDUIT_RANGE)
|
||||
valid++
|
||||
break
|
||||
|
||||
if(!valid)
|
||||
if(get_dist(src, god_nexus) <= CONDUIT_RANGE)
|
||||
valid++
|
||||
|
||||
if(!valid)
|
||||
src << "<span class='danger'>You must be near your Nexus or a Conduit to do this!</span>"
|
||||
return 0
|
||||
|
||||
if(!can_place_near_enemy_nexus)
|
||||
var/datum/mind/enemy
|
||||
switch(side)
|
||||
if("red")
|
||||
if(ticker.mode.blue_deities.len)
|
||||
enemy = ticker.mode.blue_deities[1]
|
||||
if("blue")
|
||||
if(ticker.mode.red_deities.len)
|
||||
enemy = ticker.mode.red_deities[1]
|
||||
|
||||
if(enemy && is_handofgod_god(enemy.current))
|
||||
var/mob/camera/god/enemy_god = enemy.current
|
||||
if(enemy_god.god_nexus && (get_dist(src,enemy_god.god_nexus) <= CONDUIT_RANGE*2))
|
||||
src << "<span class='danger'>You are too close to the other god's stronghold!</span>"
|
||||
return 0
|
||||
|
||||
return 1
|
||||
|
||||
|
||||
/mob/camera/god/verb/returntonexus()
|
||||
set category = "Deity"
|
||||
set name = "Goto Nexus"
|
||||
set desc = "Teleports you to your next instantly."
|
||||
|
||||
if(god_nexus)
|
||||
Move(get_turf(god_nexus))
|
||||
else
|
||||
src << "You don't even have a Nexus, construct one."
|
||||
|
||||
|
||||
/mob/camera/god/verb/jumptofollower()
|
||||
set category = "Deity"
|
||||
set name = "Jump to Follower"
|
||||
set desc = "Teleports you to one of your followers."
|
||||
var/list/following = list()
|
||||
if(side == "red")
|
||||
following = ticker.mode.red_deity_followers|ticker.mode.red_deity_prophets
|
||||
else if(side == "blue")
|
||||
following = ticker.mode.blue_deity_followers|ticker.mode.blue_deity_prophets
|
||||
else
|
||||
src << "You are unaligned, and thus do not have followers"
|
||||
return
|
||||
|
||||
var/datum/mind/choice = input("Choose a follower","Jump to Follower") as null|anything in following
|
||||
if(choice && choice.current)
|
||||
Move(get_turf(choice.current))
|
||||
|
||||
|
||||
/mob/camera/god/verb/newprophet()
|
||||
set category = "Deity"
|
||||
set name = "Appoint Prophet (100)"
|
||||
set desc = "Appoint one of your followers as your Prophet, who can hear your words"
|
||||
|
||||
var/list/following = list()
|
||||
|
||||
if(!ability_cost(100))
|
||||
return
|
||||
if(side == "red")
|
||||
var/datum/mind/old_proph = locate() in ticker.mode.red_deity_prophets
|
||||
if(old_proph && old_proph.current && old_proph.current.stat != DEAD)
|
||||
src << "You can only have one prophet alive at a time."
|
||||
return
|
||||
else
|
||||
following = ticker.mode.red_deity_followers
|
||||
else if(side == "blue")
|
||||
var/datum/mind/old_proph = locate() in ticker.mode.blue_deity_prophets
|
||||
if(old_proph && old_proph.current && old_proph.current.stat != DEAD)
|
||||
src << "You can only have one prophet alive at a time."
|
||||
return
|
||||
else
|
||||
following = ticker.mode.blue_deity_followers
|
||||
|
||||
else
|
||||
src << "You are unalligned, and thus do not have prophets"
|
||||
return
|
||||
|
||||
var/datum/mind/choice = input("Choose a follower to make into your prophet","Prophet Uplifting") as null|anything in following
|
||||
if(choice && choice.current && choice.current.stat != DEAD)
|
||||
src << "You choose [choice.current] as your prophet."
|
||||
choice.make_Handofgod_prophet(side)
|
||||
speak2god = new()
|
||||
speak2god.god = src
|
||||
speak2god.Grant(choice.current)
|
||||
|
||||
//Prophet gear
|
||||
var/mob/living/carbon/human/H = choice.current
|
||||
var/popehat = null
|
||||
var/popestick = null
|
||||
var/success = ""
|
||||
switch(side)
|
||||
if("red")
|
||||
popehat = /obj/item/clothing/head/helmet/plate/crusader/prophet/red
|
||||
popestick = /obj/item/weapon/godstaff/red
|
||||
if("blue")
|
||||
popehat = /obj/item/clothing/head/helmet/plate/crusader/prophet/blue
|
||||
popestick = /obj/item/weapon/godstaff/blue
|
||||
|
||||
if(popehat)
|
||||
var/obj/item/clothing/head/helmet/plate/crusader/prophet/P = new popehat()
|
||||
|
||||
if(H.equip_to_slot_if_possible(P,slot_in_backpack,0,1,1))
|
||||
success = "It is in your backpack."
|
||||
else
|
||||
H.unEquip(H.head)
|
||||
H.equip_to_slot_or_del(P,slot_head)
|
||||
success = "It is on your head."
|
||||
|
||||
if(success)
|
||||
H << "<span class='boldnotice'>A powerful hat has been bestowed upon you, you will need to wear it to utilize your staff fully.</span>"
|
||||
H << "<span class='boldnotice'>[success]</span>"
|
||||
|
||||
if(popestick)
|
||||
var/obj/item/weapon/godstaff/G = new popestick()
|
||||
G.god = src
|
||||
if(!H.equip_to_slot_if_possible(G,slot_in_backpack,0,1,1))
|
||||
if(!H.put_in_hands(G))
|
||||
G.loc = get_turf(H)
|
||||
success = "It is on the floor..."
|
||||
else
|
||||
success = "It is in your hands..."
|
||||
else
|
||||
success = "It is in your backpack..."
|
||||
|
||||
if(success)
|
||||
H << "<span class='boldnotice'>A powerful staff has been bestowed upon you, you can use this to convert the false god's structures!</span>"
|
||||
H << "<span class='boldnotice'>[success]</span>"
|
||||
//end prophet gear
|
||||
|
||||
add_faith(-100)
|
||||
|
||||
|
||||
/mob/camera/god/verb/talk(msg as text)
|
||||
set category = "Deity"
|
||||
set name = "Talk to Anyone (20)"
|
||||
set desc = "Allows you to send a message to anyone, regardless of their faith."
|
||||
if(!ability_cost(20))
|
||||
return
|
||||
var/mob/choice = input("Choose who you wish to talk to", "Talk to ANYONE") as null|anything in mob_list
|
||||
if(choice)
|
||||
var/original = msg
|
||||
msg = "<B>You hear a voice coming from everywhere and nowhere... <i>[msg]</i></B>"
|
||||
choice << msg
|
||||
src << "You say the following to [choice], [original]"
|
||||
add_faith(-20)
|
||||
|
||||
|
||||
/mob/camera/god/verb/smite()
|
||||
set category = "Deity"
|
||||
set name = "Smite (40)"
|
||||
set desc = "Hits anything under you with a moderate amount of damage."
|
||||
|
||||
if(!ability_cost(40,0,1))
|
||||
return
|
||||
if(!range(7,god_nexus))
|
||||
src << "You lack the strength to smite this far from your nexus."
|
||||
return
|
||||
|
||||
var/has_smitten = 0 //Hast thou been smitten, infidel?
|
||||
for(var/mob/living/L in get_turf(src))
|
||||
L.adjustFireLoss(20)
|
||||
L.adjustBruteLoss(20)
|
||||
L << "<span class='danger'><B>You feel the wrath of [name]!<B></span>"
|
||||
has_smitten = 1
|
||||
if(has_smitten)
|
||||
add_faith(-40)
|
||||
|
||||
|
||||
/mob/camera/god/verb/disaster()
|
||||
set category = "Deity"
|
||||
set name = "Invoke Disaster (300)" //difficult to reach without lots of followers
|
||||
set desc = "Tug at the fibres of reality itself and bend it to your whims!"
|
||||
|
||||
if(!ability_cost(300,0,1))
|
||||
return
|
||||
|
||||
var/event = pick(/datum/round_event/meteor_wave, /datum/round_event/communications_blackout, /datum/round_event/radiation_storm, /datum/round_event/carp_migration,
|
||||
/datum/round_event/spacevine, /datum/round_event/vent_clog, /datum/round_event/wormholes)
|
||||
if(event)
|
||||
new event()
|
||||
add_faith(-300)
|
||||
|
||||
|
||||
/mob/camera/god/verb/constructnexus()
|
||||
set category = "Deity"
|
||||
set name = "Construct Nexus"
|
||||
set desc = "Instantly creates your nexus, You can only do this once, make sure you're happy with it!"
|
||||
|
||||
if(!ability_cost(0,1,0))
|
||||
return
|
||||
|
||||
place_nexus()
|
||||
|
||||
|
||||
/* //Transolocators have no sprite
|
||||
/mob/camera/god/verb/movenexus()
|
||||
set category = "Deity"
|
||||
set name = "Relocate Nexus (50)"
|
||||
set desc = "Instantly relocates your nexus to an existing translocator belonging to your faith, this destroys the translocator in the process"
|
||||
|
||||
if(ability_cost(50,0,0) && god_nexus)
|
||||
var/list/translocators = list()
|
||||
var/list/used_keys = list()
|
||||
for(var/obj/structure/divine/translocator/T in structures)
|
||||
translocators["[T.name] ([get_area(T)])"] = T
|
||||
|
||||
if(!translocators.len)
|
||||
src << "<span class='warning'>You have no translocators!</span>"
|
||||
return
|
||||
|
||||
var/picked = input(src,"Choose a translocator","Relocate Nexus") as null|anything in translocators
|
||||
if(!picked || !translocators[picked])
|
||||
return
|
||||
|
||||
var/obj/structure/divine/translocator/T = translocators[T]
|
||||
var/turf/Tturf = get_turf(T)
|
||||
god_nexus.loc = T
|
||||
translocators[picked] = null
|
||||
add_faith(-50)
|
||||
qdel(T)
|
||||
*/
|
||||
|
||||
/mob/camera/god/verb/construct_structures()
|
||||
set category = "Deity"
|
||||
set name = "Construct Structure (75)"
|
||||
set desc = "Create the foundation of a divine object."
|
||||
|
||||
if(!ability_cost(75,1,1))
|
||||
return
|
||||
|
||||
structure_construction_ui(src)
|
||||
|
||||
|
||||
/mob/camera/god/verb/construct_traps()
|
||||
set category = "Deity"
|
||||
set name = "Construct Trap (20)"
|
||||
set desc = "Creates a ward or trap."
|
||||
|
||||
if(!ability_cost(20,1,1))
|
||||
return
|
||||
|
||||
trap_construction_ui(src)
|
||||
|
||||
|
||||
|
||||
/mob/camera/god/verb/construct_items()
|
||||
set category = "Deity"
|
||||
set name = "Construct Items (20)"
|
||||
set desc = "Construct some items for your followers"
|
||||
|
||||
if(!ability_cost(20,1,1))
|
||||
return
|
||||
|
||||
var/list/item_types = list("claymore sword" = /obj/item/weapon/claymore/hog)
|
||||
if(side == "red")
|
||||
item_types["red banner"] = /obj/item/weapon/banner/red
|
||||
item_types["red bannerbackpack"] = /obj/item/weapon/storage/backpack/bannerpack/red
|
||||
item_types["red armour"] = /obj/item/weapon/storage/box/itemset/crusader/red
|
||||
|
||||
else if(side == "blue")
|
||||
item_types["blue banner"] = /obj/item/weapon/banner/blue
|
||||
item_types["blue bannerbackpack"] = /obj/item/weapon/storage/backpack/bannerpack/blue
|
||||
item_types["blue armour"] = /obj/item/weapon/storage/box/itemset/crusader/blue
|
||||
|
||||
|
||||
var/item = input("Choose what you wish to create.", "Divine Items") as null|anything in item_types
|
||||
if(!item || !item_types[item] || !ability_cost(20,1,1))
|
||||
return
|
||||
|
||||
src << "You produce \a [item]"
|
||||
add_faith(-20)
|
||||
|
||||
var/itemtype = item_types[item]
|
||||
new itemtype (get_turf(src))
|
||||
|
||||
|
||||
|
||||
/mob/camera/god/verb/veil_structures()
|
||||
set category = "Deity"
|
||||
set name = "Veil Structures (20)"
|
||||
set desc = "Hide your structures from sight and touch, but prevent yourself from using them."
|
||||
|
||||
if(!ability_cost(20,1,1))
|
||||
return
|
||||
|
||||
src << "You focus your powers and start dragging your influence into the spiritual plane."
|
||||
for(var/mob/M in orange(3,src))//Yes I know this is terrible, but visible message doesnt work for this
|
||||
M << "<span class='warning'>The air begins to shimmer...</span>"
|
||||
if(do_after(src, 30, 0, src))
|
||||
for(var/obj/structure/divine/R in orange(3,src))
|
||||
if(istype(R, /obj/structure/divine/nexus)|| istype(R, /obj/structure/divine/trap)||(src.side != R.side))
|
||||
continue
|
||||
R.visible_message("<span class='danger'>[R] fades away.</span>")
|
||||
R.invisibility = 55
|
||||
R.alpha = 100 //To help ghosts distinguish hidden structures
|
||||
R.density = 0
|
||||
R.deactivate()
|
||||
src << "You hide your influence from view"
|
||||
add_faith(-20)
|
||||
|
||||
|
||||
/mob/camera/god/verb/reveal_structures()
|
||||
set category = "Deity"
|
||||
set name = "Reveal Structures (20)"
|
||||
set desc = "Make your structures visible again and allow them to be used."
|
||||
|
||||
if(!ability_cost(20,1,1))
|
||||
return
|
||||
|
||||
src << "You focus your powers and start dragging your influence into the material plane."
|
||||
for(var/mob/M in orange(3,src))//Yes I know this is terrible, but visible message doesnt work for this
|
||||
M << "<span class='warning'>The air begins to shimmer...</span>"
|
||||
if(do_after(src, 40, 0, src))
|
||||
for(var/obj/structure/divine/R in orange(3,src))
|
||||
if(istype(R, /obj/structure/divine/nexus)|| istype(R, /obj/structure/divine/trap)||(src.side != R.side))
|
||||
continue
|
||||
R.visible_message("<span class='danger'>[R] suddenly appears!</span>")
|
||||
R.invisibility = 0
|
||||
R.alpha = initial(R.alpha)
|
||||
R.density = initial(R.density)
|
||||
R.activate()
|
||||
src << "You bring your influence into view"
|
||||
add_faith(-20)
|
||||
|
||||
@@ -1,661 +0,0 @@
|
||||
|
||||
/proc/build_hog_construction_lists()
|
||||
if(global_handofgod_traptypes.len && global_handofgod_structuretypes.len)
|
||||
return
|
||||
|
||||
var/list/types = subtypesof(/obj/structure/divine) - /obj/structure/divine/trap
|
||||
for(var/T in types)
|
||||
var/obj/structure/divine/D = T
|
||||
if(initial(D.constructable))
|
||||
if(initial(D.trap))
|
||||
global_handofgod_traptypes[initial(D.name)] = T
|
||||
else
|
||||
global_handofgod_structuretypes[initial(D.name)] = T
|
||||
|
||||
/obj/structure/divine
|
||||
name = "divine construction site"
|
||||
icon = 'icons/obj/hand_of_god_structures.dmi'
|
||||
desc = "An unfinished divine building"
|
||||
anchored = 1
|
||||
density = 1
|
||||
var/constructable = TRUE
|
||||
var/trap = FALSE
|
||||
var/metal_cost = 0
|
||||
var/glass_cost = 0
|
||||
var/lesser_gem_cost = 0
|
||||
var/greater_gem_cost = 0
|
||||
var/mob/camera/god/deity
|
||||
var/side = "neutral" //"blue" or "red", also used for colouring structures when construction is started by a deity
|
||||
var/health = 100
|
||||
var/maxhealth = 100
|
||||
var/deactivated = 0 //Structures being hidden can't be used. Mainly to prevent invisible defense pylons.
|
||||
var/autocolours = TRUE //do we colour to our side?
|
||||
|
||||
/obj/structure/divine/New()
|
||||
..()
|
||||
|
||||
/obj/structure/divine/proc/deactivate()
|
||||
deactivated = 1
|
||||
|
||||
/obj/structure/divine/proc/activate()
|
||||
deactivated = 0
|
||||
|
||||
|
||||
/obj/structure/divine/proc/update_icons()
|
||||
if(autocolours)
|
||||
icon_state = "[initial(icon_state)]-[side]"
|
||||
|
||||
|
||||
/obj/structure/divine/Destroy()
|
||||
if(deity)
|
||||
deity.structures -= src
|
||||
return ..()
|
||||
|
||||
|
||||
|
||||
/obj/structure/divine/attackby(obj/item/I, mob/user)
|
||||
|
||||
//Structure conversion/capture
|
||||
if(istype(I, /obj/item/weapon/godstaff))
|
||||
if(!is_handofgod_cultist(user))
|
||||
user << "<span class='notice'>You're not quite sure what the hell you're even doing.</span>"
|
||||
return
|
||||
var/obj/item/weapon/godstaff/G = I
|
||||
if(G.god && deity != G.god)
|
||||
assign_deity(G.god, alert_old_deity = TRUE)
|
||||
visible_message("<span class='boldnotice'>\The [src] has been captured by [user]!</span>")
|
||||
else
|
||||
return ..()
|
||||
|
||||
/obj/structure/divine/attacked_by(obj/item/I, mob/living/user)
|
||||
..()
|
||||
take_damage(I.force, I.damtype, 1)
|
||||
|
||||
/obj/structure/divine/proc/take_damage(damage, damage_type = BRUTE, sound_effect = 1)
|
||||
switch(damage_type)
|
||||
if(BRUTE)
|
||||
if(sound_effect)
|
||||
if(damage)
|
||||
playsound(loc, 'sound/weapons/smash.ogg', 50, 1)
|
||||
else
|
||||
playsound(loc, 'sound/weapons/tap.ogg', 50, 1)
|
||||
if(BURN)
|
||||
if(sound_effect)
|
||||
playsound(src.loc, 'sound/items/Welder.ogg', 100, 1)
|
||||
else
|
||||
return
|
||||
health -= damage
|
||||
if(!health)
|
||||
visible_message("<span class='danger'>\The [src] was destroyed!</span>")
|
||||
qdel(src)
|
||||
|
||||
|
||||
/obj/structure/divine/bullet_act(obj/item/projectile/P)
|
||||
. = ..()
|
||||
take_damage(P.damage, P.damage_type, 0)
|
||||
|
||||
|
||||
/obj/structure/divine/attack_alien(mob/living/carbon/alien/humanoid/user)
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
user.do_attack_animation(src)
|
||||
add_hiddenprint(user)
|
||||
visible_message("<span class='warning'>\The [user] slashes at [src]!</span>")
|
||||
playsound(src.loc, 'sound/weapons/slash.ogg', 100, 1)
|
||||
take_damage(20, BRUTE, 0)
|
||||
|
||||
/obj/machinery/attack_animal(mob/living/simple_animal/M)
|
||||
M.changeNext_move(CLICK_CD_MELEE)
|
||||
M.do_attack_animation(src)
|
||||
if(M.melee_damage_upper > 0 || M.obj_damage)
|
||||
M.visible_message("<span class='danger'>[M.name] smashes against \the [src.name].</span>",\
|
||||
"<span class='danger'>You smash against the [src.name].</span>")
|
||||
if(M.obj_damage)
|
||||
take_damage(M.obj_damage, M.melee_damage_type, 1)
|
||||
else
|
||||
take_damage(rand(M.melee_damage_lower,M.melee_damage_upper), M.melee_damage_type, 1)
|
||||
|
||||
|
||||
/obj/structure/divine/proc/assign_deity(mob/camera/god/new_deity, alert_old_deity = TRUE)
|
||||
if(!new_deity)
|
||||
return 0
|
||||
if(deity)
|
||||
if(alert_old_deity)
|
||||
deity << "<span class='danger'><B>Your [name] was captured by [new_deity]'s cult!</B></span>"
|
||||
deity.structures -= src
|
||||
deity = new_deity
|
||||
deity.structures |= src
|
||||
side = deity.side
|
||||
update_icons()
|
||||
return 1
|
||||
|
||||
|
||||
/obj/structure/divine/construction_holder
|
||||
alpha = 125
|
||||
constructable = FALSE
|
||||
var/obj/structure/divine/construction_result = /obj/structure/divine //a path, but typed to /obj/structure/divine for initial()
|
||||
|
||||
|
||||
|
||||
/obj/structure/divine/construction_holder/assign_deity(mob/camera/god/new_deity, alert_old_deity = TRUE)
|
||||
if(..())
|
||||
color = side
|
||||
|
||||
|
||||
/obj/structure/divine/construction_holder/attack_god(mob/camera/god/user)
|
||||
if(user.side == side && construction_result)
|
||||
user.add_faith(75)
|
||||
visible_message("<span class='danger'>[user] has cancelled \the [initial(construction_result.name)]")
|
||||
qdel(src)
|
||||
|
||||
|
||||
/obj/structure/divine/construction_holder/proc/setup_construction(construct_type)
|
||||
if(ispath(construct_type))
|
||||
construction_result = construct_type
|
||||
name = "[initial(construction_result.name)] construction site "
|
||||
icon_state = initial(construction_result.icon_state)
|
||||
metal_cost = initial(construction_result.metal_cost)
|
||||
glass_cost = initial(construction_result.glass_cost)
|
||||
lesser_gem_cost = initial(construction_result.lesser_gem_cost)
|
||||
greater_gem_cost = initial(construction_result.greater_gem_cost)
|
||||
desc = "An unfinished [initial(construction_result.name)]."
|
||||
|
||||
|
||||
/obj/structure/divine/construction_holder/attackby(obj/item/I, mob/user)
|
||||
if(!I || !user)
|
||||
return 0
|
||||
|
||||
if(istype(I, /obj/item/stack/sheet/metal))
|
||||
var/obj/item/stack/sheet/metal/M = I
|
||||
if(metal_cost)
|
||||
var/spend = min(metal_cost, M.amount)
|
||||
user << "<span class='notice'>You add [spend] metal to \the [src]."
|
||||
metal_cost = max(0, metal_cost - spend)
|
||||
M.use(spend)
|
||||
check_completion()
|
||||
else
|
||||
user << "<span class='notice'>\The [src] does not require any more metal!"
|
||||
return
|
||||
|
||||
if(istype(I, /obj/item/stack/sheet/glass))
|
||||
var/obj/item/stack/sheet/glass/G = I
|
||||
if(glass_cost)
|
||||
var/spend = min(glass_cost, G.amount)
|
||||
user << "<span class='notice'>You add [spend] glass to \the [src]."
|
||||
glass_cost = max(0, glass_cost - spend)
|
||||
G.use(spend)
|
||||
check_completion()
|
||||
else
|
||||
user << "<span class='notice'>\The [src] does not require any more glass!"
|
||||
return
|
||||
|
||||
if(istype(I, /obj/item/stack/sheet/lessergem))
|
||||
var/obj/item/stack/sheet/lessergem/LG = I
|
||||
if(lesser_gem_cost)
|
||||
var/spend = min(lesser_gem_cost, LG.amount)
|
||||
user << "<span class='notice'>You add [spend] lesser gems to \the [src]."
|
||||
lesser_gem_cost = max(0, lesser_gem_cost - spend)
|
||||
LG.use(spend)
|
||||
check_completion()
|
||||
else
|
||||
user << "<span class='notice'>\The [src] does not require any more lesser gems!"
|
||||
return
|
||||
|
||||
if(istype(I, /obj/item/stack/sheet/greatergem))
|
||||
var/obj/item/stack/sheet/greatergem/GG = I //GG!
|
||||
if(greater_gem_cost)
|
||||
var/spend = min(greater_gem_cost, GG.amount)
|
||||
user << "<span class='notice'>You add [spend] greater gems to \the [src]."
|
||||
greater_gem_cost = max(0, greater_gem_cost - spend)
|
||||
GG.use(spend)
|
||||
check_completion()
|
||||
else
|
||||
user << "<span class='notice'>\The [src] does not require any more greater gems!"
|
||||
return
|
||||
|
||||
else
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/structure/divine/construction_holder/proc/check_completion()
|
||||
if(!metal_cost && !glass_cost && !lesser_gem_cost && !greater_gem_cost)
|
||||
visible_message("<span class='notice'>\The [initial(construction_result.name)] is complete!</span>")
|
||||
var/obj/structure/divine/D = new construction_result (get_turf(src))
|
||||
D.assign_deity(deity)
|
||||
qdel(src)
|
||||
|
||||
|
||||
/obj/structure/divine/construction_holder/examine(mob/user)
|
||||
..()
|
||||
|
||||
if(metal_cost || glass_cost || lesser_gem_cost || greater_gem_cost)
|
||||
user << "To finish construction it requires the following materials:"
|
||||
if(metal_cost)
|
||||
user << "[metal_cost] metal <IMG CLASS=icon SRC=icons/obj/items.dmi ICONSTATE='sheet-metal'>"
|
||||
if(glass_cost)
|
||||
user << "[glass_cost] glass <IMG CLASS=icon SRC=icons/obj/items.dmi ICONSTATE='sheet-glass'>"
|
||||
if(lesser_gem_cost)
|
||||
user << "[lesser_gem_cost] lesser gems <IMG CLASS=icon SRC=icons/obj/items.dmi ICONSTATE='sheet-lessergem'>"
|
||||
if(greater_gem_cost)
|
||||
user << "[greater_gem_cost] greater gems <IMG CLASS=icon SRC=icons/obj/items.dmi ICONSTATE='sheet-greatergem'>"
|
||||
|
||||
|
||||
/obj/structure/divine/nexus
|
||||
name = "nexus"
|
||||
desc = "It anchors a deity to this world. It radiates an unusual aura. Cultists protect this at all costs. It looks well protected from explosive shock."
|
||||
icon_state = "nexus"
|
||||
health = 500
|
||||
maxhealth = 500
|
||||
constructable = FALSE
|
||||
var/faith_regen_rate = 1
|
||||
var/list/powerpylons = list()
|
||||
|
||||
|
||||
/obj/structure/divine/nexus/ex_act()
|
||||
return
|
||||
|
||||
/obj/structure/divine/nexus/take_damage(damage, damage_type = BRUTE, sound_effect = 1)
|
||||
switch(damage_type)
|
||||
if(BRUTE)
|
||||
if(sound_effect)
|
||||
if(damage)
|
||||
playsound(loc, 'sound/weapons/smash.ogg', 50, 1)
|
||||
else
|
||||
playsound(loc, 'sound/weapons/tap.ogg', 50, 1)
|
||||
if(BURN)
|
||||
if(sound_effect)
|
||||
playsound(src.loc, 'sound/items/Welder.ogg', 100, 1)
|
||||
else
|
||||
return
|
||||
health -= damage
|
||||
if(deity)
|
||||
deity.update_health_hud()
|
||||
if(!health)
|
||||
if(!qdeleted(deity) && deity.nexus_required)
|
||||
deity << "<span class='danger'>Your nexus was destroyed. You feel yourself fading...</span>"
|
||||
qdel(deity)
|
||||
visible_message("<span class='danger'>\The [src] was destroyed!</span>")
|
||||
qdel(src)
|
||||
|
||||
|
||||
/obj/structure/divine/nexus/New()
|
||||
START_PROCESSING(SSobj, src)
|
||||
|
||||
|
||||
/obj/structure/divine/nexus/process()
|
||||
if(deity)
|
||||
deity.update_followers()
|
||||
deity.add_faith(faith_regen_rate + (powerpylons.len / 5) + (deity.alive_followers / 3))
|
||||
deity.max_faith = initial(deity.max_faith) + (deity.alive_followers*10) //10 followers = 100 max faith, so disaster() at around 20 followers
|
||||
deity.check_death()
|
||||
|
||||
|
||||
/obj/structure/divine/nexus/Destroy()
|
||||
STOP_PROCESSING(SSobj, src)
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/structure/divine/conduit
|
||||
name = "conduit"
|
||||
desc = "It allows a deity to extend their reach. Their powers are just as potent near a conduit as a nexus."
|
||||
icon_state = "conduit"
|
||||
health = 150
|
||||
maxhealth = 150
|
||||
metal_cost = 10
|
||||
glass_cost = 5
|
||||
|
||||
|
||||
/obj/structure/divine/conduit/assign_deity(mob/camera/god/new_deity, alert_old_deity = TRUE)
|
||||
if(deity)
|
||||
deity.conduits -= src
|
||||
..()
|
||||
if(deity)
|
||||
deity.conduits += src
|
||||
|
||||
/obj/structure/divine/conduit/deactivate()
|
||||
..()
|
||||
if(deity)
|
||||
deity.conduits -= src
|
||||
|
||||
/obj/structure/divine/conduit/activate()
|
||||
..()
|
||||
if(deity)
|
||||
deity.conduits += src
|
||||
|
||||
/* //No good sprites, and not enough items to make it viable yet
|
||||
/obj/structure/divine/forge
|
||||
name = "forge"
|
||||
desc = "A forge fueled by divine might, it allows the creation of sacred and powerful artifacts. It requires common materials to craft objects."
|
||||
icon_state = "forge"
|
||||
health = 250
|
||||
maxhealth = 250
|
||||
density = 0
|
||||
maxhealth = 250
|
||||
metal_cost = 40
|
||||
*/
|
||||
|
||||
/obj/structure/divine/convertaltar
|
||||
name = "conversion altar"
|
||||
desc = "An altar dedicated to a deity. Cultists can \"forcefully teach\" their non-aligned crewmembers to join their side and take up their deity."
|
||||
icon_state = "convertaltar"
|
||||
density = 0
|
||||
metal_cost = 10
|
||||
can_buckle = 1
|
||||
|
||||
|
||||
/obj/structure/divine/convertaltar/attack_hand(mob/living/user)
|
||||
..()
|
||||
if(deactivated)
|
||||
return
|
||||
var/mob/living/carbon/human/H = locate() in get_turf(src)
|
||||
if(!is_handofgod_cultist(user))
|
||||
user << "<span class='notice'>You try to use it, but unfortunately you don't know any rituals.</span>"
|
||||
return
|
||||
if(!H)
|
||||
return
|
||||
if(!H.mind)
|
||||
user << "<span class='danger'>Only sentients may serve your deity.</span>"
|
||||
return
|
||||
if((side == "red" && is_handofgod_redcultist(user) && !is_handofgod_redcultist(H)) || (side == "blue" && is_handofgod_bluecultist(user) && !is_handofgod_bluecultist(H)))
|
||||
user << "<span class='notice'>You invoke the conversion ritual.</span>"
|
||||
ticker.mode.add_hog_follower(H.mind, side)
|
||||
else
|
||||
user << "<span class='notice'>You invoke the conversion ritual.</span>"
|
||||
user << "<span class='danger'>But the altar ignores your words...</span>"
|
||||
|
||||
|
||||
/obj/structure/divine/sacrificealtar
|
||||
name = "sacrificial altar"
|
||||
desc = "An altar designed to perform blood sacrifice for a deity. The cultists performing the sacrifice will gain a powerful material to use in their forge. Sacrificing a prophet will yield even better results."
|
||||
icon_state = "sacrificealtar"
|
||||
density = 0
|
||||
metal_cost = 15
|
||||
can_buckle = 1
|
||||
|
||||
|
||||
/obj/structure/divine/sacrificealtar/attack_hand(mob/living/user)
|
||||
..()
|
||||
if(deactivated)
|
||||
return
|
||||
var/mob/living/L = locate() in get_turf(src)
|
||||
if(!is_handofgod_cultist(user))
|
||||
user << "<span class='notice'>You try to use it, but unfortunately you don't know any rituals.</span>"
|
||||
return
|
||||
if(!L)
|
||||
return
|
||||
if((side == "red" && is_handofgod_redcultist(user)) || (side == "blue" && is_handofgod_bluecultist(user)))
|
||||
if((side == "red" && is_handofgod_redcultist(L)) || (side == "blue" && is_handofgod_bluecultist(L)))
|
||||
user << "<span class='danger'>You cannot sacrifice a fellow cultist.</span>"
|
||||
return
|
||||
user << "<span class='notice'>You attempt to sacrifice [L] by invoking the sacrificial ritual.</span>"
|
||||
sacrifice(L)
|
||||
else
|
||||
user << "<span class='notice'>You attempt to sacrifice [L] by invoking the sacrificial ritual.</span>"
|
||||
user << "<span class='danger'>But the altar ignores your words...</span>"
|
||||
|
||||
|
||||
/obj/structure/divine/sacrificealtar/proc/sacrifice(mob/living/L)
|
||||
if(!L)
|
||||
L = locate() in get_turf(src)
|
||||
if(L)
|
||||
if(ismonkey(L))
|
||||
var/luck = rand(1,4)
|
||||
if(luck > 3)
|
||||
new /obj/item/stack/sheet/lessergem(get_turf(src))
|
||||
|
||||
else if(ishuman(L))
|
||||
var/mob/living/carbon/human/H = L
|
||||
|
||||
//Sacrifice altars can't teamkill
|
||||
if(side == "red" && is_handofgod_redcultist(H))
|
||||
return
|
||||
else if(side == "blue" && is_handofgod_bluecultist(H))
|
||||
return
|
||||
|
||||
if(is_handofgod_prophet(H))
|
||||
new /obj/item/stack/sheet/greatergem(get_turf(src))
|
||||
if(deity)
|
||||
deity.prophets_sacrificed_in_name++
|
||||
else
|
||||
new /obj/item/stack/sheet/lessergem(get_turf(src))
|
||||
|
||||
else if(isAI(L) || istype(L, /mob/living/carbon/alien/humanoid/royal/queen))
|
||||
new /obj/item/stack/sheet/greatergem(get_turf(src))
|
||||
else
|
||||
new /obj/item/stack/sheet/lessergem(get_turf(src))
|
||||
L.gib()
|
||||
|
||||
|
||||
/obj/structure/divine/healingfountain
|
||||
name = "healing fountain"
|
||||
desc = "A fountain containing the waters of life... or death, depending on where your allegiances lie."
|
||||
icon_state = "fountain"
|
||||
metal_cost = 10
|
||||
glass_cost = 5
|
||||
autocolours = FALSE
|
||||
var/time_between_uses = 1800
|
||||
var/last_process = 0
|
||||
var/cult_only = TRUE
|
||||
|
||||
/obj/structure/divine/healingfountain/anyone
|
||||
desc = "A fountain containing the waters of life."
|
||||
cult_only = FALSE
|
||||
|
||||
/obj/structure/divine/healingfountain/attack_hand(mob/living/user)
|
||||
if(deactivated)
|
||||
return
|
||||
if(last_process + time_between_uses > world.time)
|
||||
user << "<span class='notice'>The fountain appears to be empty.</span>"
|
||||
return
|
||||
last_process = world.time
|
||||
if(!is_handofgod_cultist(user) && cult_only)
|
||||
user << "<span class='danger'><B>The water burns!</b></spam>"
|
||||
user.reagents.add_reagent("hell_water",20)
|
||||
else
|
||||
user << "<span class='notice'>The water feels warm and soothing as you touch it. The fountain immediately dries up shortly afterwards.</span>"
|
||||
user.reagents.add_reagent("godblood",20)
|
||||
update_icons()
|
||||
addtimer(src, "update_icons", time_between_uses)
|
||||
|
||||
|
||||
/obj/structure/divine/healingfountain/update_icons()
|
||||
if(last_process + time_between_uses > world.time)
|
||||
icon_state = "fountain"
|
||||
else
|
||||
icon_state = "fountain-[side]"
|
||||
|
||||
|
||||
/obj/structure/divine/powerpylon
|
||||
name = "power pylon"
|
||||
desc = "A pylon which increases the deity's rate it can influence the world."
|
||||
icon_state = "powerpylon"
|
||||
density = 1
|
||||
health = 30
|
||||
maxhealth = 30
|
||||
metal_cost = 5
|
||||
glass_cost = 15
|
||||
|
||||
|
||||
/obj/structure/divine/powerpylon/New()
|
||||
..()
|
||||
if(deity && deity.god_nexus)
|
||||
deity.god_nexus.powerpylons += src
|
||||
|
||||
|
||||
/obj/structure/divine/powerpylon/Destroy()
|
||||
if(deity && deity.god_nexus)
|
||||
deity.god_nexus.powerpylons -= src
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/structure/divine/powerpylon/deactivate()
|
||||
..()
|
||||
if(deity)
|
||||
deity.god_nexus.powerpylons -= src
|
||||
|
||||
/obj/structure/divine/powerpylon/activate()
|
||||
..()
|
||||
if(deity)
|
||||
deity.god_nexus.powerpylons += src
|
||||
|
||||
/obj/structure/divine/defensepylon
|
||||
name = "defense pylon"
|
||||
desc = "A pylon which is blessed to withstand many blows, and fire strong bolts at nonbelievers. A god can toggle it."
|
||||
icon_state = "defensepylon"
|
||||
health = 150
|
||||
maxhealth = 150
|
||||
metal_cost = 25
|
||||
glass_cost = 30
|
||||
var/obj/machinery/porta_turret/defensepylon_internal_turret/pylon_gun
|
||||
|
||||
|
||||
/obj/structure/divine/defensepylon/New()
|
||||
..()
|
||||
pylon_gun = new(src)
|
||||
pylon_gun.base = src
|
||||
pylon_gun.faction = list("[side] god")
|
||||
|
||||
|
||||
/obj/structure/divine/defensepylon/Destroy()
|
||||
qdel(pylon_gun) //just in case
|
||||
return ..()
|
||||
|
||||
|
||||
/obj/structure/divine/defensepylon/examine(mob/user)
|
||||
..()
|
||||
user << "<span class='notice'>\The [src] looks [pylon_gun.on ? "on" : "off"].</span>"
|
||||
|
||||
|
||||
/obj/structure/divine/defensepylon/assign_deity(mob/camera/god/new_deity, alert_old_deity = TRUE)
|
||||
if(..() && pylon_gun)
|
||||
pylon_gun.faction = list("[side] god")
|
||||
pylon_gun.side = side
|
||||
|
||||
/obj/structure/divine/defensepylon/attack_god(mob/camera/god/user)
|
||||
if(user.side == side)
|
||||
if(deactivated)
|
||||
user << "You need to reveal it first!"
|
||||
return
|
||||
pylon_gun.on = !pylon_gun.on
|
||||
icon_state = (pylon_gun.on) ? "defensepylon-[side]" : "defensepylon"
|
||||
|
||||
/obj/structure/divine/defensepylon/deactivate()
|
||||
..()
|
||||
pylon_gun.on = 0
|
||||
icon_state = (pylon_gun.on) ? "defensepylon-[side]" : "defensepylon"
|
||||
|
||||
/obj/structure/divine/defensepylon/activate()
|
||||
..()
|
||||
pylon_gun.on = 1
|
||||
icon_state = (pylon_gun.on) ? "defensepylon-[side]" : "defensepylon"
|
||||
|
||||
//This sits inside the defensepylon, to avoid copypasta
|
||||
/obj/machinery/porta_turret/defensepylon_internal_turret
|
||||
name = "defense pylon"
|
||||
desc = "A plyon which is blessed to withstand many blows, and fire strong bolts at nonbelievers."
|
||||
icon = 'icons/obj/hand_of_god_structures.dmi'
|
||||
installation = null
|
||||
always_up = 1
|
||||
use_power = 0
|
||||
has_cover = 0
|
||||
health = 200
|
||||
projectile = /obj/item/projectile/beam/pylon_bolt
|
||||
eprojectile = /obj/item/projectile/beam/pylon_bolt
|
||||
shot_sound = 'sound/weapons/emitter2.ogg'
|
||||
eshot_sound = 'sound/weapons/emitter2.ogg'
|
||||
base_icon_state = "defensepylon"
|
||||
active_state = ""
|
||||
off_state = ""
|
||||
faction = null
|
||||
emp_vunerable = 0
|
||||
var/side = "neutral"
|
||||
|
||||
/obj/machinery/porta_turret/defensepylon_internal_turret/setup()
|
||||
return
|
||||
|
||||
/obj/machinery/porta_turret/defensepylon_internal_turret/shootAt(atom/movable/target)
|
||||
var/obj/item/projectile/A = ..()
|
||||
if(A)
|
||||
A.color = side
|
||||
|
||||
/obj/machinery/porta_turret/defensepylon_internal_turret/assess_perp(mob/living/carbon/human/perp)
|
||||
if(perp.handcuffed) //dishonourable to kill somebody who might be converted.
|
||||
return 0
|
||||
var/badtarget = 0
|
||||
switch(side)
|
||||
if("blue")
|
||||
badtarget = is_handofgod_bluecultist(perp)
|
||||
if("red")
|
||||
badtarget = is_handofgod_redcultist(perp)
|
||||
else
|
||||
badtarget = 1
|
||||
if(badtarget)
|
||||
return 0
|
||||
return 10
|
||||
|
||||
|
||||
|
||||
/obj/item/projectile/beam/pylon_bolt
|
||||
name = "divine bolt"
|
||||
icon_state = "greyscale_bolt"
|
||||
damage = 15
|
||||
|
||||
|
||||
/obj/structure/divine/shrine
|
||||
name = "shrine"
|
||||
desc = "A shrine dedicated to a deity."
|
||||
icon_state = "shrine"
|
||||
metal_cost = 15
|
||||
glass_cost = 15
|
||||
|
||||
|
||||
/obj/structure/divine/shrine/assign_deity(mob/camera/god/new_deity, alert_old_deity = TRUE)
|
||||
if(..())
|
||||
name = "shrine to [new_deity.name]"
|
||||
desc = "A shrine dedicated to [new_deity.name]"
|
||||
|
||||
|
||||
|
||||
|
||||
//Functional, but need sprites
|
||||
/*
|
||||
/obj/structure/divine/translocator
|
||||
name = "translocator"
|
||||
desc = "A powerful structure, made with a greater gem. It allows a deity to move their nexus to where this stands"
|
||||
icon_state = "translocator"
|
||||
health = 100
|
||||
maxhealth = 100
|
||||
metal_cost = 20
|
||||
glass_cost = 20
|
||||
greater_gem_cost = 1
|
||||
|
||||
|
||||
/obj/structure/divine/lazarusaltar
|
||||
name = "lazarus altar"
|
||||
desc = "A very powerful altar capable of bringing life back to the recently deceased, made with a greater gem. It can revive anyone and will heal virtually all wounds, but they are but a shell of their former self."
|
||||
icon_state = "lazarusaltar"
|
||||
density = 0
|
||||
health = 100
|
||||
maxhealth = 100
|
||||
metal_cost = 20
|
||||
greater_gem_cost = 1
|
||||
|
||||
|
||||
/obj/structure/divine/lazarusaltar/attack_hand(mob/living/user)
|
||||
var/mob/living/L = locate() in get_turf(src)
|
||||
if(!is_handofgod_culstist(user))
|
||||
user << "<span class='notice'>You try to use it, but unfortunately you don't know any rituals.</span>"
|
||||
return
|
||||
if(!L)
|
||||
return
|
||||
|
||||
if((side == "red" && is_handofgod_redcultist(user))) || (side == "blue" && is_handofgod_bluecultist(user)))
|
||||
user << "<span class='notice'>You attempt to revive [L] by invoking the rebirth ritual.</span>"
|
||||
L.revive()
|
||||
L.adjustCloneLoss(50)
|
||||
L.adjustStaminaLoss(100)
|
||||
else
|
||||
user << "<span class='notice'>You attempt to revive [L] by invoking the rebirth ritual.</span>"
|
||||
user << "<span class='danger'>But the altar ignores your words...</span>"
|
||||
*/
|
||||
|
||||
|
||||
@@ -7,29 +7,19 @@
|
||||
var/moralecooldown = 0
|
||||
var/moralewait = 600
|
||||
|
||||
|
||||
/obj/item/weapon/banner/attack_self(mob/living/carbon/human/user)
|
||||
if(moralecooldown + moralewait > world.time)
|
||||
return
|
||||
var/side = ""
|
||||
if(is_handofgod_redcultist(user))
|
||||
side = "red"
|
||||
else if (is_handofgod_bluecultist(user))
|
||||
side = "blue"
|
||||
|
||||
if(!side)
|
||||
return
|
||||
user << "<span class='notice'>You increase the morale of your fellows!</span>"
|
||||
moralecooldown = world.time
|
||||
|
||||
for(var/mob/living/carbon/human/H in range(4,get_turf(src)))
|
||||
if((side == "red") && is_handofgod_redcultist(H) || (side == "blue") && is_handofgod_bluecultist(H))
|
||||
H << "<span class='notice'>Your morale is increased by [user]'s banner!</span>"
|
||||
H.adjustBruteLoss(-15)
|
||||
H.adjustFireLoss(-15)
|
||||
H.AdjustStunned(-2)
|
||||
H.AdjustWeakened(-2)
|
||||
H.AdjustParalysis(-2)
|
||||
H << "<span class='notice'>Your morale is increased by [user]'s banner!</span>"
|
||||
H.adjustBruteLoss(-15)
|
||||
H.adjustFireLoss(-15)
|
||||
H.AdjustStunned(-2)
|
||||
H.AdjustWeakened(-2)
|
||||
H.AdjustParalysis(-2)
|
||||
|
||||
|
||||
/obj/item/weapon/banner/red
|
||||
@@ -38,52 +28,32 @@
|
||||
item_state = "banner-red"
|
||||
desc = "A banner with the logo of the red deity."
|
||||
|
||||
/obj/item/weapon/banner/red/examine(mob/user)
|
||||
..()
|
||||
if(is_handofgod_redcultist(user))
|
||||
user << "A banner representing our might against the heretics. We may use it to increase the morale of our fellow members!"
|
||||
else if(is_handofgod_bluecultist(user))
|
||||
user << "A heretical banner that should be destroyed posthaste."
|
||||
|
||||
|
||||
/obj/item/weapon/banner/blue
|
||||
name = "blue banner"
|
||||
icon_state = "banner-blue"
|
||||
item_state = "banner-blue"
|
||||
desc = "A banner with the logo of the blue deity"
|
||||
|
||||
/obj/item/weapon/banner/blue/examine(mob/user)
|
||||
..()
|
||||
|
||||
if(is_handofgod_redcultist(user))
|
||||
user << "A heretical banner that should be destroyed posthaste."
|
||||
else if(is_handofgod_bluecultist(user))
|
||||
user << "A banner representing our might against the heretics. We may use it to increase the morale of our fellow members!"
|
||||
|
||||
|
||||
/obj/item/weapon/storage/backpack/bannerpack
|
||||
name = "nanotrasen banner backpack"
|
||||
desc = "It's a backpack with lots of extra room. A banner with Nanotrasen's logo is attached, that can't be removed."
|
||||
max_combined_w_class = 27 //6 more then normal, for the tradeoff of declaring yourself an antag at all times.
|
||||
icon_state = "bannerpack"
|
||||
|
||||
|
||||
/obj/item/weapon/storage/backpack/bannerpack/red
|
||||
name = "red banner backpack"
|
||||
desc = "It's a backpack with lots of extra room. A red banner is attached, that can't be removed."
|
||||
icon_state = "bannerpack-red"
|
||||
|
||||
|
||||
/obj/item/weapon/storage/backpack/bannerpack/blue
|
||||
name = "blue banner backpack"
|
||||
desc = "It's a backpack with lots of extra room. A blue banner is attached, that can't be removed."
|
||||
icon_state = "bannerpack-blue"
|
||||
|
||||
|
||||
|
||||
//this is all part of one item set
|
||||
/obj/item/clothing/suit/armor/plate/crusader
|
||||
name = "Crusader's Armour"
|
||||
desc = "Armour that's comprised of metal and cloth."
|
||||
icon_state = "crusader"
|
||||
w_class = 4 //bulky
|
||||
slowdown = 2.0 //gotta pretend we're balanced.
|
||||
@@ -96,16 +66,9 @@
|
||||
/obj/item/clothing/suit/armor/plate/crusader/blue
|
||||
icon_state = "crusader-blue"
|
||||
|
||||
/obj/item/clothing/suit/armor/plate/crusader/examine(mob/user)
|
||||
..()
|
||||
if(!is_handofgod_cultist(user))
|
||||
user << "Armour that's comprised of metal and cloth."
|
||||
else
|
||||
user << "Armour that was used to protect from backstabs, gunshots, explosives, and lasers. The original wearers of this type of armour were trying to avoid being murdered. Since they're not around anymore, you're not sure if they were successful or not."
|
||||
|
||||
|
||||
/obj/item/clothing/head/helmet/plate/crusader
|
||||
name = "Crusader's Hood"
|
||||
desc = "A brownish hood."
|
||||
icon_state = "crusader"
|
||||
w_class = 3 //normal
|
||||
flags_inv = HIDEHAIR|HIDEEARS|HIDEFACE
|
||||
@@ -117,140 +80,67 @@
|
||||
/obj/item/clothing/head/helmet/plate/crusader/red
|
||||
icon_state = "crusader-red"
|
||||
|
||||
|
||||
/obj/item/clothing/head/helmet/plate/crusader/examine(mob/user)
|
||||
..()
|
||||
if(!is_handofgod_cultist(user))
|
||||
user << "A brownish hood."
|
||||
else
|
||||
user << "A hood that's very protective, despite being made of cloth. Due to the tendency of the wearer to be targeted for assassinations, being protected from being shot in the face was very important.."
|
||||
|
||||
|
||||
|
||||
//Prophet helmet
|
||||
/obj/item/clothing/head/helmet/plate/crusader/prophet
|
||||
name = "Prophet's Hat"
|
||||
desc = "A religious-looking hat."
|
||||
alternate_worn_icon = 'icons/mob/large-worn-icons/64x64/head.dmi'
|
||||
flags = 0
|
||||
armor = list(melee = 60, bullet = 60, laser = 60, energy = 50, bomb = 70, bio = 50, rad = 50) //religion protects you from disease and radiation, honk.
|
||||
worn_x_dimension = 64
|
||||
worn_y_dimension = 64
|
||||
var/side = "neither"
|
||||
|
||||
/obj/item/clothing/head/helmet/plate/crusader/prophet/equipped(mob/living/carbon/user, slot)
|
||||
var/faithful = 0
|
||||
if(slot == slot_head)
|
||||
switch(side)
|
||||
if("blue")
|
||||
faithful = is_handofgod_bluecultist(user)
|
||||
if("red")
|
||||
faithful = is_handofgod_redcultist(user)
|
||||
else
|
||||
faithful = 1
|
||||
if(!faithful)
|
||||
user << "<span class='danger'>Your mind is assaulted by a vast power, furious at your desecration!</span>"
|
||||
user.emote("scream")
|
||||
user.adjustFireLoss(10)
|
||||
user.unEquip(src)
|
||||
user.head = null
|
||||
user.update_inv_head()
|
||||
src.screen_loc = null
|
||||
user.Weaken(1)
|
||||
|
||||
/obj/item/clothing/head/helmet/plate/crusader/prophet/red
|
||||
icon_state = "prophet-red"
|
||||
side = "red"
|
||||
|
||||
|
||||
/obj/item/clothing/head/helmet/plate/crusader/prophet/blue
|
||||
icon_state = "prophet-blue"
|
||||
side = "blue"
|
||||
|
||||
|
||||
/obj/item/clothing/head/helmet/plate/crusader/prophet/examine(mob/user)
|
||||
..()
|
||||
if(!is_handofgod_cultist(user))
|
||||
user << "A brownish, religious-looking hat."
|
||||
else
|
||||
user << "A hat bestowed upon a prophet of gods and demigods."
|
||||
user << "This hat belongs to the [side] god."
|
||||
|
||||
|
||||
|
||||
//Structure conversion staff
|
||||
/obj/item/weapon/godstaff
|
||||
name = "godstaff"
|
||||
desc = "It's a stick..?"
|
||||
icon_state = "godstaff-red"
|
||||
var/mob/camera/god/god = null
|
||||
var/conversion_color = "#ffffff"
|
||||
var/staffcooldown = 0
|
||||
var/staffwait = 30
|
||||
|
||||
/obj/item/weapon/godstaff/examine(mob/user)
|
||||
..()
|
||||
if(!is_handofgod_cultist(user))
|
||||
user << "It's a stick..?"
|
||||
else
|
||||
user << "A powerful staff capable of changing the allegiance of god/demigod structures."
|
||||
|
||||
|
||||
|
||||
/obj/item/weapon/godstaff/attack_self(mob/living/carbon/user)
|
||||
if((god && !god.is_handofgod_myprophet(user)) || !god)
|
||||
user << "<span class='danger'>YOU ARE NOT THE CHOSEN ONE!</span>"
|
||||
return
|
||||
if(!(istype(user.head, /obj/item/clothing/head/helmet/plate/crusader/prophet)))
|
||||
user << "<span class='warning'>Your connection to your diety isn't strong enough! You must wear your big hat!</span>"
|
||||
return
|
||||
/obj/item/weapon/godstaff/afterattack(atom/target, mob/user, proximity_flag, click_parameters)
|
||||
if(staffcooldown + staffwait > world.time)
|
||||
return
|
||||
user.visible_message("[user] chants deeply and waves their staff")
|
||||
user.visible_message("[user] chants deeply and waves their staff!")
|
||||
if(do_after(user, 20,1,src))
|
||||
for(var/obj/structure/divine/R in orange(3,user))
|
||||
user.say("Grant us true sight my god!")
|
||||
if(istype(R, /obj/structure/divine/nexus)|| istype(R, /obj/structure/divine/trap))
|
||||
continue
|
||||
R.visible_message("<span class='danger'>[R] suddenly appears!</span>")
|
||||
R.invisibility = 0
|
||||
R.alpha = initial(R.alpha)
|
||||
R.density = initial(R.density)
|
||||
R.activate()
|
||||
target.color = conversion_color //wololo
|
||||
staffcooldown = world.time
|
||||
|
||||
/obj/item/weapon/godstaff/red
|
||||
icon_state = "godstaff-red"
|
||||
conversion_color = "#ff0000"
|
||||
|
||||
/obj/item/weapon/godstaff/blue
|
||||
icon_state = "godstaff-blue"
|
||||
|
||||
|
||||
conversion_color = "#0000ff"
|
||||
|
||||
/obj/item/clothing/gloves/plate
|
||||
name = "Plate Gauntlets"
|
||||
icon_state = "crusader"
|
||||
desc = "They're like gloves, but made of metal."
|
||||
siemens_coefficient = 0
|
||||
cold_protection = HANDS
|
||||
min_cold_protection_temperature = GLOVES_MIN_TEMP_PROTECT
|
||||
heat_protection = HANDS
|
||||
max_heat_protection_temperature = GLOVES_MAX_TEMP_PROTECT
|
||||
|
||||
|
||||
/obj/item/clothing/gloves/plate/red
|
||||
icon_state = "crusader-red"
|
||||
|
||||
/obj/item/clothing/gloves/plate/blue
|
||||
icon_state = "crusader-blue"
|
||||
|
||||
|
||||
/obj/item/clothing/gloves/plate/examine(mob/user)
|
||||
..()
|
||||
if(!is_handofgod_cultist(user))
|
||||
usr << "They're like gloves, but made of metal."
|
||||
else
|
||||
usr << "Protective gloves that are also blessed to protect from heat and shock."
|
||||
|
||||
|
||||
/obj/item/clothing/shoes/plate
|
||||
name = "Plate Boots"
|
||||
desc = "Metal boots, they look heavy."
|
||||
icon_state = "crusader"
|
||||
w_class = 3 //normal
|
||||
armor = list(melee = 50, bullet = 50, laser = 50, energy = 40, bomb = 60, bio = 0, rad = 0) //does this even do anything on boots?
|
||||
@@ -268,14 +158,6 @@
|
||||
icon_state = "crusader-blue"
|
||||
|
||||
|
||||
/obj/item/clothing/shoes/plate/examine(mob/user)
|
||||
..()
|
||||
if(!is_handofgod_cultist(user))
|
||||
usr << "Metal boots, they look heavy."
|
||||
else
|
||||
usr << "Heavy boots that are blessed for sure footing. You'll be safe from being taken down by the heresy that is the banana peel."
|
||||
|
||||
|
||||
/obj/item/weapon/storage/box/itemset/crusader
|
||||
name = "Crusader's Armour Set" //i can't into ck2 references
|
||||
desc = "This armour is said to be based on the armor of kings on another world thousands of years ago, who tended to assassinate, conspire, and plot against everyone who tried to do the same to them. Some things never change."
|
||||
@@ -301,6 +183,7 @@
|
||||
new /obj/item/clothing/shoes/plate/red(src)
|
||||
|
||||
|
||||
/obj/item/weapon/claymore/hog
|
||||
/obj/item/weapon/claymore/weak
|
||||
desc = "This one is rusted."
|
||||
force = 30
|
||||
armour_penetration = 15
|
||||
@@ -32,7 +32,7 @@
|
||||
return -1
|
||||
if(target.mind in ticker.mode.revolutionaries)
|
||||
ticker.mode.remove_revolutionary(target.mind)
|
||||
if((target.mind in ticker.mode.cult) || (target.mind in ticker.mode.blue_deity_prophets|ticker.mode.red_deity_prophets|ticker.mode.red_deity_followers|ticker.mode.blue_deity_followers))
|
||||
if(target.mind in ticker.mode.cult)
|
||||
target << "<span class='warning'>You feel something interfering with your mental conditioning, but you resist it!</span>"
|
||||
else
|
||||
target << "<span class='notice'>You feel a sense of peace and security. You are now protected from brainwashing.</span>"
|
||||
@@ -46,7 +46,6 @@
|
||||
return 1
|
||||
return 0
|
||||
|
||||
|
||||
/obj/item/weapon/implanter/mindshield
|
||||
name = "implanter (mindshield)"
|
||||
|
||||
|
||||
244
code/game/objects/structures/divine.dm
Normal file
244
code/game/objects/structures/divine.dm
Normal file
@@ -0,0 +1,244 @@
|
||||
/obj/structure/divine
|
||||
name = "divine construction site"
|
||||
icon = 'icons/obj/hand_of_god_structures.dmi'
|
||||
desc = "An unfinished divine building"
|
||||
anchored = 1
|
||||
density = 1
|
||||
var/trap = FALSE
|
||||
var/side = "neutral" //only used to decide icon states
|
||||
var/health = 100
|
||||
var/maxhealth = 100
|
||||
var/deactivated = 0 //Structures being hidden can't be used. Mainly to prevent invisible defense pylons.
|
||||
|
||||
/obj/structure/divine/proc/deactivate()
|
||||
deactivated = 1
|
||||
|
||||
/obj/structure/divine/proc/activate()
|
||||
deactivated = 0
|
||||
|
||||
/obj/structure/divine/proc/update_icons()
|
||||
icon_state = "[initial(icon_state)]-[side]"
|
||||
|
||||
/obj/structure/divine/attacked_by(obj/item/I, mob/living/user)
|
||||
..()
|
||||
take_damage(I.force, I.damtype, 1)
|
||||
|
||||
/obj/structure/divine/proc/take_damage(damage, damage_type = BRUTE, sound_effect = 1)
|
||||
switch(damage_type)
|
||||
if(BRUTE)
|
||||
if(sound_effect)
|
||||
if(damage)
|
||||
playsound(loc, 'sound/weapons/smash.ogg', 50, 1)
|
||||
else
|
||||
playsound(loc, 'sound/weapons/tap.ogg', 50, 1)
|
||||
if(BURN)
|
||||
if(sound_effect)
|
||||
playsound(src.loc, 'sound/items/Welder.ogg', 100, 1)
|
||||
else
|
||||
return
|
||||
health -= damage
|
||||
if(!health)
|
||||
visible_message("<span class='danger'>\The [src] was destroyed!</span>")
|
||||
qdel(src)
|
||||
|
||||
|
||||
/obj/structure/divine/bullet_act(obj/item/projectile/P)
|
||||
. = ..()
|
||||
take_damage(P.damage, P.damage_type, 0)
|
||||
|
||||
|
||||
/obj/structure/divine/attack_alien(mob/living/carbon/alien/humanoid/user)
|
||||
user.changeNext_move(CLICK_CD_MELEE)
|
||||
user.do_attack_animation(src)
|
||||
add_hiddenprint(user)
|
||||
visible_message("<span class='warning'>\The [user] slashes at [src]!</span>")
|
||||
playsound(src.loc, 'sound/weapons/slash.ogg', 100, 1)
|
||||
take_damage(20, BRUTE, 0)
|
||||
|
||||
/obj/machinery/attack_animal(mob/living/simple_animal/M)
|
||||
M.changeNext_move(CLICK_CD_MELEE)
|
||||
M.do_attack_animation(src)
|
||||
if(M.melee_damage_upper > 0 || M.obj_damage)
|
||||
M.visible_message("<span class='danger'>[M.name] smashes against \the [src.name].</span>",\
|
||||
"<span class='danger'>You smash against the [src.name].</span>")
|
||||
if(M.obj_damage)
|
||||
take_damage(M.obj_damage, M.melee_damage_type, 1)
|
||||
else
|
||||
take_damage(rand(M.melee_damage_lower,M.melee_damage_upper), M.melee_damage_type, 1)
|
||||
|
||||
/obj/structure/divine/nexus
|
||||
name = "nexus"
|
||||
desc = "It anchors a deity to this world. It radiates an unusual aura. It looks well protected from explosive shock."
|
||||
icon_state = "nexus"
|
||||
health = 500
|
||||
maxhealth = 500
|
||||
var/list/powerpylons = list()
|
||||
|
||||
/obj/structure/divine/nexus/ex_act()
|
||||
return
|
||||
|
||||
/obj/structure/divine/conduit
|
||||
name = "conduit"
|
||||
desc = "It allows a deity to extend their reach. Their powers are just as potent near a conduit as a nexus."
|
||||
icon_state = "conduit"
|
||||
health = 150
|
||||
maxhealth = 150
|
||||
|
||||
/obj/structure/divine/convertaltar
|
||||
name = "conversion altar"
|
||||
desc = "An altar dedicated to a deity."
|
||||
icon_state = "convertaltar"
|
||||
density = 0
|
||||
can_buckle = 1
|
||||
|
||||
/obj/structure/divine/sacrificealtar
|
||||
name = "sacrificial altar"
|
||||
desc = "An altar designed to perform blood sacrifice for a deity."
|
||||
icon_state = "sacrificealtar"
|
||||
density = 0
|
||||
can_buckle = 1
|
||||
|
||||
/obj/structure/divine/sacrificealtar/attack_hand(mob/living/user)
|
||||
..()
|
||||
if(!has_buckled_mobs())
|
||||
return
|
||||
var/mob/living/L = locate() in buckled_mobs
|
||||
if(!L)
|
||||
return
|
||||
user << "<span class='notice'>You attempt to sacrifice [L] by invoking the sacrificial ritual.</span>"
|
||||
L.gib()
|
||||
message_admins("[key_name_admin(user)] has sacrificed [key_name_admin(L)] on the sacrifical altar.")
|
||||
|
||||
/obj/structure/divine/healingfountain
|
||||
name = "healing fountain"
|
||||
desc = "A fountain containing the waters of life... or death, depending on where your allegiances lie."
|
||||
icon_state = "fountain"
|
||||
var/time_between_uses = 1800
|
||||
var/last_process = 0
|
||||
var/cult_only = TRUE
|
||||
|
||||
/obj/structure/divine/healingfountain/anyone
|
||||
desc = "A fountain containing the waters of life."
|
||||
cult_only = FALSE
|
||||
|
||||
/obj/structure/divine/healingfountain/attack_hand(mob/living/user)
|
||||
if(deactivated)
|
||||
return
|
||||
if(last_process + time_between_uses > world.time)
|
||||
user << "<span class='notice'>The fountain appears to be empty.</span>"
|
||||
return
|
||||
last_process = world.time
|
||||
if(!iscultist(user) && cult_only)
|
||||
user << "<span class='danger'><B>The water burns!</b></spam>"
|
||||
user.reagents.add_reagent("hell_water",20)
|
||||
else
|
||||
user << "<span class='notice'>The water feels warm and soothing as you touch it. The fountain immediately dries up shortly afterwards.</span>"
|
||||
user.reagents.add_reagent("godblood",20)
|
||||
update_icons()
|
||||
addtimer(src, "update_icons", time_between_uses)
|
||||
|
||||
|
||||
/obj/structure/divine/healingfountain/update_icons()
|
||||
if(last_process + time_between_uses > world.time)
|
||||
icon_state = "fountain"
|
||||
else
|
||||
icon_state = "fountain-[side]"
|
||||
|
||||
|
||||
/obj/structure/divine/powerpylon
|
||||
name = "power pylon"
|
||||
desc = "A pylon which increases the deity's rate it can influence the world."
|
||||
icon_state = "powerpylon"
|
||||
density = 1
|
||||
health = 30
|
||||
maxhealth = 30
|
||||
|
||||
/obj/structure/divine/defensepylon
|
||||
name = "defense pylon"
|
||||
desc = "A pylon which is blessed to withstand many blows, and fire strong bolts at nonbelievers. A god can toggle it."
|
||||
icon_state = "defensepylon"
|
||||
health = 150
|
||||
maxhealth = 150
|
||||
var/gun_faction = "cult"
|
||||
var/obj/machinery/porta_turret/defensepylon_internal_turret/pylon_gun
|
||||
|
||||
|
||||
/obj/structure/divine/defensepylon/New()
|
||||
..()
|
||||
pylon_gun = new(src)
|
||||
pylon_gun.base = src
|
||||
pylon_gun.faction = list(gun_faction)
|
||||
pylon_gun.side = side
|
||||
|
||||
|
||||
/obj/structure/divine/defensepylon/Destroy()
|
||||
qdel(pylon_gun) //just in case
|
||||
return ..()
|
||||
|
||||
/obj/structure/divine/defensepylon/examine(mob/user)
|
||||
..()
|
||||
user << "<span class='notice'>\The [src] looks [pylon_gun.on ? "on" : "off"].</span>"
|
||||
|
||||
/obj/structure/divine/defensepylon/attack_hand(mob/living/user)
|
||||
if(gun_faction in user.faction)
|
||||
pylon_gun.on = !pylon_gun.on
|
||||
icon_state = (pylon_gun.on) ? "defensepylon-[side]" : "defensepylon"
|
||||
else
|
||||
. = ..()
|
||||
|
||||
/obj/structure/divine/defensepylon/deactivate()
|
||||
..()
|
||||
pylon_gun.on = 0
|
||||
icon_state = (pylon_gun.on) ? "defensepylon-[side]" : "defensepylon"
|
||||
|
||||
/obj/structure/divine/defensepylon/activate()
|
||||
..()
|
||||
pylon_gun.on = 1
|
||||
icon_state = (pylon_gun.on) ? "defensepylon-[side]" : "defensepylon"
|
||||
|
||||
//This sits inside the defensepylon, to avoid copypasta
|
||||
/obj/machinery/porta_turret/defensepylon_internal_turret
|
||||
name = "defense pylon"
|
||||
desc = "A plyon which is blessed to withstand many blows, and fire strong bolts at nonbelievers."
|
||||
icon = 'icons/obj/hand_of_god_structures.dmi'
|
||||
installation = null
|
||||
always_up = 1
|
||||
use_power = 0
|
||||
has_cover = 0
|
||||
health = 200
|
||||
projectile = /obj/item/projectile/beam/pylon_bolt
|
||||
eprojectile = /obj/item/projectile/beam/pylon_bolt
|
||||
shot_sound = 'sound/weapons/emitter2.ogg'
|
||||
eshot_sound = 'sound/weapons/emitter2.ogg'
|
||||
base_icon_state = "defensepylon"
|
||||
active_state = ""
|
||||
off_state = ""
|
||||
faction = null
|
||||
emp_vunerable = 0
|
||||
var/side = "neutral"
|
||||
|
||||
/obj/machinery/porta_turret/defensepylon_internal_turret/setup()
|
||||
return
|
||||
|
||||
/obj/machinery/porta_turret/defensepylon_internal_turret/shootAt(atom/movable/target)
|
||||
var/obj/item/projectile/A = ..()
|
||||
if(A)
|
||||
A.color = side
|
||||
|
||||
/obj/machinery/porta_turret/defensepylon_internal_turret/assess_perp(mob/living/carbon/human/perp)
|
||||
if(perp.handcuffed) //dishonourable to kill somebody who might be converted.
|
||||
return 0
|
||||
var/list/test = faction & perp.faction
|
||||
if(test.len)
|
||||
return 0
|
||||
return 10
|
||||
|
||||
/obj/item/projectile/beam/pylon_bolt
|
||||
name = "divine bolt"
|
||||
icon_state = "greyscale_bolt"
|
||||
damage = 15
|
||||
|
||||
/obj/structure/divine/shrine
|
||||
name = "shrine"
|
||||
desc = "A shrine dedicated to a deity."
|
||||
icon_state = "shrine"
|
||||
@@ -8,7 +8,6 @@
|
||||
health = 20
|
||||
maxhealth = 20
|
||||
trap = TRUE
|
||||
autocolours = FALSE
|
||||
var/last_trigger = 0
|
||||
var/time_between_triggers = 600 //takes a minute to recharge
|
||||
|
||||
@@ -24,7 +23,6 @@
|
||||
trap_effect(L)
|
||||
animate(src, alpha = initial(alpha), time = time_between_triggers)
|
||||
|
||||
|
||||
/obj/structure/divine/trap/examine(mob/user)
|
||||
..()
|
||||
if(!isliving(user)) //bad ghosts, stop trying to powergame from beyond the grave
|
||||
@@ -37,13 +35,11 @@
|
||||
/obj/structure/divine/trap/proc/trap_effect(mob/living/L)
|
||||
return
|
||||
|
||||
|
||||
/obj/structure/divine/trap/stun
|
||||
name = "shock trap"
|
||||
desc = "A trap that will shock you, it will burn your flesh and render you immobile, You'd better avoid it."
|
||||
icon_state = "trap-shock"
|
||||
|
||||
|
||||
/obj/structure/divine/trap/stun/trap_effect(mob/living/L)
|
||||
L << "<span class='danger'><B>You are paralyzed from the intense shock!</B></span>"
|
||||
L.Weaken(5)
|
||||
@@ -478,66 +478,6 @@
|
||||
dat += "<td><A href='?_src_=holder;adminplayerobservefollow=\ref[M]'>FLW</a></td></tr>"
|
||||
dat += "</table>"
|
||||
|
||||
if(ticker.mode.red_deities.len || ticker.mode.red_deity_prophets.len || ticker.mode.blue_deity_prophets.len || ticker.mode.red_deity_followers.len || ticker.mode.blue_deity_followers.len)
|
||||
dat += "<br><table cellspacing=5><tr><td><B>Red Deity</B></td><td></td></tr>"
|
||||
for(var/datum/mind/N in ticker.mode.red_deities)
|
||||
var/mob/M = N.current
|
||||
if(M)
|
||||
dat += "<tr><td>Red Deity: <a href='?_src_=holder;adminplayeropts=\ref[M]'>[M.real_name]</a>[M.client ? "" : " <i>(No Client)</i>"][M.stat == 2 ? " <b><font color=red>(DEAD)</font></b>" : ""]</td>"
|
||||
dat += "<td><A href='?priv_msg=[M.ckey]'>PM</A></td>"
|
||||
dat += "<td><A href='?_src_=holder;adminplayerobservefollow=\ref[M]'>FLW</a></td></tr>"
|
||||
dat += "</table>"
|
||||
|
||||
if(ticker.mode.blue_deities.len)
|
||||
dat += "<br><table cellspacing=5><tr><td><B>Blue Deity</B></td><td></td></tr>"
|
||||
for(var/datum/mind/N in ticker.mode.blue_deities)
|
||||
var/mob/M = N.current
|
||||
if(M)
|
||||
dat += "<tr><td>Blue Deity: <a href='?_src_=holder;adminplayeropts=\ref[M]'>[M.real_name]</a>[M.client ? "" : " <i>(No Client)</i>"][M.stat == 2 ? " <b><font color=red>(DEAD)</font></b>" : ""]</td>"
|
||||
dat += "<td><A href='?priv_msg=[M.ckey]'>PM</A></td>"
|
||||
dat += "<td><A href='?_src_=holder;adminplayerobservefollow=\ref[M]'>FLW</a></td></tr>"
|
||||
dat += "</table>"
|
||||
|
||||
if(ticker.mode.red_deity_prophets.len)
|
||||
dat += "<br><table cellspacing=5><tr><td><B>Red Deity Prophets</B></td><td></td></tr>"
|
||||
for(var/datum/mind/N in ticker.mode.red_deity_prophets)
|
||||
var/mob/M = N.current
|
||||
if(M)
|
||||
dat += "<tr><td>Red Deity Prophet: <a href='?_src_=holder;adminplayeropts=\ref[M]'>[M.real_name]</a>[M.client ? "" : " <i>(No Client)</i>"][M.stat == 2 ? " <b><font color=red>(DEAD)</font></b>" : ""]</td>"
|
||||
dat += "<td><A href='?priv_msg=[M.ckey]'>PM</A></td>"
|
||||
dat += "<td><A href='?_src_=holder;adminplayerobservefollow=\ref[M]'>FLW</a></td></tr>"
|
||||
dat += "</table>"
|
||||
|
||||
if(ticker.mode.blue_deity_prophets.len)
|
||||
dat += "<br><table cellspacing=5><tr><td><B>Blue Deity Prophets</B></td><td></td></tr>"
|
||||
for(var/datum/mind/N in ticker.mode.blue_deity_prophets)
|
||||
var/mob/M = N.current
|
||||
if(M)
|
||||
dat += "<tr><td>Blue Deity Prophet: <a href='?_src_=holder;adminplayeropts=\ref[M]'>[M.real_name]</a>[M.client ? "" : " <i>(No Client)</i>"][M.stat == 2 ? " <b><font color=red>(DEAD)</font></b>" : ""]</td>"
|
||||
dat += "<td><A href='?priv_msg=[M.ckey]'>PM</A></td>"
|
||||
dat += "<td><A href='?_src_=holder;adminplayerobservefollow=\ref[M]'>FLW</a></td></tr>"
|
||||
dat += "</table>"
|
||||
|
||||
if(ticker.mode.red_deity_followers.len)
|
||||
dat += "<br><table cellspacing=5><tr><td><B>Red Deity Followers</B></td><td></td></tr>"
|
||||
for(var/datum/mind/N in ticker.mode.red_deity_followers)
|
||||
var/mob/M = N.current
|
||||
if(M)
|
||||
dat += "<tr><td>Red Deity Followers: <a href='?_src_=holder;adminplayeropts=\ref[M]'>[M.real_name]</a>[M.client ? "" : " <i>(No Client)</i>"][M.stat == 2 ? " <b><font color=red>(DEAD)</font></b>" : ""]</td>"
|
||||
dat += "<td><A href='?priv_msg=[M.ckey]'>PM</A></td>"
|
||||
dat += "<td><A href='?_src_=holder;adminplayerobservefollow=\ref[M]'>FLW</a></td></tr>"
|
||||
dat += "</table>"
|
||||
|
||||
if(ticker.mode.blue_deity_followers.len)
|
||||
dat += "<br><table cellspacing=5><tr><td><B>Blue Deity Followers</B></td><td></td></tr>"
|
||||
for(var/datum/mind/N in ticker.mode.blue_deity_followers)
|
||||
var/mob/M = N.current
|
||||
if(M)
|
||||
dat += "<tr><td>Blue Deity Followers: <a href='?_src_=holder;adminplayeropts=\ref[M]'>[M.real_name]</a>[M.client ? "" : " <i>(No Client)</i>"][M.stat == 2 ? " <b><font color=red>(DEAD)</font></b>" : ""]</td>"
|
||||
dat += "<td><A href='?priv_msg=[M.ckey]'>PM</A></td>"
|
||||
dat += "<td><A href='?_src_=holder;adminplayerobservefollow=\ref[M]'>FLW</a></td></tr>"
|
||||
dat += "</table>"
|
||||
|
||||
if(ticker.mode.traitors.len > 0)
|
||||
dat += "<br><table cellspacing=5><tr><td><B>Traitors</B></td><td></td><td></td></tr>"
|
||||
for(var/datum/mind/traitor in ticker.mode.traitors)
|
||||
|
||||
@@ -470,7 +470,6 @@
|
||||
health = INFINITY
|
||||
maxhealth = INFINITY
|
||||
var/team = WHITE_TEAM
|
||||
constructable = FALSE
|
||||
time_between_triggers = 1
|
||||
alpha = 255
|
||||
|
||||
@@ -482,7 +481,6 @@
|
||||
L << "<span class='danger'><B>Stay out of the enemy spawn!</B></span>"
|
||||
L.death()
|
||||
|
||||
|
||||
/obj/structure/divine/trap/ctf/red
|
||||
team = RED_TEAM
|
||||
icon_state = "trap-fire"
|
||||
|
||||
@@ -3,5 +3,4 @@
|
||||
ticker.mode.remove_cultist(mind, 0, 0)
|
||||
ticker.mode.remove_revolutionary(mind, 0)
|
||||
ticker.mode.remove_gangster(mind, remove_bosses=1)
|
||||
ticker.mode.remove_hog_follower(mind,0)
|
||||
..()
|
||||
|
||||
@@ -6,4 +6,3 @@
|
||||
if(mind)
|
||||
ticker.mode.remove_revolutionary(mind)
|
||||
ticker.mode.remove_gangster(mind,1,remove_bosses=1)
|
||||
ticker.mode.remove_hog_follower(mind, 0)
|
||||
|
||||
@@ -70,7 +70,7 @@
|
||||
loot = list(/obj/effect/decal/remains/human,
|
||||
/obj/item/clothing/suit/armor/riot/knight/templar,
|
||||
/obj/item/clothing/head/helmet/knight/templar,
|
||||
/obj/item/weapon/claymore/hog{name = "holy sword"})
|
||||
/obj/item/weapon/claymore/weak{name = "holy sword"})
|
||||
|
||||
/mob/living/simple_animal/hostile/skeleton/ice
|
||||
name = "ice skeleton"
|
||||
|
||||
@@ -486,23 +486,6 @@
|
||||
qdel(src)
|
||||
|
||||
|
||||
/mob/proc/become_god(var/side_colour)
|
||||
var/mob/camera/god/G = new /mob/camera/god(loc)
|
||||
G.side = side_colour
|
||||
if(mind)
|
||||
mind.transfer_to(G)
|
||||
else
|
||||
G.key = key
|
||||
|
||||
G.job = "Deity"
|
||||
G.rename_self("deity")
|
||||
G.update_icons()
|
||||
|
||||
. = G
|
||||
qdel(src)
|
||||
|
||||
|
||||
|
||||
/mob/living/carbon/human/proc/corgize()
|
||||
if (notransform)
|
||||
return
|
||||
|
||||
@@ -188,11 +188,9 @@
|
||||
if("emote")
|
||||
M.visible_message("<span class='warning'>[M] [pick("whimpers quietly", "shivers as though cold", "glances around in paranoia")].</span>")
|
||||
if(data >= 75) // 30 units, 135 seconds
|
||||
if(iscultist(M) || is_handofgod_cultist(M) || is_handofgod_prophet(M) || is_servant_of_ratvar(M))
|
||||
if(iscultist(M) || is_servant_of_ratvar(M))
|
||||
if(iscultist(M))
|
||||
ticker.mode.remove_cultist(M.mind, 1, 1)
|
||||
else if(is_handofgod_cultist(M) || is_handofgod_prophet(M))
|
||||
ticker.mode.remove_hog_follower(M.mind)
|
||||
else if(is_servant_of_ratvar(M))
|
||||
remove_servant_of_ratvar(M)
|
||||
holder.remove_reagent(id, volume) // maybe this is a little too perfect and a max() cap on the statuses would be better??
|
||||
|
||||
@@ -69,7 +69,7 @@
|
||||
R.adjustHealth(50)
|
||||
sleep(20)
|
||||
for(var/mob/living/carbon/C in get_hearers_in_view(round(created_volume/48,1),get_turf(holder.my_atom)))
|
||||
if(iscultist(C) || is_handofgod_cultist(C))
|
||||
if(iscultist(C))
|
||||
C << "<span class='userdanger'>The divine explosion sears you!</span>"
|
||||
C.Weaken(2)
|
||||
C.adjust_fire_stacks(5)
|
||||
|
||||
@@ -365,14 +365,6 @@
|
||||
#include "code\game\gamemodes\gang\gang_datum.dm"
|
||||
#include "code\game\gamemodes\gang\gang_pen.dm"
|
||||
#include "code\game\gamemodes\gang\recaller.dm"
|
||||
#include "code\game\gamemodes\handofgod\_handofgod.dm"
|
||||
#include "code\game\gamemodes\handofgod\actions.dm"
|
||||
#include "code\game\gamemodes\handofgod\god.dm"
|
||||
#include "code\game\gamemodes\handofgod\items.dm"
|
||||
#include "code\game\gamemodes\handofgod\objectives.dm"
|
||||
#include "code\game\gamemodes\handofgod\powers.dm"
|
||||
#include "code\game\gamemodes\handofgod\structures.dm"
|
||||
#include "code\game\gamemodes\handofgod\traps.dm"
|
||||
#include "code\game\gamemodes\malfunction\Malf_Modules.dm"
|
||||
#include "code\game\gamemodes\meteor\meteor.dm"
|
||||
#include "code\game\gamemodes\meteor\meteors.dm"
|
||||
@@ -604,6 +596,7 @@
|
||||
#include "code\game\objects\items\documents.dm"
|
||||
#include "code\game\objects\items\latexballoon.dm"
|
||||
#include "code\game\objects\items\nuke_tools.dm"
|
||||
#include "code\game\objects\items\religion.dm"
|
||||
#include "code\game\objects\items\shooting_range.dm"
|
||||
#include "code\game\objects\items\toys.dm"
|
||||
#include "code\game\objects\items\trash.dm"
|
||||
@@ -749,6 +742,7 @@
|
||||
#include "code\game\objects\structures\bedsheet_bin.dm"
|
||||
#include "code\game\objects\structures\destructible_structures.dm"
|
||||
#include "code\game\objects\structures\displaycase.dm"
|
||||
#include "code\game\objects\structures\divine.dm"
|
||||
#include "code\game\objects\structures\door_assembly.dm"
|
||||
#include "code\game\objects\structures\dresser.dm"
|
||||
#include "code\game\objects\structures\electricchair.dm"
|
||||
@@ -784,6 +778,7 @@
|
||||
#include "code\game\objects\structures\tables_racks.dm"
|
||||
#include "code\game\objects\structures\tank_dispenser.dm"
|
||||
#include "code\game\objects\structures\target_stake.dm"
|
||||
#include "code\game\objects\structures\traps.dm"
|
||||
#include "code\game\objects\structures\watercloset.dm"
|
||||
#include "code\game\objects\structures\windoor_assembly.dm"
|
||||
#include "code\game\objects\structures\window.dm"
|
||||
|
||||
Reference in New Issue
Block a user