removed client/var/be_alien and client/var/be_pai, everything now uses client.prefs.be_special

git-svn-id: http://tgstation13.googlecode.com/svn/trunk@5126 316c924e-a436-60f5-8080-3fe189b3f50e
This commit is contained in:
elly1989@rocketmail.com
2012-11-19 18:35:14 +00:00
parent 6d05ae60de
commit 27a53e211b
7 changed files with 11 additions and 21 deletions

View File

@@ -303,7 +303,7 @@ proc/isInSight(var/atom/A, var/atom/B)
var/i = 0
while(candidates.len <= 0 && i < 5)
for(var/mob/dead/observer/G in player_list)
if(G.client.be_alien)
if(G.client.prefs.be_special & BE_ALIEN)
if(((G.client.inactivity/10)/60) <= ALIEN_SELECT_AFK_BUFFER + i) // the most active players are more likely to become an alien
if(!(G.mind && G.mind.current && G.mind.current.stat != DEAD))
candidates += G.key

View File

@@ -41,7 +41,7 @@
proc/create_fragments(var/wave_size = 1)
var/list/candidates = list()
for(var/mob/dead/observer/G in player_list)
if(G.client.be_alien)
if(G.client.prefs.be_special & BE_ALIEN)
if(!(G.mind && G.mind.current && G.mind.current.stat != DEAD))
candidates += G.key

View File

@@ -200,7 +200,7 @@ proc/cmd_admin_mute(mob/M as mob, mute_type, automute = 0)
var/list/candidates = list()
for(var/mob/M in player_list)
if(M.stat != DEAD) continue //we are not dead!
if(!M.client.be_alien) continue //we don't want to be an alium
if(!M.client.prefs.be_special & BE_ALIEN) continue //we don't want to be an alium
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
candidates += M.ckey

View File

@@ -20,8 +20,6 @@
var/deadchat = 1
var/area = null
var/played = 0
var/be_alien = 0 //Check if that guy wants to be an alien
var/be_pai = 1 //Consider client when searching for players to recruit as a pAI
var/STFU_ghosts //80+ people rounds are fun to admin when text flies faster than airport security
var/STFU_radio //80+ people rounds are fun to admin when text flies faster than airport security

View File

@@ -234,23 +234,17 @@ This is the proc mobs get to turn into a ghost. Forked from ghostize due to comp
set name = "Toggle Be Alien Candidate"
set category = "Ghost"
set desc = "Determines whether you will or will not be an alien candidate when someone bursts."
if(client.be_alien)
client.be_alien = 0
src << "You are now excluded from alien candidate lists until end of round."
else if(!client.be_alien)
client.be_alien = 1
src << "You are now included in alien candidate lists until end of round."
if(client)
client.prefs.be_special ^= BE_ALIEN
src << "You are now [(client.prefs.be_special & BE_ALIEN) ? "included in" : "excluded from"] alien candidate lists until end of round."
/mob/dead/observer/verb/toggle_pai_candidate()
set name = "Toggle Be pAI Candidate"
set category = "Ghost"
set desc = "Receive a pop-up request when a pAI device requests a new personality. (toggle)"
if(client.be_pai)
client.be_pai = 0
src << "You will no longer receive pAI recruitment pop-ups this round."
else
client.be_pai = 1
src << "You will now be considered a viable candidate when a pAI device requests a new personality, effective until the end of this round."
if(client)
client.prefs.be_special ^= BE_PAI
src << "You will [(client.prefs.be_special & BE_PAI) ? "now" : "no longer" ] recieve pAI recruitment pop-ups."
/mob/dead/observer/memory()
set hidden = 1

View File

@@ -201,7 +201,7 @@ var/datum/paiController/paiController // Global handler for pAI candidates
for(var/datum/paiCandidate/c in paiController.pai_candidates)
if(c.key == O.key)
hasSubmitted = 1
if(!hasSubmitted && O.client.be_pai)
if(!hasSubmitted && (O.client.prefs.be_special & BE_PAI))
question(O.client)
proc/question(var/client/C)
@@ -214,4 +214,4 @@ var/datum/paiController/paiController // Global handler for pAI candidates
if(response == "Yes")
recruitWindow(C.mob)
else if (response == "Never for this round")
C.be_pai = 0
C.prefs.be_special &= ~BE_PAI

View File

@@ -714,8 +714,6 @@ datum/preferences
C.holder.sound_adminhelp = src.sound_adminhelp
C.holder.ooccolor = src.ooccolor
C.midis = src.midis
C.be_alien = be_special & BE_ALIEN
C.be_pai = be_special & BE_PAI
if(isnull(src.ghost_ears)) src.ghost_ears = 1 //There were problems where the default was null before someone saved their profile.
C.ghost_ears = src.ghost_ears
C.ghost_sight = src.ghost_sight