mirror of
https://github.com/Aurorastation/Aurora.3.git
synced 2026-08-31 09:00:25 +01:00
Give AI LOOC powers (#7886)
The AI can now hear and speak LOOC via its Eye as well as via its Core. Tested and it works.
This commit is contained in:
+11
-2
@@ -108,12 +108,21 @@
|
||||
var/list/messageturfs = list()//List of turfs we broadcast to.
|
||||
var/list/messagemobs = list()//List of living mobs nearby who can hear it
|
||||
|
||||
for (var/turf in range(world.view, get_turf(source)))
|
||||
for(var/turf in range(world.view, get_turf(source)))
|
||||
messageturfs += turf
|
||||
if(isAI(source))
|
||||
var/mob/living/silicon/ai/AI = source
|
||||
for(var/turf in range(world.view, get_turf(AI.eyeobj)))
|
||||
messageturfs += turf
|
||||
|
||||
for(var/mob/M in player_list)
|
||||
if (!M.client || istype(M, /mob/abstract/new_player))
|
||||
if(!M.client || istype(M, /mob/abstract/new_player))
|
||||
continue
|
||||
if(isAI(M))
|
||||
var/mob/living/silicon/ai/AI = M
|
||||
if(get_turf(AI.eyeobj) in messageturfs)
|
||||
messagemobs += M
|
||||
continue
|
||||
if(get_turf(M) in messageturfs)
|
||||
messagemobs += M
|
||||
|
||||
|
||||
Reference in New Issue
Block a user