About a million changes, but largely: Functional (Sort of) Antag Huds, Mind fixes, and Final glue to get the mode working.

This commit is contained in:
Remie Richards
2015-10-07 22:11:19 +01:00
parent 059a1700a7
commit b9394257da
65 changed files with 475 additions and 329 deletions

View File

@@ -28,22 +28,3 @@
#define TOGGLES_DEFAULT_CHAT (CHAT_OOC|CHAT_DEAD|CHAT_GHOSTEARS|CHAT_GHOSTSIGHT|CHAT_PRAYER|CHAT_RADIO|CHAT_PULLR|CHAT_GHOSTWHISPER|CHAT_GHOSTPDA|CHAT_GHOSTRADIO) #define TOGGLES_DEFAULT_CHAT (CHAT_OOC|CHAT_DEAD|CHAT_GHOSTEARS|CHAT_GHOSTSIGHT|CHAT_PRAYER|CHAT_RADIO|CHAT_PULLR|CHAT_GHOSTWHISPER|CHAT_GHOSTPDA|CHAT_GHOSTRADIO)
//Antag preferences
#define BE_TRAITOR 1
#define BE_OPERATIVE 2
#define BE_CHANGELING 3
#define BE_WIZARD 4
#define BE_MALF 5
#define BE_REV 6
#define BE_ALIEN 7
#define BE_PAI 8
#define BE_CULTIST 9
#define BE_BLOB 10
#define BE_NINJA 11
#define BE_MONKEY 12
#define BE_GANG 13
#define BE_SHADOWLING 14
#define BE_ABDUCTOR 15
#define BE_REVENANT 16
#define BE_HOG_GOD 17
#define BE_HOG_CULTIST 18

View File

@@ -0,0 +1,50 @@
//Values for antag preferences, event roles, etc. unified here
//These are synced with the Database, if you change the values of the defines
//then you MUST update the database!
#define ROLE_TRAITOR "traitor"
#define ROLE_OPERATIVE "operative"
#define ROLE_CHANGELING "changeling"
#define ROLE_WIZARD "wizard"
#define ROLE_MALF "malf AI"
#define ROLE_REV "revolutionary"
#define ROLE_ALIEN "xenomorph"
#define ROLE_PAI "pAI"
#define ROLE_CULTIST "cultist"
#define ROLE_BLOB "blob"
#define ROLE_NINJA "space ninja"
#define ROLE_MONKEY "monkey"
#define ROLE_GANG "gangster"
#define ROLE_SHADOWLING "shadowling"
#define ROLE_ABDUCTOR "abductor"
#define ROLE_REVENANT "revenant"
#define ROLE_HOG_GOD "hand of god: god"
#define ROLE_HOG_CULTIST "hand of god: cultist"
//Missing assignment means it's not a gamemode specific role, IT'S NOT A BUG OR ERROR.
//The gamemode specific ones are just so the gamemodes can query whether a player is old enough
//(in game days played) to play that role
var/global/list/special_roles = list(
ROLE_TRAITOR = /datum/game_mode/traitor,
ROLE_OPERATIVE = /datum/game_mode/nuclear,
ROLE_CHANGELING = /datum/game_mode/changeling,
ROLE_WIZARD = /datum/game_mode/wizard,
ROLE_MALF = /datum/game_mode/malfunction,
ROLE_REV = /datum/game_mode/revolution,
ROLE_ALIEN,
ROLE_PAI,
ROLE_CULTIST = /datum/game_mode/cult,
ROLE_BLOB = /datum/game_mode/blob,
ROLE_NINJA,
ROLE_MONKEY = /datum/game_mode/monkey,
ROLE_GANG = /datum/game_mode/gang,
ROLE_SHADOWLING = /datum/game_mode/shadowling,
ROLE_ABDUCTOR = /datum/game_mode/abduction,
ROLE_HOG_GOD = /datum/game_mode/hand_of_god,
ROLE_HOG_CULTIST = /datum/game_mode/hand_of_god,
)

View File

@@ -33,23 +33,3 @@ var/MAX_EX_LIGHT_RANGE = 14
var/MAX_EX_FLASH_RANGE = 14 var/MAX_EX_FLASH_RANGE = 14
var/MAX_EX_FLAME_RANGE = 14 var/MAX_EX_FLAME_RANGE = 14
var/list/be_special_flags = list(
"Traitor" = BE_TRAITOR,
"Operative" = BE_OPERATIVE,
"Changeling" = BE_CHANGELING,
"Wizard" = BE_WIZARD,
"Malf AI" = BE_MALF,
"Revolutionary" = BE_REV,
"Alien Lifeform" = BE_ALIEN,
"pAI" = BE_PAI,
"Cultist" = BE_CULTIST,
"Blob" = BE_BLOB,
"Ninja" = BE_NINJA,
"Monkey" = BE_MONKEY,
"Gang" = BE_GANG,
"Abductor" = BE_ABDUCTOR,
"Revenant" = BE_REVENANT,
"Shadowling" = BE_SHADOWLING,
"Hand of god, god" = BE_HOG_GOD,
"Hand of god, cultist" = BE_HOG_CULTIST
)

View File

@@ -181,7 +181,7 @@ var/datum/subsystem/pai/SSpai
/datum/subsystem/pai/proc/requestRecruits() /datum/subsystem/pai/proc/requestRecruits()
for(var/mob/dead/observer/O in player_list) for(var/mob/dead/observer/O in player_list)
if(jobban_isbanned(O, "pAI")) if(jobban_isbanned(O, ROLE_PAI))
continue continue
if(asked.Find(O.key)) if(asked.Find(O.key))
if(world.time < asked[O.key] + askDelay) if(world.time < asked[O.key] + askDelay)
@@ -193,7 +193,7 @@ var/datum/subsystem/pai/SSpai
for(var/datum/paiCandidate/c in SSpai.candidates) for(var/datum/paiCandidate/c in SSpai.candidates)
if(c.key == O.key) if(c.key == O.key)
hasSubmitted = 1 hasSubmitted = 1
if(!hasSubmitted && (BE_PAI in O.client.prefs.be_special)) if(!hasSubmitted && (ROLE_PAI in O.client.prefs.be_special))
question(O.client) question(O.client)
/datum/subsystem/pai/proc/question(client/C) /datum/subsystem/pai/proc/question(client/C)

View File

