Fixed some possible runtimes with pollCandidates() (#19919)

* Fixed some possible runtimes with pollCandidates()

* Fixed bug in pollCandidatesForMobs()
This commit is contained in:
Cruix
2016-08-21 13:45:22 -07:00
committed by oranges
parent c3da691c16
commit f406e518cc
7 changed files with 23 additions and 7 deletions
+1 -1
View File
@@ -453,7 +453,7 @@ It's fairly easy to fix if dealing with single letters but not so much with comp
poll_message = "[poll_message] Job:[M.mind.assigned_role]."
if(M.mind && M.mind.special_role)
poll_message = "[poll_message] Status:[M.mind.special_role]."
var/list/mob/dead/observer/candidates = pollCandidates(poll_message, "pAI", null, FALSE, 100)
var/list/mob/dead/observer/candidates = pollCandidatesForMob(poll_message, "pAI", null, FALSE, 100, M)
var/mob/dead/observer/theghost = null
if(candidates.len)