UE com X Criaturas

Const

MinMonsters = 5 //Quantidade de Bixo na tela
UeSpell = exevo gran mas frigo // qual ue vai usar
Delay = 2000 // Exausted por runa (1000 = 1 segundo)

ShootOnSelf = 1 // nao muda

while not terminated do
begin
A := 0;
UpdateWorld;
for i := 0 to creatures.count - 1 do
begin
if (i >= Creatures.Count) or (Terminated) then break;
if Creatures.Creature.Z = self.Z then
if Creatures.Creature.NPC then
A := A + 1;
end;
if A >= MinMonsters then
begin
if ShootOnSelf
then Self.Say(UeSpell)
else Self.Say(UeSpell)
sleep(Delay);
end;
sleep(500);
end;