Code:
o=player.GetMainCharacterIndex()
for i in xrange(o-150000, o+150000):
dys = player.GetCharacterDistance(i)
if dys > 0 and dys < 7500:
a = chr.GetInstanceType(i)
if a==6:
imie=chr.GetNameByVID(i)
chat.AppendChat(7,"# player in range: "+str(imie)) +" - dys: "+str(int(dys)))
#====================== work but only in ~7500 and loosing my char target ======================
player.SetTarget(i)
if player.GetTargetVID() != 0:
chat.AppendChat(7,"# alive by target")
else:
chat.AppendChat(7,"# dead by target")
#====================== only for mobs? ======================
info = chrmgr.GetVIDInfo(i)
chat.AppendChat(7,"# isalive: "+info.split("isAlive=")[1][0])