@@ -21,6 +21,8 @@ var/datum/atom_hud/huds = list( \
var/list/hud_icons = list() //these will be the indexes for the atom's hud_list var/list/hud_icons = list() //these will be the indexes for the atom's hud_list
/datum/atom_hud/proc/remove_hud_from(mob/M) /datum/atom_hud/proc/remove_hud_from(mob/M)
if(!M)
return
if(src in M.permanent_huds) if(src in M.permanent_huds)
return return
for(var/atom/A in hudatoms) for(var/atom/A in hudatoms)
@@ -28,30 +30,37 @@ var/datum/atom_hud/huds = list( \
hudusers -= M hudusers -= M
/datum/atom_hud/proc/remove_from_hud(atom/A) /datum/atom_hud/proc/remove_from_hud(atom/A)
if(!A)
return
for(var/mob/M in hudusers) for(var/mob/M in hudusers)
remove_from_single_hud(M, A) remove_from_single_hud(M, A)
hudatoms -= A hudatoms -= A
/datum/atom_hud/proc/remove_from_single_hud(mob/M, atom/A) //unsafe, no sanity apart from client /datum/atom_hud/proc/remove_from_single_hud(mob/M, atom/A) //unsafe, no sanity apart from client
if(!M.client) if(!M || !M.client || !A)
return return
for(var/i in hud_icons) for(var/i in hud_icons)
M.client.images -= A.hud_list[i] M.client.images -= A.hud_list[i]
/datum/atom_hud/proc/add_hud_to(mob/M) /datum/atom_hud/proc/add_hud_to(mob/M)
if(!M)
return
hudusers |= M hudusers |= M
for(var/atom/A in hudatoms) for(var/atom/A in hudatoms)
add_to_single_hud(M, A) add_to_single_hud(M, A)
/datum/atom_hud/proc/add_to_hud(atom/A) /datum/atom_hud/proc/add_to_hud(atom/A)
if(!A)
return
hudatoms |= A hudatoms |= A
for(var/mob/M in hudusers) for(var/mob/M in hudusers)
add_to_single_hud(M, A) add_to_single_hud(M, A)
/datum/atom_hud/proc/add_to_single_hud(mob/M, atom/A) //unsafe, no sanity apart from client /datum/atom_hud/proc/add_to_single_hud(mob/M, atom/A) //unsafe, no sanity apart from client
if(!M.client) if(!M || !M.client || !A)
return return
for(var/i in hud_icons) for(var/i in hud_icons)
if(A.hud_list[i])
M.client.images |= A.hud_list[i] M.client.images |= A.hud_list[i]
//MOB PROCS //MOB PROCS

View File

@@ -61,10 +61,10 @@
src.key = key src.key = key
/datum/mind/proc/transfer_to(mob/living/new_character) /datum/mind/proc/transfer_to(mob/new_character)
if(!istype(new_character)) //if(!istype(new_character))
throw EXCEPTION("transfer_to(): new_character must be mob/living") // throw EXCEPTION("transfer_to(): new_character must be mob/living")
return // return
if(current) //remove ourself from our old body's mind variable if(current) //remove ourself from our old body's mind variable
current.mind = null current.mind = null
@@ -285,7 +285,7 @@
else else
text += "head|loyal|<b>EMPLOYEE</b>|<a href='?src=\ref[src];revolution=headrev'>headrev</a>|<a href='?src=\ref[src];revolution=rev'>rev</a>" text += "head|loyal|<b>EMPLOYEE</b>|<a href='?src=\ref[src];revolution=headrev'>headrev</a>|<a href='?src=\ref[src];revolution=rev'>rev</a>"
if(current && current.client && (BE_REV in current.client.prefs.be_special)) if(current && current.client && (ROLE_REV in current.client.prefs.be_special))
text += "|Enabled in Prefs" text += "|Enabled in Prefs"
else else
text += "|Disabled in Prefs" text += "|Disabled in Prefs"
@@ -303,7 +303,7 @@
else else
text += "<B>NONE</B>" text += "<B>NONE</B>"
if(current && current.client && (BE_GANG in current.client.prefs.be_special)) if(current && current.client && (ROLE_GANG in current.client.prefs.be_special))
text += "|Enabled in Prefs<BR>" text += "|Enabled in Prefs<BR>"
else else
text += "|Disabled in Prefs<BR>" text += "|Disabled in Prefs<BR>"
@@ -350,7 +350,7 @@
else else
text += "loyal|<b>EMPLOYEE</b>|<a href='?src=\ref[src];cult=cultist'>cultist</a>" text += "loyal|<b>EMPLOYEE</b>|<a href='?src=\ref[src];cult=cultist'>cultist</a>"
if(current && current.client && (BE_CULTIST in current.client.prefs.be_special)) if(current && current.client && (ROLE_CULTIST in current.client.prefs.be_special))
text += "|Enabled in Prefs" text += "|Enabled in Prefs"
else else
text += "|Disabled in Prefs" text += "|Disabled in Prefs"
@@ -370,7 +370,7 @@
else else
text += "<a href='?src=\ref[src];wizard=wizard'>yes</a>|<b>NO</b>" text += "<a href='?src=\ref[src];wizard=wizard'>yes</a>|<b>NO</b>"
if(current && current.client && (BE_WIZARD in current.client.prefs.be_special)) if(current && current.client && (ROLE_WIZARD in current.client.prefs.be_special))
text += "|Enabled in Prefs" text += "|Enabled in Prefs"
else else
text += "|Disabled in Prefs" text += "|Disabled in Prefs"
@@ -394,7 +394,7 @@
// if (istype(changeling) && changeling.changelingdeath) // if (istype(changeling) && changeling.changelingdeath)
// text += "<br>All the changelings are dead! Restart in [round((changeling.TIME_TO_GET_REVIVED-(world.time-changeling.changelingdeathtime))/10)] seconds." // text += "<br>All the changelings are dead! Restart in [round((changeling.TIME_TO_GET_REVIVED-(world.time-changeling.changelingdeathtime))/10)] seconds."
if(current && current.client && (BE_CHANGELING in current.client.prefs.be_special)) if(current && current.client && (ROLE_CHANGELING in current.client.prefs.be_special))
text += "|Enabled in Prefs" text += "|Enabled in Prefs"
else else
text += "|Disabled in Prefs" text += "|Disabled in Prefs"
@@ -419,7 +419,7 @@
else else
text += "<a href='?src=\ref[src];nuclear=nuclear'>operative</a>|<b>NANOTRASEN</b>" text += "<a href='?src=\ref[src];nuclear=nuclear'>operative</a>|<b>NANOTRASEN</b>"
if(current && current.client && (BE_OPERATIVE in current.client.prefs.be_special)) if(current && current.client && (ROLE_OPERATIVE in current.client.prefs.be_special))
text += "|Enabled in Prefs" text += "|Enabled in Prefs"
else else
text += "|Disabled in Prefs" text += "|Disabled in Prefs"
@@ -438,7 +438,7 @@
else else
text += "<a href='?src=\ref[src];traitor=traitor'>traitor</a>|<b>LOYAL</b>" text += "<a href='?src=\ref[src];traitor=traitor'>traitor</a>|<b>LOYAL</b>"
if(current && current.client && (BE_TRAITOR in current.client.prefs.be_special)) if(current && current.client && (ROLE_TRAITOR in current.client.prefs.be_special))
text += "|Enabled in Prefs" text += "|Enabled in Prefs"
else else
text += "|Disabled in Prefs" text += "|Disabled in Prefs"
@@ -457,7 +457,7 @@
else else
text += "<a href='?src=\ref[src];shadowling=shadowling'>shadowling</a>|<a href='?src=\ref[src];shadowling=thrall'>thrall</a>|<b>HUMAN</b>" text += "<a href='?src=\ref[src];shadowling=shadowling'>shadowling</a>|<a href='?src=\ref[src];shadowling=thrall'>thrall</a>|<b>HUMAN</b>"
if(current && current.client && (BE_SHADOWLING in current.client.prefs.be_special)) if(current && current.client && (ROLE_SHADOWLING in current.client.prefs.be_special))
text += "|Enabled in Prefs" text += "|Enabled in Prefs"
else else
text += "|Disabled in Prefs" text += "|Disabled in Prefs"
@@ -476,7 +476,7 @@
else else
text += "<a href='?src=\ref[src];abductor=abductor'>Abductor</a>|<b>human</b>" text += "<a href='?src=\ref[src];abductor=abductor'>Abductor</a>|<b>human</b>"
if(current && current.client && (BE_ABDUCTOR in current.client.prefs.be_special)) if(current && current.client && (ROLE_ABDUCTOR in current.client.prefs.be_special))
text += "|Enabled in Prefs" text += "|Enabled in Prefs"
else else
text += "|Disabled in Prefs" text += "|Disabled in Prefs"
@@ -499,12 +499,12 @@
else else
text += "<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 follower'>blue follower</a>|<a href='?src=\ref[src];handofgod=blue prophet'>blue prophet</a>" text += "<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 follower'>blue follower</a>|<a href='?src=\ref[src];handofgod=blue prophet'>blue prophet</a>"
if(current && current.client && (BE_HOG_GOD in current.client.prefs.be_special)) if(current && current.client && (ROLE_HOG_GOD in current.client.prefs.be_special))
text += "|HOG God Enabled in Prefs" text += "|HOG God Enabled in Prefs"
else else
text += "|HOG God Disabled in Prefs" text += "|HOG God Disabled in Prefs"
if(current && current.client && (BE_HOG_CULTIST in current.client.prefs.be_special)) if(current && current.client && (ROLE_HOG_CULTIST in current.client.prefs.be_special))
text += "|HOG Cultist Enabled in Prefs" text += "|HOG Cultist Enabled in Prefs"
else else
text += "|HOG Disabled in Prefs" text += "|HOG Disabled in Prefs"
@@ -532,7 +532,7 @@
else else
text += "healthy|infected|human|<b>OTHER</b>" text += "healthy|infected|human|<b>OTHER</b>"
if(current && current.client && (BE_MONKEY in current.client.prefs.be_special)) if(current && current.client && (ROLE_MONKEY in current.client.prefs.be_special))
text += "|Enabled in Prefs" text += "|Enabled in Prefs"
else else
text += "|Disabled in Prefs" text += "|Disabled in Prefs"
@@ -563,7 +563,7 @@
n_e_robots++ n_e_robots++
text += "<br>[n_e_robots] of [ai.connected_robots.len] slaved cyborgs are emagged. <a href='?src=\ref[src];silicon=unemagcyborgs'>Unemag</a>" text += "<br>[n_e_robots] of [ai.connected_robots.len] slaved cyborgs are emagged. <a href='?src=\ref[src];silicon=unemagcyborgs'>Unemag</a>"
if(current && current.client && (BE_MALF in current.client.prefs.be_special)) if(current && current.client && (ROLE_MALF in current.client.prefs.be_special))
text += "|Enabled in Prefs" text += "|Enabled in Prefs"
else else
text += "|Disabled in Prefs" text += "|Disabled in Prefs"
@@ -1536,6 +1536,8 @@
ticker.mode.blue_deity_followers -= src ticker.mode.blue_deity_followers -= src
ticker.mode.blue_deity_prophets -= src ticker.mode.blue_deity_prophets -= src
current.faction |= "red god"
current.faction -= "blue god"
if(src in ticker.mode.red_deity_prophets) 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>" 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>"
@@ -1553,6 +1555,8 @@
ticker.mode.red_deity_followers -= src ticker.mode.red_deity_followers -= src
ticker.mode.red_deity_prophets -= src ticker.mode.red_deity_prophets -= src
current.faction -= "red god"
current.faction |= "blue god"
if(src in ticker.mode.blue_deity_prophets) 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>" 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>"
@@ -1579,6 +1583,8 @@
if(src in ticker.mode.blue_deity_followers || src in ticker.mode.blue_deity_prophets) 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 << "<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_followers -= src
ticker.mode.blue_deity_prophets -= src ticker.mode.blue_deity_prophets -= src
@@ -1594,6 +1600,8 @@
if(src in ticker.mode.red_deity_followers || src in ticker.mode.red_deity_prophets) 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 << "<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_followers -= src
ticker.mode.red_deity_prophets -= src ticker.mode.red_deity_prophets -= src

View File

@@ -6,7 +6,7 @@
/datum/game_mode/abduction /datum/game_mode/abduction
name = "abduction" name = "abduction"
config_tag = "abduction" config_tag = "abduction"
antag_flag = BE_ABDUCTOR antag_flag = ROLE_ABDUCTOR
recommended_enemies = 2 recommended_enemies = 2
required_players = 15 required_players = 15
var/max_teams = 4 var/max_teams = 4

View File

@@ -1,9 +1,9 @@
/datum/atom_hud/antag /datum/atom_hud/antag
hud_icons = list(ANTAG_HUD) hud_icons = list(ANTAG_HUD)
/datum/atom_hud/antag/proc/join_hud(mob/living/M) /datum/atom_hud/antag/proc/join_hud(mob/M)
if(!istype(M)) if(!istype(M))
CRASH("join_hud(): [M] ([M.type]) is not a living mob!") CRASH("join_hud(): [M] ([M.type]) is not a mob!")
if(M.mind.antag_hud) if(M.mind.antag_hud)
var/datum/atom_hud/antag/oldhud = M.mind.antag_hud var/datum/atom_hud/antag/oldhud = M.mind.antag_hud
oldhud.leave_hud(M) oldhud.leave_hud(M)
@@ -11,9 +11,9 @@
add_hud_to(M) add_hud_to(M)
M.mind.antag_hud = src M.mind.antag_hud = src
/datum/atom_hud/antag/proc/leave_hud(mob/living/M) /datum/atom_hud/antag/proc/leave_hud(mob/M)
if(!istype(M)) if(!istype(M))
CRASH("leave_hud(): [M] ([M.type]) is not a living mob!") CRASH("leave_hud(): [M] ([M.type]) is not a mob!")
remove_from_hud(M) remove_from_hud(M)
remove_hud_from(M) remove_hud_from(M)
M.mind.antag_hud = null M.mind.antag_hud = null
@@ -21,17 +21,18 @@
//GAME_MODE PROCS //GAME_MODE PROCS
//called to set a mob's antag icon state //called to set a mob's antag icon state
/datum/game_mode/proc/set_antag_hud(mob/living/M, new_icon_state) /datum/game_mode/proc/set_antag_hud(mob/M, new_icon_state)
if(!istype(M)) if(!istype(M))
CRASH("set_antag_hud(): [M] ([M.type]) is not a living mob!") CRASH("set_antag_hud(): [M] ([M.type]) is not a mob!")
var/image/holder = M.hud_list[ANTAG_HUD] var/image/holder = M.hud_list[ANTAG_HUD]
if(holder)
holder.icon_state = new_icon_state holder.icon_state = new_icon_state
M.mind.antag_hud_icon_state = new_icon_state M.mind.antag_hud_icon_state = new_icon_state
//MIND PROCS //MIND PROCS
//this is called by mind.transfer_to() //this is called by mind.transfer_to()
/datum/mind/proc/transfer_antag_huds(mob/living/M) /datum/mind/proc/transfer_antag_huds(mob/M)
for(var/datum/atom_hud/antag/hud in huds) for(var/datum/atom_hud/antag/hud in huds)
if(M in hud.hudusers) if(M in hud.hudusers)
hud.leave_hud(M) hud.leave_hud(M)

View File

@@ -53,7 +53,7 @@
if (used) if (used)
H << "You already used this contract!" H << "You already used this contract!"
return return
var/list/candidates = get_candidates(BE_WIZARD) var/list/candidates = get_candidates(ROLE_WIZARD)
if(candidates.len) if(candidates.len)
src.used = 1 src.used = 1
var/client/C = pick(candidates) var/client/C = pick(candidates)
@@ -135,7 +135,7 @@
borg_to_spawn = input("What type?", "Cyborg Type", type) as null|anything in possible_types borg_to_spawn = input("What type?", "Cyborg Type", type) as null|anything in possible_types
if(!borg_to_spawn) if(!borg_to_spawn)
return return
var/list/borg_candicates = get_candidates(BE_OPERATIVE) var/list/borg_candicates = get_candidates(ROLE_OPERATIVE)
if(borg_candicates.len > 0) if(borg_candicates.len > 0)
used = 1 used = 1
var/client/C = pick(borg_candicates) var/client/C = pick(borg_candicates)
@@ -171,7 +171,7 @@
/obj/item/weapon/antag_spawner/slaughter_demon/attack_self(mob/user) /obj/item/weapon/antag_spawner/slaughter_demon/attack_self(mob/user)
var/list/demon_candidates = get_candidates(BE_ALIEN) var/list/demon_candidates = get_candidates(ROLE_ALIEN)
if(user.z != 1) if(user.z != 1)
user << "<span class='notice'>You should probably wait until you reach the station.</span>" user << "<span class='notice'>You should probably wait until you reach the station.</span>"
return return

View File

@@ -9,7 +9,7 @@ var/list/blob_nodes = list()
/datum/game_mode/blob /datum/game_mode/blob
name = "blob" name = "blob"
config_tag = "blob" config_tag = "blob"
antag_flag = BE_BLOB antag_flag = ROLE_BLOB
required_players = 30 required_players = 30
required_enemies = 1 required_enemies = 1
@@ -53,7 +53,7 @@ var/list/blob_nodes = list()
/datum/game_mode/blob/proc/get_blob_candidates() /datum/game_mode/blob/proc/get_blob_candidates()
var/list/candidates = list() var/list/candidates = list()
for(var/mob/living/carbon/human/player in player_list) for(var/mob/living/carbon/human/player in player_list)
if(!player.stat && player.mind && !player.mind.special_role && !jobban_isbanned(player, "Syndicate") && (BE_BLOB in player.client.prefs.be_special)) if(!player.stat && player.mind && !player.mind.special_role && !jobban_isbanned(player, "Syndicate") && (ROLE_BLOB in player.client.prefs.be_special))
if(age_check(player.client)) if(age_check(player.client))
candidates += player candidates += player
return candidates return candidates

View File

@@ -98,7 +98,7 @@
var/list/candidates = list() var/list/candidates = list()
if(!new_overmind) if(!new_overmind)
candidates = get_candidates(BE_BLOB) candidates = get_candidates(ROLE_BLOB)
if(candidates.len) if(candidates.len)
C = pick(candidates) C = pick(candidates)
else else

View File

@@ -15,7 +15,7 @@ var/list/slot2type = list("head" = /obj/item/clothing/head/changeling, "wear_mas
/datum/game_mode/changeling /datum/game_mode/changeling
name = "changeling" name = "changeling"
config_tag = "changeling" config_tag = "changeling"
antag_flag = BE_CHANGELING antag_flag = ROLE_CHANGELING
restricted_jobs = list("AI", "Cyborg") restricted_jobs = list("AI", "Cyborg")
protected_jobs = list("Security Officer", "Warden", "Detective", "Head of Security", "Captain") protected_jobs = list("Security Officer", "Warden", "Detective", "Head of Security", "Captain")
required_players = 15 required_players = 15
@@ -105,8 +105,8 @@ var/list/slot2type = list("head" = /obj/item/clothing/head/changeling, "wear_mas
if(ticker.mode.changelings.len >= changelingcap) //Caps number of latejoin antagonists if(ticker.mode.changelings.len >= changelingcap) //Caps number of latejoin antagonists
return return
if(ticker.mode.changelings.len <= (changelingcap - 2) || prob(100 - (config.changeling_scaling_coeff*2))) if(ticker.mode.changelings.len <= (changelingcap - 2) || prob(100 - (config.changeling_scaling_coeff*2)))
if(BE_CHANGELING in character.client.prefs.be_special) if(ROLE_CHANGELING in character.client.prefs.be_special)
if(!jobban_isbanned(character.client, "changeling") && !jobban_isbanned(character.client, "Syndicate")) if(!jobban_isbanned(character.client, ROLE_CHANGELING) && !jobban_isbanned(character.client, "Syndicate"))
if(age_check(character.client)) if(age_check(character.client))
if(!(character.job in restricted_jobs)) if(!(character.job in restricted_jobs))
character.mind.make_Changling() character.mind.make_Changling()

View File

@@ -18,7 +18,7 @@
/datum/game_mode/traitor/changeling/can_start() /datum/game_mode/traitor/changeling/can_start()
if(!..()) if(!..())
return 0 return 0
possible_changelings = get_players_for_role(BE_CHANGELING) possible_changelings = get_players_for_role(ROLE_CHANGELING)
if(possible_changelings.len < required_enemies) if(possible_changelings.len < required_enemies)
return 0 return 0
return 1 return 1
@@ -30,7 +30,7 @@
if(config.protect_assistant_from_antagonist) if(config.protect_assistant_from_antagonist)
restricted_jobs += "Assistant" restricted_jobs += "Assistant"
var/list/datum/mind/possible_changelings = get_players_for_role(BE_CHANGELING) var/list/datum/mind/possible_changelings = get_players_for_role(ROLE_CHANGELING)
var/num_changelings = 1 var/num_changelings = 1
@@ -66,8 +66,8 @@
..() ..()
return return
if(ticker.mode.changelings.len <= (changelingcap - 2) || prob(100 / (config.changeling_scaling_coeff * 4))) if(ticker.mode.changelings.len <= (changelingcap - 2) || prob(100 / (config.changeling_scaling_coeff * 4)))
if(BE_CHANGELING in character.client.prefs.be_special) if(ROLE_CHANGELING in character.client.prefs.be_special)
if(!jobban_isbanned(character.client, "changeling") && !jobban_isbanned(character.client, "Syndicate")) if(!jobban_isbanned(character.client, ROLE_CHANGELING) && !jobban_isbanned(character.client, "Syndicate"))
if(age_check(character.client)) if(age_check(character.client))
if(!(character.job in restricted_jobs)) if(!(character.job in restricted_jobs))
character.mind.make_Changling() character.mind.make_Changling()

View File

@@ -50,7 +50,7 @@
/datum/game_mode/cult /datum/game_mode/cult
name = "cult" name = "cult"
config_tag = "cult" config_tag = "cult"
antag_flag = BE_CULTIST antag_flag = ROLE_CULTIST
restricted_jobs = list("Chaplain","AI", "Cyborg", "Security Officer", "Warden", "Detective", "Head of Security", "Captain", "Head of Personnel") restricted_jobs = list("Chaplain","AI", "Cyborg", "Security Officer", "Warden", "Detective", "Head of Security", "Captain", "Head of Personnel")
protected_jobs = list() protected_jobs = list()
required_players = 20 required_players = 20

View File

@@ -292,21 +292,6 @@
var/list/drafted = list() var/list/drafted = list()
var/datum/mind/applicant = null var/datum/mind/applicant = null
var/roletext
switch(role)
if(BE_CHANGELING) roletext="changeling"
if(BE_TRAITOR) roletext="traitor"
if(BE_OPERATIVE) roletext="operative"
if(BE_WIZARD) roletext="wizard"
if(BE_REV) roletext="revolutionary"
if(BE_GANG) roletext="gangster"
if(BE_CULTIST) roletext="cultist"
if(BE_MONKEY) roletext="monkey"
if(BE_ABDUCTOR) roletext="abductor"
if(BE_HOG_GOD) roletext="hand of god, god"
if(BE_HOG_CULTIST) roletext="hand of god, cultist"
// Ultimate randomizing code right here // Ultimate randomizing code right here
for(var/mob/new_player/player in player_list) for(var/mob/new_player/player in player_list)
if(player.client && player.ready) if(player.client && player.ready)
@@ -319,7 +304,7 @@
for(var/mob/new_player/player in players) for(var/mob/new_player/player in players)
if(player.client && player.ready) if(player.client && player.ready)
if(role in player.client.prefs.be_special) if(role in player.client.prefs.be_special)
if(!jobban_isbanned(player, "Syndicate") && !jobban_isbanned(player, roletext)) //Nodrak/Carn: Antag Job-bans if(!jobban_isbanned(player, "Syndicate") && !jobban_isbanned(player, role)) //Nodrak/Carn: Antag Job-bans
if(age_check(player.client)) //Must be older than the minimum age if(age_check(player.client)) //Must be older than the minimum age
candidates += player.mind // Get a list of all the people who want to be the antagonist for this round candidates += player.mind // Get a list of all the people who want to be the antagonist for this round
@@ -333,7 +318,7 @@
for(var/mob/new_player/player in players) for(var/mob/new_player/player in players)
if(player.client && player.ready) if(player.client && player.ready)
if(!(role in player.client.prefs.be_special)) // We don't have enough people who want to be antagonist, make a seperate list of people who don't want to be one if(!(role in player.client.prefs.be_special)) // We don't have enough people who want to be antagonist, make a seperate list of people who don't want to be one
if(!jobban_isbanned(player, "Syndicate") && !jobban_isbanned(player, roletext)) //Nodrak/Carn: Antag Job-bans if(!jobban_isbanned(player, "Syndicate") && !jobban_isbanned(player, role)) //Nodrak/Carn: Antag Job-bans
drafted += player.mind drafted += player.mind
if(restricted_jobs) if(restricted_jobs)

View File

@@ -12,7 +12,7 @@ var/list/gang_colors_pool = list("red","orange","yellow","green","blue","purple"
/datum/game_mode/gang /datum/game_mode/gang
name = "gang war" name = "gang war"
config_tag = "gang" config_tag = "gang"
antag_flag = BE_GANG antag_flag = ROLE_GANG
restricted_jobs = list("Security Officer", "Warden", "Detective", "AI", "Cyborg","Captain", "Head of Personnel", "Head of Security", "Chief Engineer", "Research Director", "Chief Medical Officer") restricted_jobs = list("Security Officer", "Warden", "Detective", "AI", "Cyborg","Captain", "Head of Personnel", "Head of Security", "Chief Engineer", "Research Director", "Chief Medical Officer")
required_players = 20 required_players = 20
required_enemies = 2 required_enemies = 2

View File

@@ -1,7 +1,6 @@
var/global/list/global_handofgod_traptypes = list() var/global/list/global_handofgod_traptypes = list()
var/global/list/global_handofgod_structuretypes = list() var/global/list/global_handofgod_structuretypes = list()
var/global/list/global_handofgod_itemtypes = list()
/datum/game_mode /datum/game_mode
@@ -21,18 +20,12 @@ var/global/list/global_handofgod_itemtypes = list()
/datum/game_mode/hand_of_god /datum/game_mode/hand_of_god
name = "hand of god" name = "hand of god"
config_tag = "handofgod" config_tag = "handofgod"
antag_flag = BE_HOG_CULTIST //Followers use BE_HOG_CULTIST, Gods are picked later on with BE_HOG_GOD antag_flag = ROLE_HOG_CULTIST //Followers use ROLE_HOG_CULTIST, Gods are picked later on with ROLE_HOG_GOD
required_players = 1 //20-25+
required_enemies = 0 //This MUST be an even number to function properly. This number counts
//all enemy players involved, as in both teams combined. Recommended: 8
//If you want to test something by yourself, set to zero. Note that you will produce one unavoidable
//runtime due to an empty list being pick()'d.
recommended_enemies = 2
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") restricted_jobs = list("Chaplain","AI", "Cyborg", "Security Officer", "Warden", "Detective", "Head of Security", "Captain", "Head of Personnel")
var/finished = 0
/datum/game_mode/hand_of_god/announce() /datum/game_mode/hand_of_god/announce()
@@ -85,25 +78,28 @@ var/global/list/global_handofgod_itemtypes = list()
/datum/game_mode/hand_of_god/post_setup() /datum/game_mode/hand_of_god/post_setup()
//Find viable red god //Find viable red god
var/list/red_god_possibilities = get_players_for_role(BE_HOG_GOD) var/list/red_god_possibilities = get_players_for_role(ROLE_HOG_GOD)
red_god_possibilities &= red_deity_followers //followers only red_god_possibilities &= red_deity_followers //followers only
if(!red_god_possibilities.len) //No candidates? just pick any follower regardless of prefs if(!red_god_possibilities.len) //No candidates? just pick any follower regardless of prefs
red_god_possibilities = red_deity_followers red_god_possibilities = red_deity_followers
//Make red god //Make red god
var/datum/mind/red_god = pick_n_take(red_god_possibilities) var/datum/mind/red_god = pick_n_take(red_god_possibilities)
if(red_god)
red_god.current.become_god("red") red_god.current.become_god("red")
ticker.mode.forge_deity_objectives(red_god) ticker.mode.forge_deity_objectives(red_god)
remove_hog_follower(red_god,0) remove_hog_follower(red_god,0)
add_god(red_god,"red") add_god(red_god,"red")
//Find viable blue god //Find viable blue god
var/list/blue_god_possibilities = get_players_for_role(BE_HOG_GOD) var/list/blue_god_possibilities = get_players_for_role(ROLE_HOG_GOD)
blue_god_possibilities &= blue_deity_followers //followers only blue_god_possibilities &= blue_deity_followers //followers only
if(!blue_god_possibilities.len) //No candidates? just pick any follower regardless of prefs if(!blue_god_possibilities.len) //No candidates? just pick any follower regardless of prefs
blue_god_possibilities = blue_deity_followers blue_god_possibilities = blue_deity_followers
//Make blue god
var/datum/mind/blue_god = pick_n_take(blue_god_possibilities) var/datum/mind/blue_god = pick_n_take(blue_god_possibilities)
if(blue_god)
blue_god.current.become_god("blue") blue_god.current.become_god("blue")
ticker.mode.forge_deity_objectives(blue_god) ticker.mode.forge_deity_objectives(blue_god)
remove_hog_follower(blue_god,0) remove_hog_follower(blue_god,0)
@@ -145,7 +141,7 @@ var/global/list/global_handofgod_itemtypes = list()
deity.objectives += build deity.objectives += build
build.gen_amount_goal(8, 16) build.gen_amount_goal(8, 16)
var/datum/objective/sacrifice_prophet/sacrifice var/datum/objective/sacrifice_prophet/sacrifice = new
sacrifice.owner = deity sacrifice.owner = deity
deity.objectives += sacrifice deity.objectives += sacrifice
@@ -194,6 +190,8 @@ var/global/list/global_handofgod_itemtypes = list()
if(colour == "blue") if(colour == "blue")
blue_deity_followers += follower_mind blue_deity_followers += follower_mind
H.faction |= "[colour] god"
update_hog_icons_added(follower_mind, colour) update_hog_icons_added(follower_mind, colour)
follower_mind.special_role = "Hand of God: [capitalize(colour)] Follower" 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>" follower_mind.current.attack_log += "\[[time_stamp()]\] <font color='red'>Has been converted to the [colour] follower cult!</font>"
@@ -218,6 +216,11 @@ var/global/list/global_handofgod_itemtypes = list()
update_hog_icons_removed(follower_mind,"red") update_hog_icons_removed(follower_mind,"red")
update_hog_icons_removed(follower_mind,"blue") update_hog_icons_removed(follower_mind,"blue")
if(follower_mind.current)
var/mob/living/carbon/human/H = follower_mind.current
H.faction -= "red god"
H.faction -= "blue god"
if(announce) if(announce)
follower_mind.current.attack_log += "\[[time_stamp()]\] <font color='red'>Has been deconverted from a deity's cult!</font>" 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>" 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>"
@@ -296,7 +299,6 @@ var/global/list/global_handofgod_itemtypes = list()
var/mob/living/carbon/human/H = A var/mob/living/carbon/human/H = A
if(!H.mind) if(!H.mind)
return 0 return 0
if(side == "red") if(side == "red")
if(H.mind in ticker.mode.red_deity_prophets) if(H.mind in ticker.mode.red_deity_prophets)
return 1 return 1
@@ -305,12 +307,13 @@ var/global/list/global_handofgod_itemtypes = list()
return 1 return 1
////////////////////// //////////////////////
//Roundend Reporting// //Roundend Reporting//
////////////////////// //////////////////////
/datum/game_mode/proc/declare_completion_handofgod() /datum/game_mode/hand_of_god/declare_completion()
if(red_deities.len) if(red_deities.len)
var/text = "<BR><font size=3 color='red'><B>The red cult:</b></font>" var/text = "<BR><font size=3 color='red'><B>The red cult:</b></font>"
for(var/datum/mind/red_god in red_deities) for(var/datum/mind/red_god in red_deities)
@@ -422,15 +425,15 @@ var/global/list/global_handofgod_itemtypes = list()
var/rank = 0 var/rank = 0
if(side == "red") if(side == "red")
hud_key = ANTAG_HUD_HOG_RED hud_key = ANTAG_HUD_HOG_RED
if(is_handofgod_redprophet(hog_mind)) if(is_handofgod_redprophet(hog_mind.current))
rank = 1 rank = 1
else if(side == "blue") else if(side == "blue")
hud_key = ANTAG_HUD_HOG_BLUE hud_key = ANTAG_HUD_HOG_BLUE
if(is_handofgod_blueprophet(hog_mind)) if(is_handofgod_blueprophet(hog_mind.current))
rank = 1 rank = 1
if(is_handofgod_god(hog_mind)) if(is_handofgod_god(hog_mind.current))
rank = 2 rank = 2
if(hud_key) if(hud_key)

View File

@@ -8,25 +8,31 @@
see_in_dark = 0 see_in_dark = 0
sight = SEE_TURFS | SEE_MOBS | SEE_OBJS | SEE_SELF sight = SEE_TURFS | SEE_MOBS | SEE_OBJS | SEE_SELF
languages = HUMAN | MONKEY | ALIEN | ROBOT | SLIME | DRONE | SWARMER languages = HUMAN | MONKEY | ALIEN | ROBOT | SLIME | DRONE | SWARMER
hud_possible = list(ANTAG_HUD)
var/faith = 0 var/faith = 100 //For initial prophet appointing/stupid purchase
var/max_faith = 100 var/max_faith = 100
var/side = "neutral" //Red or Blue for the gamemode 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/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/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/followers_required = 0 //Same as above
var/alive_followers = 0 var/alive_followers = 0
var/mob/living/carbon/human/prophet = null //The prophet of this god
var/list/structures = list() var/list/structures = list()
var/prophets_sacrificed_in_name = 0 var/prophets_sacrificed_in_name = 0
/mob/camera/god/New(loc, newName, side = "neutral") /mob/camera/god/New()
..() ..()
real_name = newName
name = real_name
side = side
update_icons() update_icons()
build_hog_construction_lists()
//Force nexuses after 2 minutes in hand of god mode
if(ticker && ticker.mode && ticker.mode.name == "hand of god")
spawn(1200)
if(src)
if(!god_nexus)
place_nexus()
src << "<span class='danger'>You failed to place your nexus, and it has been placed for you!</span>"
/mob/camera/god/update_icons() /mob/camera/god/update_icons()
@@ -47,10 +53,10 @@
sync_mind() sync_mind()
src << "<span class='notice'>You are a deity!</span>" 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 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 for you randomly." 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. If this drops to zero, you will die." 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 die as well, but your powers are amplified when near it." src << "Your <b>Nexus Integrity</b> tells you the condition of your nexus. If your nexus is destroyed, you will die."
src << "Your <b>Faith</b> is used to interact with the world. This will regenerate on it's own, and it goes faster when you have more followers." src << "Your <b>Faith</b> is used to interact with the world. This will regenerate on it's 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." 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() update_health_hud()
@@ -62,11 +68,26 @@
/mob/camera/god/proc/add_faith(faith_amt) /mob/camera/god/proc/add_faith(faith_amt)
if(faith_amt) if(faith_amt)
faith = Clamp(faith+faith_amt, 0, max_faith) faith = round(Clamp(faith+faith_amt, 0, max_faith))
if(hud_used && hud_used.deity_power_display) 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>" 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)
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()
/mob/camera/god/proc/update_followers() /mob/camera/god/proc/update_followers()
alive_followers = 0 alive_followers = 0
var/list/all_followers var/list/all_followers

View File

@@ -6,6 +6,33 @@
icon_state = "banner" icon_state = "banner"
item_state = "banner" item_state = "banner"
desc = "A banner with Nanotrasen's logo on it." desc = "A banner with Nanotrasen's logo on it."
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)
/obj/item/weapon/banner/red /obj/item/weapon/banner/red
name = "red banner" name = "red banner"
@@ -16,15 +43,15 @@
/obj/item/weapon/banner/red/examine() /obj/item/weapon/banner/red/examine()
..() ..()
if(is_handofgod_redcultist(usr)) if(is_handofgod_redcultist(usr))
usr << "A banner representing our might against the heretics." usr << "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(usr)) else if(is_handofgod_bluecultist(usr))
usr << "A heretical banner that should be destroyed posthaste." usr << "A heretical banner that should be destroyed posthaste."
/obj/item/weapon/banner/blue /obj/item/weapon/banner/blue
name = "red banner" name = "blue banner"
icon_state = "banner-red" icon_state = "banner-blue"
item_state = "banner-red" item_state = "banner-blue"
desc = "A banner with the logo of the blue deity" desc = "A banner with the logo of the blue deity"
/obj/item/weapon/banner/blue/examine() /obj/item/weapon/banner/blue/examine()
@@ -33,7 +60,7 @@
if(is_handofgod_redcultist(usr)) if(is_handofgod_redcultist(usr))
usr << "A heretical banner that should be destroyed posthaste." usr << "A heretical banner that should be destroyed posthaste."
else if(is_handofgod_bluecultist(usr)) else if(is_handofgod_bluecultist(usr))
usr << "A banner representing our might against the heretics." usr << "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 /obj/item/weapon/storage/backpack/bannerpack
@@ -58,7 +85,7 @@
//this is all part of one item set //this is all part of one item set
/obj/item/clothing/suit/armor/plate/crusader /obj/item/clothing/suit/armor/plate/crusader
name = "Crusader's Armor" name = "Crusader's Armour"
icon_state = "crusader" icon_state = "crusader"
w_class = 4 //bulky w_class = 4 //bulky
slowdown = 2.0 //gotta pretend we're balanced. slowdown = 2.0 //gotta pretend we're balanced.
@@ -73,9 +100,9 @@
/obj/item/clothing/suit/armor/plate/crusader/examine(mob/user) /obj/item/clothing/suit/armor/plate/crusader/examine(mob/user)
..() ..()
if(!is_handofgod_cultist(user)) if(!is_handofgod_cultist(user))
usr << "Armor that's comprised of metal and cloth." usr << "Armour that's comprised of metal and cloth."
else else
usr << "Armor that was used to protect from backstabs, gunshots, explosives, and lasers. The original wearers of this type of armor were trying to avoid being murdered. Since they're not around anymore, you're not sure if they were successful or not." usr << "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 /obj/item/clothing/head/helmet/plate/crusader
@@ -154,8 +181,8 @@
/obj/item/weapon/storage/box/itemset/crusader /obj/item/weapon/storage/box/itemset/crusader
name = "Crusader's Armor Set" //i can't into ck2 references name = "Crusader's Armour Set" //i can't into ck2 references
desc = "This armor 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." 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."
/obj/item/weapon/storage/box/itemset/crusader/blue/New() /obj/item/weapon/storage/box/itemset/crusader/blue/New()

View File

@@ -29,9 +29,10 @@
martyr_compatible = 1 martyr_compatible = 1
/datum/objective/deicide/check_completion() /datum/objective/deicide/check_completion()
if(target && target.current && target.current.stat == DEAD) if(target)
return 1 if(target.current) //Gods are deleted when they lose
return 0 return 0
return 1
/datum/objective/deicide/find_target() /datum/objective/deicide/find_target()

View File

@@ -1,17 +1,42 @@
/mob/camera/god/proc/ability_cost(cost = 0,structures = 0, requires_conduit = 0) /mob/camera/god/proc/ability_cost(cost = 0,structures = 0, requires_conduit = 0)
if(cost && faith < cost) if(faith < cost)
src << "<span class='danger'>You lack the faith!</span>"
return 0 return 0
if(structures && !(isturf(loc) || istype(loc, /turf/space)))
if(structures)
if(!isturf(loc) || istype(loc, /turf/space))
src << "<span class='danger'>Your structure would just float away, you need stable ground!</span>" src << "<span class='danger'>Your structure would just float away, you need stable ground!</span>"
return 0 return 0
if(structures && (locate(/obj/structure) in get_turf(src)))
src << "<span class='danger'>There is another structure here, Select an empty spot.</span>" 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) if(requires_conduit)
//Organised this way as there can be multiple conduits, so it's more likely to be a conduit check. //Organised this way as there can be multiple conduits, so it's more likely to be a conduit check.
if(!locate(/obj/structure/divine/conduit) in range(src,15)) var/valid = 0
if(!locate(/obj/structure/divine/nexus) in range(src, 15)) for(var/obj/structure/divine/conduit/C in range(src,15))
if(C.side == side)
valid++
break
if(!valid)
for(var/obj/structure/divine/nexus/N in range(src,15))
if(N.side == side)
valid++
break
if(!valid)
src << "<span class='danger'>You must be near your Nexus or a Conduit to do this!</span>"
return 0 return 0
return 1 return 1
@@ -34,9 +59,9 @@
set desc = "Teleports you to one of your followers." set desc = "Teleports you to one of your followers."
var/list/following = list() var/list/following = list()
if(side == "red") if(side == "red")
following = ticker.mode.red_deity_followers following = ticker.mode.red_deity_followers|ticker.mode.red_deity_prophets
else if(side == "blue") else if(side == "blue")
following = ticker.mode.blue_deity_followers following = ticker.mode.blue_deity_followers|ticker.mode.blue_deity_prophets
else else
src << "You are unaligned, and thus do not have followers" src << "You are unaligned, and thus do not have followers"
return return
@@ -54,16 +79,19 @@
var/list/following = list() var/list/following = list()
if(!ability_cost(100)) if(!ability_cost(100))
src << "You lack the faith to make a prophet."
return return
if(side == "red") if(side == "red")
if(ticker.mode.red_deity_prophets.len) 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." src << "You can only have one prophet alive at a time."
return
else else
following = ticker.mode.red_deity_followers following = ticker.mode.red_deity_followers
else if(side == "blue") else if(side == "blue")
if(ticker.mode.blue_deity_prophets.len) 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." src << "You can only have one prophet alive at a time."
return
else else
following = ticker.mode.blue_deity_followers following = ticker.mode.blue_deity_followers
@@ -83,7 +111,6 @@
set name = "Talk to Anyone (20)" set name = "Talk to Anyone (20)"
set desc = "Allows you to send a message to anyone, regardless of their faith." set desc = "Allows you to send a message to anyone, regardless of their faith."
if(!ability_cost(20)) if(!ability_cost(20))
src << "You lack the faith to convene with others."
return return
var/mob/choice = input("Choose who you wish to talk to", "Talk to ANYONE") as null|anything in mob_list var/mob/choice = input("Choose who you wish to talk to", "Talk to ANYONE") as null|anything in mob_list
if(choice) if(choice)
@@ -100,7 +127,6 @@
set desc = "Hits anything under you with a moderate amount of damage." set desc = "Hits anything under you with a moderate amount of damage."
if(!ability_cost(40,0,1)) if(!ability_cost(40,0,1))
src << "You lack the faith to smite others."
return return
if(!range(7,god_nexus)) if(!range(7,god_nexus))
src << "You lack the strength to smite this far from your nexus." src << "You lack the strength to smite this far from your nexus."
@@ -120,7 +146,6 @@
set desc = "Knocks out the mortal below you for a brief amount of time." set desc = "Knocks out the mortal below you for a brief amount of time."
if(!ability_cost(20,0,1)) if(!ability_cost(20,0,1))
src << "You lack the faith to lull mortals to sleep."
return return
for(var/mob/living/L in get_turf(src)) for(var/mob/living/L in get_turf(src))
@@ -136,7 +161,6 @@
set desc = "Tug at the fibres of reality itself and bend it to your whims!" set desc = "Tug at the fibres of reality itself and bend it to your whims!"
if(!ability_cost(300,0,1)) if(!ability_cost(300,0,1))
src << "You lack the faith to bend reality."
return return
var/event = pick(/datum/round_event/meteor_wave, /datum/round_event/communications_blackout, /datum/round_event/radiation_storm, /datum/round_event/carp_migration, var/event = pick(/datum/round_event/meteor_wave, /datum/round_event/communications_blackout, /datum/round_event/radiation_storm, /datum/round_event/carp_migration,
@@ -151,15 +175,10 @@
set name = "Construct Nexus" set name = "Construct Nexus"
set desc = "Instantly creates your nexus, You can only do this once, make sure you're happy with it!" 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)) if(!ability_cost(0,1,0) || z != 1)
var/obj/structure/divine/nexus/N = new(get_turf(src)) return
N.deity = src
N.side = side place_nexus()
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()
/* //Transolocators have no sprite /* //Transolocators have no sprite
@@ -195,15 +214,17 @@
set name = "Construct Structure (75)" set name = "Construct Structure (75)"
set desc = "Create the foundation of a divine object." set desc = "Create the foundation of a divine object."
if(ability_cost(75,1,1)) if(!ability_cost(75,1,1))
return
var/construct = input("Choose what you wish to create.", "Divine Construction") as null|anything in global_handofgod_structuretypes var/construct = input("Choose what you wish to create.", "Divine Construction") as null|anything in global_handofgod_structuretypes
if(!construct || !global_handofgod_structuretypes[construct] || !ability_cost(75,1,1)) //check again, they might try to cheat the input window. if(!construct || !global_handofgod_structuretypes[construct] || !ability_cost(75,1,1)) //check again, they might try to cheat the input window.
return return
var/obj/structure/divine/construct_type = global_handofgod_structuretypes[construct] //it's a path but we need to initial() some vars var/obj/structure/divine/construct_type = global_handofgod_structuretypes[construct] //it's a path but we need to initial() some vars
if(!construct_type) if(!construct_type)
return return
src << "You lay the foundations for \a [construct], your followers must finish the construction using metal and glass."
add_faith(-75) add_faith(-75)
var/obj/structure/divine/construction_holder/CH = new(get_turf(src)) var/obj/structure/divine/construction_holder/CH = new(get_turf(src))
@@ -217,7 +238,9 @@
set name = "Construct Trap (20)" set name = "Construct Trap (20)"
set desc = "Creates a ward or trap." set desc = "Creates a ward or trap."
if(ability_cost(20,1,1)) if(!ability_cost(20,1,1))
return
var/trap = input("Choose what you wish to create.", "Divine Traps") as null|anything in global_handofgod_traptypes var/trap = input("Choose what you wish to create.", "Divine Traps") as null|anything in global_handofgod_traptypes
if(!trap || !global_handofgod_traptypes[trap] || !ability_cost(20,1,1)) if(!trap || !global_handofgod_traptypes[trap] || !ability_cost(20,1,1))
return return
@@ -236,8 +259,10 @@
set name = "Construct Items (20)" set name = "Construct Items (20)"
set desc = "Construct some items for your followers" set desc = "Construct some items for your followers"
if(ability_cost(20,1,1)) if(!ability_cost(20,1,1))
var/list/item_types = list() return
var/list/item_types = list("claymore sword" = /obj/item/weapon/claymore)
if(side == "red") if(side == "red")
item_types["red banner"] = /obj/item/weapon/banner/red item_types["red banner"] = /obj/item/weapon/banner/red
item_types["red bannerbackpack"] = /obj/item/weapon/storage/backpack/bannerpack/red item_types["red bannerbackpack"] = /obj/item/weapon/storage/backpack/bannerpack/red
@@ -250,11 +275,11 @@
var/item = input("Choose what you wish to create.", "Divine Items") as null|anything in item_types var/item = input("Choose what you wish to create.", "Divine Items") as null|anything in item_types
if(!item || !global_handofgod_itemtypes[item] || !ability_cost(20,1,1)) if(!item || !item_types[item] || !ability_cost(20,1,1))
return return
src << "You produce \a [item]" src << "You produce \a [item]"
add_faith(-20) add_faith(-20)
var/itemtype = global_handofgod_itemtypes[item] var/itemtype = item_types[item]
new itemtype (get_turf(src)) new itemtype (get_turf(src))

View File

@@ -1,10 +1,24 @@
/proc/build_hog_construction_lists()
if(global_handofgod_traptypes.len && global_handofgod_structuretypes.len)
return
var/list/types = typesof(/obj/structure/divine) - /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 /obj/structure/divine
name = "divine construction site" name = "divine construction site"
icon = 'icons/obj/hand_of_god_structures.dmi' icon = 'icons/obj/hand_of_god_structures.dmi'
desc = "An unfinished divine building" desc = "An unfinished divine building"
anchored = 1 anchored = 1
density = 1 density = 1
var/constructable = TRUE
var/trap = FALSE var/trap = FALSE
var/metal_cost = 0 var/metal_cost = 0
var/glass_cost = 0 var/glass_cost = 0
@@ -18,12 +32,6 @@
/obj/structure/divine/New() /obj/structure/divine/New()
..() ..()
if(!trap)
if(!global_handofgod_structuretypes[name])
global_handofgod_structuretypes[name] = type
else
if(!global_handofgod_traptypes[name])
global_handofgod_traptypes[name] = type
/obj/structure/divine/proc/update_icons() /obj/structure/divine/proc/update_icons()
@@ -48,7 +56,7 @@
return 0 return 0
playsound(get_turf(src), I.hitsound, 50, 1) playsound(get_turf(src), I.hitsound, 50, 1)
visible_message("<span class='danger'>\The [src] has been attack with \the [I][(user ? " by [user]/" : ".")]!</span>") visible_message("<span class='danger'>\The [src] has been attack with \the [I][(user ? " by [user]" : ".")]!</span>")
health = max(0, health-I.force) health = max(0, health-I.force)
healthcheck() healthcheck()
@@ -77,20 +85,29 @@
/obj/structure/divine/proc/assign_deity(mob/camera/god/new_deity, alert_old_deity = TRUE) /obj/structure/divine/proc/assign_deity(mob/camera/god/new_deity, alert_old_deity = TRUE)
if(!new_deity) if(!new_deity)
return 0 return 0
if(deity && alert_old_deity) if(deity)
if(alert_old_deity)
deity << "<span class='danger'><B>Your [name] was captured by [new_deity]'s cult!</B></span>" deity << "<span class='danger'><B>Your [name] was captured by [new_deity]'s cult!</B></span>"
deity.structures -= src deity.structures -= src
deity = new_deity deity = new_deity
deity.structures |= src deity.structures |= src
side = deity.side side = deity.side
update_icons() update_icons()
return 1
/obj/structure/divine/construction_holder /obj/structure/divine/construction_holder
alpha = 125 alpha = 125
constructable = FALSE
var/obj/structure/divine/construction_result = /obj/structure/divine //a path, but typed to /obj/structure/divine for initial() 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/proc/setup_construction(construct_type) /obj/structure/divine/construction_holder/proc/setup_construction(construct_type)
if(ispath(construct_type)) if(ispath(construct_type))
construction_result = construct_type construction_result = construct_type
@@ -161,7 +178,8 @@
/obj/structure/divine/construction_holder/proc/check_completion() /obj/structure/divine/construction_holder/proc/check_completion()
if(!metal_cost && !glass_cost && !lesser_gem_cost && !greater_gem_cost) if(!metal_cost && !glass_cost && !lesser_gem_cost && !greater_gem_cost)
visible_message("<span class='notice'>\The [initial(construction_result.name)] is complete!</span>") visible_message("<span class='notice'>\The [initial(construction_result.name)] is complete!</span>")
new construction_result (get_turf(src)) var/obj/structure/divine/D = new construction_result (get_turf(src))
D.assign_deity(deity)
qdel(src) qdel(src)
@@ -169,7 +187,7 @@
..() ..()
if(metal_cost || glass_cost || lesser_gem_cost || greater_gem_cost) if(metal_cost || glass_cost || lesser_gem_cost || greater_gem_cost)
user << "To finish construction it requires the following materials: <BR>" user << "To finish construction it requires the following materials:"
if(metal_cost) if(metal_cost)
user << "[metal_cost] metal <IMG CLASS=icon SRC=icons/obj/items.dmi ICONSTATE='sheet-metal'>" user << "[metal_cost] metal <IMG CLASS=icon SRC=icons/obj/items.dmi ICONSTATE='sheet-metal'>"
if(glass_cost) if(glass_cost)
@@ -186,6 +204,7 @@
icon_state = "nexus" icon_state = "nexus"
health = 500 health = 500
maxhealth = 500 maxhealth = 500
constructable = FALSE
var/faith_regen_rate = 1 var/faith_regen_rate = 1
var/list/powerpylons = list() var/list/powerpylons = list()
@@ -199,7 +218,7 @@
deity.update_health_hud() deity.update_health_hud()
if(!health) if(!health)
if(deity && deity.nexus_required) if(!qdeleted(deity) && deity.nexus_required)
deity << "<span class='danger'>Your nexus was destroyed. You feel yourself fading...</span>" deity << "<span class='danger'>Your nexus was destroyed. You feel yourself fading...</span>"
qdel(deity) qdel(deity)
visible_message("<span class='danger'>\The [src] was destroyed!</span>") visible_message("<span class='danger'>\The [src] was destroyed!</span>")
@@ -214,6 +233,7 @@
if(deity) if(deity)
deity.update_followers() deity.update_followers()
deity.add_faith(faith_regen_rate + (powerpylons.len / 5) + (deity.alive_followers / 3)) 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
/obj/structure/divine/nexus/Destroy() /obj/structure/divine/nexus/Destroy()
@@ -231,6 +251,7 @@
glass_cost = 10 glass_cost = 10
/* //No good sprites, and not enough items to make it viable yet
/obj/structure/divine/forge /obj/structure/divine/forge
name = "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." desc = "A forge fueled by divine might, it allows the creation of sacred and powerful artifacts. It requires common materials to craft objects."
@@ -240,7 +261,7 @@
density = 0 density = 0
maxhealth = 250 maxhealth = 250
metal_cost = 40 metal_cost = 40
*/
/obj/structure/divine/convertaltar /obj/structure/divine/convertaltar
name = "conversion taltar" name = "conversion taltar"
@@ -248,9 +269,11 @@
icon_state = "convertaltar" icon_state = "convertaltar"
density = 0 density = 0
metal_cost = 20 metal_cost = 20
can_buckle = 1
/obj/structure/divine/convertaltar/attack_hand(mob/living/user) /obj/structure/divine/convertaltar/attack_hand(mob/living/user)
..()
var/mob/living/carbon/human/H = locate() in get_turf(src) var/mob/living/carbon/human/H = locate() in get_turf(src)
if(!is_handofgod_cultist(user)) if(!is_handofgod_cultist(user))
user << "<span class='notice'>You try to use it, but unfortunately you don't know any rituals.</span>" user << "<span class='notice'>You try to use it, but unfortunately you don't know any rituals.</span>"
@@ -274,9 +297,11 @@
icon_state = "sacrificealtar" icon_state = "sacrificealtar"
density = 0 density = 0
metal_cost = 30 metal_cost = 30
can_buckle = 1
/obj/structure/divine/sacrificealtar/attack_hand(mob/living/user) /obj/structure/divine/sacrificealtar/attack_hand(mob/living/user)
..()
var/mob/living/L = locate() in get_turf(src) var/mob/living/L = locate() in get_turf(src)
if(!is_handofgod_cultist(user)) if(!is_handofgod_cultist(user))
user << "<span class='notice'>You try to use it, but unfortunately you don't know any rituals.</span>" user << "<span class='notice'>You try to use it, but unfortunately you don't know any rituals.</span>"
@@ -329,7 +354,7 @@
/obj/structure/divine/healingfountain /obj/structure/divine/healingfountain
name = "healing fountain" name = "healing fountain"
desc = "A fountain containing the waters of life... or death, depending on where your allegiances lie" desc = "A fountain containing the waters of life... or death, depending on where your allegiances lie"
icon_state = "puddle" icon_state = "fountain"
metal_cost = 15 metal_cost = 15
glass_cost = 10 glass_cost = 10
autocolours = FALSE autocolours = FALSE
@@ -349,13 +374,16 @@
user << "<span class='notice'>The water feels warm ans soothing as you touch it. The fountain immediately dries up shortly afterwards.</span>" user << "<span class='notice'>The water feels warm ans soothing as you touch it. The fountain immediately dries up shortly afterwards.</span>"
user.reagents.add_reagent("doctorsdelight",20) user.reagents.add_reagent("doctorsdelight",20)
update_icons() update_icons()
spawn(time_between_uses)
if(src)
update_icons()
/obj/structure/divine/healingfountain/update_icons() /obj/structure/divine/healingfountain/update_icons()
if(last_process + time_between_uses > world.time) if(last_process + time_between_uses > world.time)
icon_state = "fountain-dry" icon_state = "fountain-dry"
else else
icon_state = "fountain" icon_state = "fountain-[side]"
/obj/structure/divine/powerpylon /obj/structure/divine/powerpylon
@@ -405,7 +433,7 @@
/obj/structure/divine/defensepylon/assign_deity(mob/camera/god/new_deity, alert_old_deity = TRUE) /obj/structure/divine/defensepylon/assign_deity(mob/camera/god/new_deity, alert_old_deity = TRUE)
if(..() && pylon_gun) if(..() && pylon_gun)
pylon_gun.faction = side pylon_gun.faction = "[side] god"
pylon_gun.side = side pylon_gun.side = side

View File

@@ -22,9 +22,7 @@
last_trigger = world.time last_trigger = world.time
alpha = 200 alpha = 200
trap_effect(L) trap_effect(L)
spawn(time_between_triggers) animate(src, alpha = 30, time = time_between_triggers)
if(src)
alpha = 30
/obj/structure/divine/trap/examine(mob/user) /obj/structure/divine/trap/examine(mob/user)
@@ -33,9 +31,7 @@
return return
user << "You reveal a trap!" user << "You reveal a trap!"
alpha = 200 alpha = 200
spawn(time_between_triggers) animate(src, alpha = 30, time = time_between_triggers)
if(src)
alpha = 30
/obj/structure/divine/trap/proc/trap_effect(mob/living/L) /obj/structure/divine/trap/proc/trap_effect(mob/living/L)
@@ -99,7 +95,7 @@
/obj/structure/divine/trap/ward /obj/structure/divine/trap/ward
name = "Divine Ward" name = "divine ward"
desc = "A divine barrier, It looks like you could destroy it with enough effort, or wait for it to dissipate..." desc = "A divine barrier, It looks like you could destroy it with enough effort, or wait for it to dissipate..."
icon_state = "ward" icon_state = "ward"
health = 150 health = 150

View File

@@ -4,7 +4,7 @@
/datum/game_mode/malfunction /datum/game_mode/malfunction
name = "AI malfunction" name = "AI malfunction"
config_tag = "malfunction" config_tag = "malfunction"
antag_flag = BE_MALF antag_flag = ROLE_MALF
required_players = 25 required_players = 25
required_enemies = 1 required_enemies = 1
recommended_enemies = 1 recommended_enemies = 1
@@ -29,11 +29,11 @@
required_players = max(required_enemies+1, required_players) //to prevent issues if players are set too low required_players = max(required_enemies+1, required_players) //to prevent issues if players are set too low
return ..() return ..()
/datum/game_mode/malfunction/get_players_for_role(role = BE_MALF) /datum/game_mode/malfunction/get_players_for_role(role = ROLE_MALF)
var/datum/job/ai/DummyAIjob = new var/datum/job/ai/DummyAIjob = new
for(var/mob/new_player/player in player_list) for(var/mob/new_player/player in player_list)
if(player.client && player.ready) if(player.client && player.ready)
if(BE_MALF in player.client.prefs.be_special) if(ROLE_MALF in player.client.prefs.be_special)
if(!jobban_isbanned(player, "Syndicate") && !jobban_isbanned(player, "AI") && DummyAIjob.player_old_enough(player.client)) if(!jobban_isbanned(player, "Syndicate") && !jobban_isbanned(player, "AI") && DummyAIjob.player_old_enough(player.client))
antag_candidates += player.mind antag_candidates += player.mind
antag_candidates = shuffle(antag_candidates) antag_candidates = shuffle(antag_candidates)

View File

@@ -4,7 +4,7 @@
/datum/game_mode/monkey /datum/game_mode/monkey
name = "monkey" name = "monkey"
config_tag = "monkey" config_tag = "monkey"
antag_flag = BE_MONKEY antag_flag = ROLE_MONKEY
required_players = 20 required_players = 20
required_enemies = 1 required_enemies = 1

View File

@@ -8,7 +8,7 @@
required_players = 20 // 20 players - 5 players to be the nuke ops = 15 players remaining required_players = 20 // 20 players - 5 players to be the nuke ops = 15 players remaining
required_enemies = 5 required_enemies = 5
recommended_enemies = 5 recommended_enemies = 5
antag_flag = BE_OPERATIVE antag_flag = ROLE_OPERATIVE
enemy_minimum_age = 14 enemy_minimum_age = 14
var/const/agents_possible = 5 //If we ever need more syndicate agents. var/const/agents_possible = 5 //If we ever need more syndicate agents.

View File

@@ -13,7 +13,7 @@
/datum/game_mode/revolution /datum/game_mode/revolution
name = "revolution" name = "revolution"
config_tag = "revolution" config_tag = "revolution"
antag_flag = BE_REV antag_flag = ROLE_REV
restricted_jobs = list("Security Officer", "Warden", "Detective", "AI", "Cyborg","Captain", "Head of Personnel", "Head of Security", "Chief Engineer", "Research Director", "Chief Medical Officer") restricted_jobs = list("Security Officer", "Warden", "Detective", "AI", "Cyborg","Captain", "Head of Personnel", "Head of Security", "Chief Engineer", "Research Director", "Chief Medical Officer")
required_players = 20 required_players = 20
required_enemies = 1 required_enemies = 1
@@ -187,7 +187,7 @@
var/list/promotable_revs = list() var/list/promotable_revs = list()
for(var/datum/mind/khrushchev in revolutionaries) for(var/datum/mind/khrushchev in revolutionaries)
if(khrushchev.current && khrushchev.current.client && khrushchev.current.stat != DEAD) if(khrushchev.current && khrushchev.current.client && khrushchev.current.stat != DEAD)
if(BE_REV in khrushchev.current.client.prefs.be_special) if(ROLE_REV in khrushchev.current.client.prefs.be_special)
promotable_revs += khrushchev promotable_revs += khrushchev
if(promotable_revs) if(promotable_revs)
var/datum/mind/stalin = pick(promotable_revs) var/datum/mind/stalin = pick(promotable_revs)

View File

@@ -67,7 +67,7 @@ Made by Xhuis
/datum/game_mode/shadowling /datum/game_mode/shadowling
name = "shadowling" name = "shadowling"
config_tag = "shadowling" config_tag = "shadowling"
antag_flag = BE_SHADOWLING antag_flag = ROLE_SHADOWLING
required_players = 30 required_players = 30
required_enemies = 2 required_enemies = 2
recommended_enemies = 2 recommended_enemies = 2

View File

@@ -9,7 +9,7 @@
/datum/game_mode/traitor /datum/game_mode/traitor
name = "traitor" name = "traitor"
config_tag = "traitor" config_tag = "traitor"
antag_flag = BE_TRAITOR antag_flag = ROLE_TRAITOR
restricted_jobs = list("Cyborg")//They are part of the AI if he is traitor so are they, they use to get double chances restricted_jobs = list("Cyborg")//They are part of the AI if he is traitor so are they, they use to get double chances
protected_jobs = list("Security Officer", "Warden", "Detective", "Head of Security", "Captain")//AI", Currently out of the list as malf does not work for shit protected_jobs = list("Security Officer", "Warden", "Detective", "Head of Security", "Captain")//AI", Currently out of the list as malf does not work for shit
required_players = 0 required_players = 0
@@ -74,8 +74,8 @@
if(ticker.mode.traitors.len >= traitorcap) //Upper cap for number of latejoin antagonists if(ticker.mode.traitors.len >= traitorcap) //Upper cap for number of latejoin antagonists
return return
if(ticker.mode.traitors.len <= (traitorcap - 2) || prob(100 / (config.traitor_scaling_coeff * 2))) if(ticker.mode.traitors.len <= (traitorcap - 2) || prob(100 / (config.traitor_scaling_coeff * 2)))
if(BE_TRAITOR in character.client.prefs.be_special) if(ROLE_TRAITOR in character.client.prefs.be_special)
if(!jobban_isbanned(character.client, "traitor") && !jobban_isbanned(character.client, "Syndicate")) if(!jobban_isbanned(character.client, ROLE_TRAITOR) && !jobban_isbanned(character.client, "Syndicate"))
if(age_check(character.client)) if(age_check(character.client))
if(!(character.job in restricted_jobs)) if(!(character.job in restricted_jobs))
add_latejoin_traitor(character.mind) add_latejoin_traitor(character.mind)

View File

@@ -243,7 +243,7 @@ var/global/list/multiverse = list()
usr.mind.special_role = "[usr.real_name] Prime" usr.mind.special_role = "[usr.real_name] Prime"
evil = FALSE evil = FALSE
else else
var/list/candidates = get_candidates(BE_WIZARD) var/list/candidates = get_candidates(ROLE_WIZARD)
if(candidates.len) if(candidates.len)
var/client/C = pick(candidates) var/client/C = pick(candidates)
spawn_copy(C, get_turf(user.loc), user) spawn_copy(C, get_turf(user.loc), user)

View File

@@ -78,8 +78,8 @@
spawn(rand(500, 700)) spawn(rand(500, 700))
message_admins("SWF is still pissed, sending another wizard - [max_mages - mages_made] left.") message_admins("SWF is still pissed, sending another wizard - [max_mages - mages_made] left.")
for(var/mob/dead/observer/G in player_list) for(var/mob/dead/observer/G in player_list)
if(G.client && !G.client.holder && !G.client.is_afk() && (BE_WIZARD in G.client.prefs.be_special)) if(G.client && !G.client.holder && !G.client.is_afk() && (ROLE_WIZARD in G.client.prefs.be_special))
if(!jobban_isbanned(G, "wizard") && !jobban_isbanned(G, "Syndicate")) if(!jobban_isbanned(G, ROLE_WIZARD) && !jobban_isbanned(G, "Syndicate"))
if(age_check(G.client)) if(age_check(G.client))
candidates += G candidates += G
if(!candidates.len) if(!candidates.len)

View File

@@ -243,7 +243,7 @@
/obj/item/device/soulstone/proc/getCultGhost(obj/item/device/soulstone/C, mob/living/carbon/human/T, mob/U) /obj/item/device/soulstone/proc/getCultGhost(obj/item/device/soulstone/C, mob/living/carbon/human/T, mob/U)
var/list/candidates = get_candidates(BE_CULTIST) var/list/candidates = get_candidates(ROLE_CULTIST)
shuffle(candidates) shuffle(candidates)

View File

@@ -4,7 +4,7 @@
/datum/game_mode/wizard /datum/game_mode/wizard
name = "wizard" name = "wizard"
config_tag = "wizard" config_tag = "wizard"
antag_flag = BE_WIZARD antag_flag = ROLE_WIZARD
required_players = 20 required_players = 20
required_enemies = 1 required_enemies = 1
recommended_enemies = 1 recommended_enemies = 1

View File

@@ -170,6 +170,6 @@
/datum/outfit/job/proc/announce_head(var/mob/living/carbon/human/H, var/channels) //tells the given channel that the given mob is the new department head. See communications.dm for valid channels. /datum/outfit/job/proc/announce_head(var/mob/living/carbon/human/H, var/channels) //tells the given channel that the given mob is the new department head. See communications.dm for valid channels.
spawn(4) //to allow some initialization spawn(4) //to allow some initialization
if(announcement_systems.len) if(H && announcement_systems.len)
var/obj/machinery/announcement_system/announcer = pick(announcement_systems) var/obj/machinery/announcement_system/announcer = pick(announcement_systems)
announcer.announce("NEWHEAD", H.real_name, H.job, channels) announcer.announce("NEWHEAD", H.real_name, H.job, channels)

View File

@@ -363,10 +363,11 @@
/obj/machinery/gun_turret/New() /obj/machinery/gun_turret/New()
..() ..()
take_damage(0) //check your health
icon_state = "[base_icon_state]" + "0"
if(!base) if(!base)
base = src base = src
take_damage(0) //check your health
icon_state = "[base_icon_state]" + "0"
/obj/machinery/gun_turret/ex_act(severity, target) /obj/machinery/gun_turret/ex_act(severity, target)
switch(severity) switch(severity)
@@ -400,8 +401,6 @@
die() die()
return return
state = 2 state = 2
if(!base)
state = 2
update_icon() update_icon()
return return

View File

@@ -198,7 +198,7 @@
S.poison_per_bite = poison_per_bite S.poison_per_bite = poison_per_bite
S.poison_type = poison_type S.poison_type = poison_type
if(player_spiders) if(player_spiders)
var/list/candidates = get_candidates(BE_ALIEN, ALIEN_AFK_BRACKET) var/list/candidates = get_candidates(ROLE_ALIEN, ALIEN_AFK_BRACKET)
shuffle(candidates) shuffle(candidates)

View File

@@ -65,11 +65,11 @@
var/mob/living/carbon/human/H = null var/mob/living/carbon/human/H = null
for(var/mob/living/carbon/human/applicant in player_list) for(var/mob/living/carbon/human/applicant in player_list)
if(BE_TRAITOR in applicant.client.prefs.be_special) if(ROLE_TRAITOR in applicant.client.prefs.be_special)
if(!applicant.stat) if(!applicant.stat)
if(applicant.mind) if(applicant.mind)
if (!applicant.mind.special_role) if (!applicant.mind.special_role)
if(!jobban_isbanned(applicant, "traitor") && !jobban_isbanned(applicant, "Syndicate")) if(!jobban_isbanned(applicant, ROLE_TRAITOR) && !jobban_isbanned(applicant, "Syndicate"))
if(temp.age_check(applicant.client)) if(temp.age_check(applicant.client))
if(!(applicant.job in temp.restricted_jobs)) if(!(applicant.job in temp.restricted_jobs))
candidates += applicant candidates += applicant
@@ -101,11 +101,11 @@
var/mob/living/carbon/human/H = null var/mob/living/carbon/human/H = null
for(var/mob/living/carbon/human/applicant in player_list) for(var/mob/living/carbon/human/applicant in player_list)
if(BE_CHANGELING in applicant.client.prefs.be_special) if(ROLE_CHANGELING in applicant.client.prefs.be_special)
if(!applicant.stat) if(!applicant.stat)
if(applicant.mind) if(applicant.mind)
if (!applicant.mind.special_role) if (!applicant.mind.special_role)
if(!jobban_isbanned(applicant, "changeling") && !jobban_isbanned(applicant, "Syndicate")) if(!jobban_isbanned(applicant, ROLE_CHANGELING) && !jobban_isbanned(applicant, "Syndicate"))
if(temp.age_check(applicant.client)) if(temp.age_check(applicant.client))
if(!(applicant.job in temp.restricted_jobs)) if(!(applicant.job in temp.restricted_jobs))
candidates += applicant candidates += applicant
@@ -135,11 +135,11 @@
var/mob/living/carbon/human/H = null var/mob/living/carbon/human/H = null
for(var/mob/living/carbon/human/applicant in player_list) for(var/mob/living/carbon/human/applicant in player_list)
if(BE_REV in applicant.client.prefs.be_special) if(ROLE_REV in applicant.client.prefs.be_special)
if(applicant.stat == CONSCIOUS) if(applicant.stat == CONSCIOUS)
if(applicant.mind) if(applicant.mind)
if(!applicant.mind.special_role) if(!applicant.mind.special_role)
if(!jobban_isbanned(applicant, "revolutionary") && !jobban_isbanned(applicant, "Syndicate")) if(!jobban_isbanned(applicant, ROLE_REV) && !jobban_isbanned(applicant, "Syndicate"))
if(temp.age_check(applicant.client)) if(temp.age_check(applicant.client))
if(!(applicant.job in temp.restricted_jobs)) if(!(applicant.job in temp.restricted_jobs))
candidates += applicant candidates += applicant
@@ -206,11 +206,11 @@
var/mob/living/carbon/human/H = null var/mob/living/carbon/human/H = null
for(var/mob/living/carbon/human/applicant in player_list) for(var/mob/living/carbon/human/applicant in player_list)
if(BE_CULTIST in applicant.client.prefs.be_special) if(ROLE_CULTIST in applicant.client.prefs.be_special)
if(applicant.stat == CONSCIOUS) if(applicant.stat == CONSCIOUS)
if(applicant.mind) if(applicant.mind)
if(!applicant.mind.special_role) if(!applicant.mind.special_role)
if(!jobban_isbanned(applicant, "cultist") && !jobban_isbanned(applicant, "Syndicate")) if(!jobban_isbanned(applicant, ROLE_CULTIST) && !jobban_isbanned(applicant, "Syndicate"))
if(temp.age_check(applicant.client)) if(temp.age_check(applicant.client))
if(!(applicant.job in temp.restricted_jobs)) if(!(applicant.job in temp.restricted_jobs))
candidates += applicant candidates += applicant
@@ -386,11 +386,11 @@
var/mob/living/carbon/human/H = null var/mob/living/carbon/human/H = null
for(var/mob/living/carbon/human/applicant in player_list) for(var/mob/living/carbon/human/applicant in player_list)
if(BE_GANG in applicant.client.prefs.be_special) if(ROLE_GANG in applicant.client.prefs.be_special)
if(!applicant.stat) if(!applicant.stat)
if(applicant.mind) if(applicant.mind)
if(!applicant.mind.special_role) if(!applicant.mind.special_role)
if(!jobban_isbanned(applicant, "gangster") && !jobban_isbanned(applicant, "Syndicate")) if(!jobban_isbanned(applicant, ROLE_GANG) && !jobban_isbanned(applicant, "Syndicate"))
if(temp.age_check(applicant.client)) if(temp.age_check(applicant.client))
if(!(applicant.job in temp.restricted_jobs)) if(!(applicant.job in temp.restricted_jobs))
candidates += applicant candidates += applicant
@@ -584,7 +584,7 @@
var/list/mob/living/carbon/human/candidates = list() var/list/mob/living/carbon/human/candidates = list()
var/mob/living/carbon/human/H = null var/mob/living/carbon/human/H = null
for(var/mob/living/carbon/human/applicant in player_list) for(var/mob/living/carbon/human/applicant in player_list)
if(BE_SHADOWLING in applicant.client.prefs.be_special) if(ROLE_SHADOWLING in applicant.client.prefs.be_special)
if(!applicant.stat) if(!applicant.stat)
if(applicant.mind) if(applicant.mind)
if(!applicant.mind.special_role) if(!applicant.mind.special_role)

View File

@@ -198,7 +198,7 @@
var/list/candidates = list() var/list/candidates = list()
for(var/mob/M in player_list) for(var/mob/M in player_list)
if(M.stat != DEAD) continue //we are not dead! if(M.stat != DEAD) continue //we are not dead!
if(!(BE_ALIEN in M.client.prefs.be_special)) continue //we don't want to be an alium if(!(ROLE_ALIEN in M.client.prefs.be_special)) continue //we don't want to be an alium
if(M.client.is_afk()) continue //we are afk if(M.client.is_afk()) continue //we are afk
if(M.mind && M.mind.current && M.mind.current.stat != DEAD) continue //we have a live body we are tied to if(M.mind && M.mind.current && M.mind.current.stat != DEAD) continue //we have a live body we are tied to
candidates += M.ckey candidates += M.ckey

View File

@@ -2,26 +2,6 @@
var/list/preferences_datums = list() var/list/preferences_datums = list()
var/global/list/special_roles = list( //keep synced with the defines BE_* in setup.dm
//some autodetection here.
"traitor" = /datum/game_mode/traitor, //0
"operative" = /datum/game_mode/nuclear, //1
"changeling" = /datum/game_mode/changeling, //2
"wizard" = /datum/game_mode/wizard, //3
"malf AI" = /datum/game_mode/malfunction, //4
"revolutionary" = /datum/game_mode/revolution, //5
"alien", //6
"pAI/posibrain", //7
"cultist" = /datum/game_mode/cult, //8
"blob" = /datum/game_mode/blob, //9
"ninja", //10
"monkey" = /datum/game_mode/monkey, //11
"gangster" = /datum/game_mode/gang, //12
"shadowling" = /datum/game_mode/shadowling, //13
"abductor" = /datum/game_mode/abduction, //14
"hand of god, god" = /datum/game_mode/hand_of_god, //15
"hand of god, culstist" = /datum/game_mode/hand_of_god, //16
)
/datum/preferences /datum/preferences
@@ -367,7 +347,7 @@ var/global/list/special_roles = list( //keep synced with the defines BE_* in set
dat += "</td><td width='300px' height='300px' valign='top'>" dat += "</td><td width='300px' height='300px' valign='top'>"
dat += "<h2>Antagonist Settings</h2>" dat += "<h2>Special Role Settings</h2>"
if(jobban_isbanned(user, "Syndicate")) if(jobban_isbanned(user, "Syndicate"))
dat += "<font color=red><b>You are banned from antagonist roles.</b></font>" dat += "<font color=red><b>You are banned from antagonist roles.</b></font>"
@@ -376,7 +356,7 @@ var/global/list/special_roles = list( //keep synced with the defines BE_* in set
for (var/i in special_roles) for (var/i in special_roles)
if(jobban_isbanned(user, i)) if(jobban_isbanned(user, i))
dat += "<b>Be [i]:</b> <a href='?_src_=prefs;jobbancheck=[i]'>BANNED</a><br>" dat += "<b>Be [capitalize(i)]:</b> <a href='?_src_=prefs;jobbancheck=[i]'>BANNED</a><br>"
else else
var/days_remaining = null var/days_remaining = null
if(config.use_age_restriction_for_jobs && ispath(special_roles[i])) //If it's a game mode antag, check if the player meets the minimum age if(config.use_age_restriction_for_jobs && ispath(special_roles[i])) //If it's a game mode antag, check if the player meets the minimum age
@@ -384,12 +364,10 @@ var/global/list/special_roles = list( //keep synced with the defines BE_* in set
var/datum/game_mode/temp_mode = new mode_path var/datum/game_mode/temp_mode = new mode_path
days_remaining = temp_mode.get_remaining_days(user.client) days_remaining = temp_mode.get_remaining_days(user.client)
var/antagkey = capitalize(i)
if(days_remaining) if(days_remaining)
dat += "<b>Be [i]:</b> <font color=red> \[IN [days_remaining] DAYS]</font><br>" dat += "<b>Be [capitalize(i)]:</b> <font color=red> \[IN [days_remaining] DAYS]</font><br>"
else else
dat += "<b>Be [i]:</b> <a href='?_src_=prefs;preference=be_special;be_special_type=[be_special_flags[antagkey]]'>[(antagkey in be_special) ? "Yes" : "No"]</a><br>" dat += "<b>Be [capitalize(i)]:</b> <a href='?_src_=prefs;preference=be_special;be_special_type=[i]'>[(i in be_special) ? "Yes" : "No"]</a><br>"
dat += "</td></tr></table>" dat += "</td></tr></table>"
@@ -1000,7 +978,7 @@ var/global/list/special_roles = list( //keep synced with the defines BE_* in set
toggles ^= ANNOUNCE_LOGIN toggles ^= ANNOUNCE_LOGIN
if("be_special") if("be_special")
var/be_special_type = text2num(href_list["be_special_type"]) var/be_special_type = href_list["be_special_type"]
if(be_special_type in be_special) if(be_special_type in be_special)
be_special -= be_special_type be_special -= be_special_type
else else

View File

@@ -52,14 +52,45 @@ SAVEFILE UPDATING/VERSIONING - 'Simplified', or rather, more coder-friendly ~Car
var/B_revenant = 32768 var/B_revenant = 32768
var/list/archived = list(B_traitor,B_operative,B_changeling,B_wizard,B_malf,B_rev,B_alien,B_pai,B_cultist,B_blob,B_ninja,B_monkey,B_gang,B_shadowling,B_abductor,B_revenant) var/list/archived = list(B_traitor,B_operative,B_changeling,B_wizard,B_malf,B_rev,B_alien,B_pai,B_cultist,B_blob,B_ninja,B_monkey,B_gang,B_shadowling,B_abductor,B_revenant)
var/list/new_be_special = list()
be_special = list()
for(var/flag in archived) for(var/flag in archived)
if(old_be_special & flag) if(old_be_special & flag)
new_be_special += flag //this is shitty, but this proc should only be run once per player and then never again for the rest of eternity,
switch(flag)
be_special = new_be_special.Copy() if(1) //why aren't these the variables above? Good question, it's because byond complains the expression isn't constant, when it is.
be_special += ROLE_TRAITOR
if(2)
be_special += ROLE_OPERATIVE
if(4)
be_special += ROLE_CHANGELING
if(8)
be_special += ROLE_WIZARD
if(16)
be_special += ROLE_MALF
if(32)
be_special += ROLE_REV
if(64)
be_special += ROLE_ALIEN
if(128)
be_special += ROLE_PAI
if(256)
be_special += ROLE_CULTIST
if(512)
be_special += ROLE_BLOB
if(1024)
be_special += ROLE_NINJA
if(2048)
be_special += ROLE_MONKEY
if(4096)
be_special += ROLE_GANG
if(8192)
be_special += ROLE_SHADOWLING
if(16384)
be_special += ROLE_ABDUCTOR
if(32768)
be_special += ROLE_REVENANT
/datum/preferences/proc/update_preferences(current_version) /datum/preferences/proc/update_preferences(current_version)

View File

@@ -215,18 +215,33 @@
feedback_add_details("admin_verb", "SAmbi") //If you are copy-pasting this, I bet you read this comment expecting to see the same thing :^) feedback_add_details("admin_verb", "SAmbi") //If you are copy-pasting this, I bet you read this comment expecting to see the same thing :^)
//be special //be special
/client/verb/toggle_be_special(role in be_special_flags) /client/verb/toggle_be_special(/*role in be_special_flags*/)
set name = "Toggle SpecialRole Candidacy" set name = "Toggle SpecialRole Candidacy"
set category = "Preferences" set category = "Preferences"
set desc = "Toggles which special roles you would like to be a candidate for, during events." set desc = "Toggles which special roles you would like to be a candidate for, during events."
var/role_flag = be_special_flags[role]
if(!role_flag) return var/list/options = list()
for(var/role in special_roles)
var/key = capitalize(role)
if(role in prefs.be_special)
key += " (Enabled)"
else
key += " (Disabled)"
options[key] = role
var/a_input = input(src,"Special role candicacy","Special roles") as null|anything in options
if(!a_input || !options[a_input])
return
var/role_flag = options[a_input]
if(role_flag in prefs.be_special) if(role_flag in prefs.be_special)
prefs.be_special -= role_flag prefs.be_special -= role_flag
else else
prefs.be_special += role_flag prefs.be_special += role_flag
prefs.save_preferences() prefs.save_preferences()
src << "You will [(prefs.be_special & role_flag) ? "now" : "no longer"] be considered for [role] events (where possible)." src << "You will [(role_flag in prefs.be_special) ? "now" : "no longer"] be considered for [capitalize(role_flag)] events (where possible)."
feedback_add_details("admin_verb","TBeSpecial") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc! feedback_add_details("admin_verb","TBeSpecial") //If you are copy-pasting this, ensure the 2nd parameter is unique to the new proc!
/client/verb/toggle_member_publicity() /client/verb/toggle_member_publicity()

View File

@@ -35,7 +35,7 @@
if(temp_vent_parent.other_atmosmch.len > 20) //Stops Aliens getting stuck in small networks. See: Security, Virology if(temp_vent_parent.other_atmosmch.len > 20) //Stops Aliens getting stuck in small networks. See: Security, Virology
vents += temp_vent vents += temp_vent
var/list/candidates = get_candidates(BE_ALIEN, ALIEN_AFK_BRACKET) var/list/candidates = get_candidates(ROLE_ALIEN, ALIEN_AFK_BRACKET)
while(spawncount > 0 && vents.len && candidates.len) while(spawncount > 0 && vents.len && candidates.len)
var/obj/vent = pick_n_take(vents) var/obj/vent = pick_n_take(vents)

View File

@@ -10,7 +10,7 @@
for(var/datum/mind/M in ticker.mode.wizards) for(var/datum/mind/M in ticker.mode.wizards)
if(!ishuman(M.current)) continue if(!ishuman(M.current)) continue
var/mob/living/carbon/human/W = M.current var/mob/living/carbon/human/W = M.current
var/list/candidates = get_candidates(BE_WIZARD) var/list/candidates = get_candidates(ROLE_WIZARD)
if(!candidates) return //Sad Trombone if(!candidates) return //Sad Trombone
var/client/C = pick(candidates) var/client/C = pick(candidates)

View File

@@ -362,3 +362,9 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
ManualFollow(target) ManualFollow(target)
if(href_list["reenter"]) if(href_list["reenter"])
reenter_corpse() reenter_corpse()
//We don't want to update the current var
//But we will still carry a mind.
/mob/dead/observer/mind_initialize()
return

View File

@@ -67,7 +67,7 @@ var/const/ALIEN_AFK_BRACKET = 450 // 45 seconds
/obj/item/organ/internal/body_egg/alien_embryo/proc/AttemptGrow(gib_on_success = 1) /obj/item/organ/internal/body_egg/alien_embryo/proc/AttemptGrow(gib_on_success = 1)
if(!owner) return if(!owner) return
var/list/candidates = get_candidates(BE_ALIEN, ALIEN_AFK_BRACKET) var/list/candidates = get_candidates(ROLE_ALIEN, ALIEN_AFK_BRACKET)
var/client/C = null var/client/C = null
// To stop clientless larva, we will check that our host has a client // To stop clientless larva, we will check that our host has a client

View File

@@ -42,7 +42,6 @@
var/metabolism_efficiency = 1 //more or less efficiency to metabolize helpful/harmful reagents and regulate body temperature.. var/metabolism_efficiency = 1 //more or less efficiency to metabolize helpful/harmful reagents and regulate body temperature..
var/list/image/staticOverlays = list() var/list/image/staticOverlays = list()
var/has_limbs = 0 //does the mob have distinct limbs?(arms,legs, chest,head) var/has_limbs = 0 //does the mob have distinct limbs?(arms,legs, chest,head)
var/list/datum/action/actions = list()
var/list/pipes_shown = list() var/list/pipes_shown = list()
var/last_played_vent var/last_played_vent

View File

@@ -526,7 +526,7 @@
return return
used = TRUE used = TRUE
user << "[use_message]" user << "[use_message]"
var/list/candidates = get_candidates(BE_ALIEN, ALIEN_AFK_BRACKET) var/list/candidates = get_candidates(ROLE_ALIEN, ALIEN_AFK_BRACKET)
shuffle(candidates) shuffle(candidates)

View File

@@ -195,7 +195,7 @@
/datum/round_event/morph/proc/get_morph(end_if_fail = 0) /datum/round_event/morph/proc/get_morph(end_if_fail = 0)
key_of_morph = null key_of_morph = null
if(!key_of_morph) if(!key_of_morph)
var/list/candidates = get_candidates(BE_ALIEN) var/list/candidates = get_candidates(ROLE_ALIEN)
if(!candidates.len) if(!candidates.len)
if(end_if_fail) if(end_if_fail)
return 0 return 0

View File

@@ -385,7 +385,7 @@
break break
message_admins("The new revenant's old client either could not be found or is in a new, living mob - grabbing a random candidate instead...") message_admins("The new revenant's old client either could not be found or is in a new, living mob - grabbing a random candidate instead...")
else else
var/list/candidates = get_candidates(BE_REVENANT) var/list/candidates = get_candidates(ROLE_REVENANT)
if(!candidates.len) if(!candidates.len)
message_admins("No candidates were found for the new revenant. Oh well!") message_admins("No candidates were found for the new revenant. Oh well!")
return 0 return 0

View File

@@ -21,7 +21,7 @@
return return
key_of_revenant = null key_of_revenant = null
if(!key_of_revenant) if(!key_of_revenant)
var/list/candidates = get_candidates(BE_REVENANT) var/list/candidates = get_candidates(ROLE_REVENANT)
if(!candidates.len) if(!candidates.len)
if(end_if_fail) if(end_if_fail)
return 0 return 0

View File

@@ -15,7 +15,7 @@
/datum/round_event/slaughter/proc/get_slaughter(end_if_fail = 0) /datum/round_event/slaughter/proc/get_slaughter(end_if_fail = 0)
key_of_slaughter = null key_of_slaughter = null
if(!key_of_slaughter) if(!key_of_slaughter)
var/list/candidates = get_candidates(BE_ALIEN) var/list/candidates = get_candidates(ROLE_ALIEN)
if(!candidates.len) if(!candidates.len)
if(end_if_fail) if(end_if_fail)
return 0 return 0

View File

@@ -56,6 +56,8 @@
client.screen += client.void client.screen += client.void
sync_mind()
// Calling update_interface() in /mob/Login() causes the Cyborg to immediately be ghosted; because of winget(). // Calling update_interface() in /mob/Login() causes the Cyborg to immediately be ghosted; because of winget().
// Calling it in the overriden Login, such as /mob/living/Login() doesn't cause this. // Calling it in the overriden Login, such as /mob/living/Login() doesn't cause this.
/mob/proc/update_interface() /mob/proc/update_interface()

View File

@@ -6,6 +6,7 @@
hud_possible = list(ANTAG_HUD) hud_possible = list(ANTAG_HUD)
pressure_resistance = 8 pressure_resistance = 8
var/datum/mind/mind var/datum/mind/mind
var/list/datum/action/actions = list()
var/stat = 0 //Whether a mob is alive or dead. TODO: Move this to living - Nodrak var/stat = 0 //Whether a mob is alive or dead. TODO: Move this to living - Nodrak

View File

@@ -433,11 +433,9 @@
gib(src) gib(src)
/mob/proc/become_god(var/side) /mob/proc/become_god(var/side_colour)
if(client) var/mob/camera/god/G = new /mob/camera/god(loc)
src << sound(null, repeat = 0, wait = 0, wolume = 85, channel = 1) G.side = side_colour
var/mob/camera/god/G = new(loc, side = side)
G.invisibility = 40 G.invisibility = 40
if(mind) if(mind)
mind.transfer_to(G) mind.transfer_to(G)
@@ -446,6 +444,7 @@
G.job = "Deity" G.job = "Deity"
G.rename_self("deity", 0) G.rename_self("deity", 0)
G.update_icons()
. = G . = G
qdel(src) qdel(src)

View File

@@ -54,7 +54,7 @@ Contents:
//selecting a candidate player //selecting a candidate player
if(!key) if(!key)
var/list/candidates = get_candidates(BE_NINJA) var/list/candidates = get_candidates(ROLE_NINJA)
if(!candidates.len) if(!candidates.len)
return kill() return kill()
var/client/C = pick(candidates) var/client/C = pick(candidates)

View File

@@ -176,7 +176,7 @@
user << "<span class='notice'>You offer the sentience potion to [M]...</span>" user << "<span class='notice'>You offer the sentience potion to [M]...</span>"
being_used = 1 being_used = 1
var/list/candidates = get_candidates(BE_ALIEN, ALIEN_AFK_BRACKET) var/list/candidates = get_candidates(ROLE_ALIEN, ALIEN_AFK_BRACKET)
shuffle(candidates) shuffle(candidates)

View File

@@ -1 +1 @@
extended handofgod

Binary file not shown.

Before

Width:  |  Height:  |  Size: 13 KiB

After

Width:  |  Height:  |  Size: 13 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 230 KiB

After

Width:  |  Height:  |  Size: 230 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 98 KiB

After

Width:  |  Height:  |  Size: 99 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 257 KiB

After

Width:  |  Height:  |  Size: 259 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 23 KiB

After

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 48 KiB

After

Width:  |  Height:  |  Size: 47 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 53 KiB

After

Width:  |  Height:  |  Size: 54 KiB

View File

@@ -33,6 +33,7 @@
#include "code\__DEFINES\pipe_construction.dm" #include "code\__DEFINES\pipe_construction.dm"
#include "code\__DEFINES\preferences.dm" #include "code\__DEFINES\preferences.dm"
#include "code\__DEFINES\qdel.dm" #include "code\__DEFINES\qdel.dm"
#include "code\__DEFINES\role_preferences.dm"
#include "code\__DEFINES\say.dm" #include "code\__DEFINES\say.dm"
#include "code\__DEFINES\sight.dm" #include "code\__DEFINES\sight.dm"
#include "code\__DEFINES\stat.dm" #include "code\__DEFINES\stat.dm"