forked from Mirrors/openclonk
make bats not attack prey in containers
parent
0e6f1599c6
commit
bc3d0bb29d
|
@ -157,7 +157,8 @@ private func FxCoreBehaviorTimer(object target, proplist effect, int time)
|
|||
|
||||
if (Distance(GetX(), GetY(), effect.attack_target->GetX(), effect.attack_target->GetY()) < 10)
|
||||
{
|
||||
BitePrey(effect.attack_target);
|
||||
if (!effect.attack_target->Contained())
|
||||
BitePrey(effect.attack_target);
|
||||
effect.attack_target = nil;
|
||||
SetRandomDirection();
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue