Merge pull request #4780 from Citadel-Station-13/upstream-merge-34280
[MIRROR] Fixes mobs on lavaland targeting through walls on wakeup
This commit is contained in:
@@ -476,12 +476,15 @@ mob/living/simple_animal/hostile/proc/DestroySurroundings() // for use with mega
|
||||
toggle_ai(AI_Z_OFF)
|
||||
return
|
||||
|
||||
if (isturf(T) && !is_station_level(T.z))
|
||||
var/cheap_search = isturf(T) && !is_station_level(T.z)
|
||||
if (cheap_search)
|
||||
tlist = ListTargetsLazy(T.z)
|
||||
else
|
||||
tlist = ListTargets()
|
||||
|
||||
if(AIStatus == AI_IDLE && FindTarget(tlist, 1))
|
||||
if(cheap_search) //Try again with full effort
|
||||
FindTarget()
|
||||
toggle_ai(AI_ON)
|
||||
|
||||
/mob/living/simple_animal/hostile/proc/ListTargetsLazy(var/_Z)//Step 1, find out what we can see
|
||||
|
||||
Reference in New Issue
Block a user