Additional AutoPlayTaskManager GeoEngine can see target check.
Thanks to petryxa.
This commit is contained in:
@@ -101,6 +101,13 @@ public class AutoPlayTaskManager
|
|||||||
{
|
{
|
||||||
if (creature.isAutoAttackable(player))
|
if (creature.isAutoAttackable(player))
|
||||||
{
|
{
|
||||||
|
// GeoEngine can see target check.
|
||||||
|
if (!GeoEngine.getInstance().canSeeTarget(player, creature))
|
||||||
|
{
|
||||||
|
player.setTarget(null);
|
||||||
|
continue PLAY;
|
||||||
|
}
|
||||||
|
|
||||||
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -101,6 +101,13 @@ public class AutoPlayTaskManager
|
|||||||
{
|
{
|
||||||
if (creature.isAutoAttackable(player))
|
if (creature.isAutoAttackable(player))
|
||||||
{
|
{
|
||||||
|
// GeoEngine can see target check.
|
||||||
|
if (!GeoEngine.getInstance().canSeeTarget(player, creature))
|
||||||
|
{
|
||||||
|
player.setTarget(null);
|
||||||
|
continue PLAY;
|
||||||
|
}
|
||||||
|
|
||||||
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -101,6 +101,13 @@ public class AutoPlayTaskManager
|
|||||||
{
|
{
|
||||||
if (creature.isAutoAttackable(player))
|
if (creature.isAutoAttackable(player))
|
||||||
{
|
{
|
||||||
|
// GeoEngine can see target check.
|
||||||
|
if (!GeoEngine.getInstance().canSeeTarget(player, creature))
|
||||||
|
{
|
||||||
|
player.setTarget(null);
|
||||||
|
continue PLAY;
|
||||||
|
}
|
||||||
|
|
||||||
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -101,6 +101,13 @@ public class AutoPlayTaskManager
|
|||||||
{
|
{
|
||||||
if (creature.isAutoAttackable(player))
|
if (creature.isAutoAttackable(player))
|
||||||
{
|
{
|
||||||
|
// GeoEngine can see target check.
|
||||||
|
if (!GeoEngine.getInstance().canSeeTarget(player, creature))
|
||||||
|
{
|
||||||
|
player.setTarget(null);
|
||||||
|
continue PLAY;
|
||||||
|
}
|
||||||
|
|
||||||
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -101,6 +101,13 @@ public class AutoPlayTaskManager
|
|||||||
{
|
{
|
||||||
if (creature.isAutoAttackable(player))
|
if (creature.isAutoAttackable(player))
|
||||||
{
|
{
|
||||||
|
// GeoEngine can see target check.
|
||||||
|
if (!GeoEngine.getInstance().canSeeTarget(player, creature))
|
||||||
|
{
|
||||||
|
player.setTarget(null);
|
||||||
|
continue PLAY;
|
||||||
|
}
|
||||||
|
|
||||||
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -101,6 +101,13 @@ public class AutoPlayTaskManager
|
|||||||
{
|
{
|
||||||
if (creature.isAutoAttackable(player))
|
if (creature.isAutoAttackable(player))
|
||||||
{
|
{
|
||||||
|
// GeoEngine can see target check.
|
||||||
|
if (!GeoEngine.getInstance().canSeeTarget(player, creature))
|
||||||
|
{
|
||||||
|
player.setTarget(null);
|
||||||
|
continue PLAY;
|
||||||
|
}
|
||||||
|
|
||||||
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -101,6 +101,13 @@ public class AutoPlayTaskManager
|
|||||||
{
|
{
|
||||||
if (creature.isAutoAttackable(player))
|
if (creature.isAutoAttackable(player))
|
||||||
{
|
{
|
||||||
|
// GeoEngine can see target check.
|
||||||
|
if (!GeoEngine.getInstance().canSeeTarget(player, creature))
|
||||||
|
{
|
||||||
|
player.setTarget(null);
|
||||||
|
continue PLAY;
|
||||||
|
}
|
||||||
|
|
||||||
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -102,6 +102,13 @@ public class AutoPlayTaskManager
|
|||||||
{
|
{
|
||||||
if (creature.isAutoAttackable(player))
|
if (creature.isAutoAttackable(player))
|
||||||
{
|
{
|
||||||
|
// GeoEngine can see target check.
|
||||||
|
if (!GeoEngine.getInstance().canSeeTarget(player, creature))
|
||||||
|
{
|
||||||
|
player.setTarget(null);
|
||||||
|
continue PLAY;
|
||||||
|
}
|
||||||
|
|
||||||
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -102,6 +102,13 @@ public class AutoPlayTaskManager
|
|||||||
{
|
{
|
||||||
if (creature.isAutoAttackable(player))
|
if (creature.isAutoAttackable(player))
|
||||||
{
|
{
|
||||||
|
// GeoEngine can see target check.
|
||||||
|
if (!GeoEngine.getInstance().canSeeTarget(player, creature))
|
||||||
|
{
|
||||||
|
player.setTarget(null);
|
||||||
|
continue PLAY;
|
||||||
|
}
|
||||||
|
|
||||||
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -102,6 +102,13 @@ public class AutoPlayTaskManager
|
|||||||
{
|
{
|
||||||
if (creature.isAutoAttackable(player))
|
if (creature.isAutoAttackable(player))
|
||||||
{
|
{
|
||||||
|
// GeoEngine can see target check.
|
||||||
|
if (!GeoEngine.getInstance().canSeeTarget(player, creature))
|
||||||
|
{
|
||||||
|
player.setTarget(null);
|
||||||
|
continue PLAY;
|
||||||
|
}
|
||||||
|
|
||||||
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@@ -102,6 +102,13 @@ public class AutoPlayTaskManager
|
|||||||
{
|
{
|
||||||
if (creature.isAutoAttackable(player))
|
if (creature.isAutoAttackable(player))
|
||||||
{
|
{
|
||||||
|
// GeoEngine can see target check.
|
||||||
|
if (!GeoEngine.getInstance().canSeeTarget(player, creature))
|
||||||
|
{
|
||||||
|
player.setTarget(null);
|
||||||
|
continue PLAY;
|
||||||
|
}
|
||||||
|
|
||||||
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
player.getAI().setIntention(CtrlIntention.AI_INTENTION_ATTACK, creature);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Reference in New Issue
Block a user