Makes special role preferences a list, instead of flag entry.

Allows us to define more than 16 special roles.
Updates some role usages to use the new ghost trap system.
This commit is contained in:
PsiOmegaDelta
2016-01-15 11:12:50 +01:00
parent 228454c7d0
commit b74f2baf6d
15 changed files with 176 additions and 210 deletions

View File

@@ -330,12 +330,11 @@ proc/isInSight(var/atom/A, var/atom/B)
// Same as above but for alien candidates.
/proc/get_alien_candidates()
var/list/candidates = list() //List of candidate KEYS to assume control of the new larva ~Carn
var/i = 0
while(candidates.len <= 0 && i < 5)
for(var/mob/dead/observer/G in player_list)
if(G.client.prefs.be_special & BE_ALIEN)
if(BE_ALIEN in G.client.prefs.be_special_role)
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