CTGavesT Posted March 11 Posted March 11 Hello, I add this code here https://maxcheaters.com/topic/248730-agathions-acis-401-does-not-interfere-with-summons-or-pets/. but i have problem with agathion movement, agathion does not move when the player moves. The player must stop moving for Agathion to come close him. i think the problem is here at < _followTask = ThreadPool.scheduleAtFixedRate(new Follow(this), 1000, 1000); >> public void followToOwner() { if (_followTask == null) _followTask = ThreadPool.scheduleAtFixedRate(new Follow(this), 1000, 1000); int rnd = Rnd.get(-30, +30); SpawnLocation loc = _owner.getPosition(); if (!checkIfInRange(1000, this, _owner)) teleport(_owner, 30); if (_owner.isMoving()) getAI().tryToFollow(_owner, false); else { if (!checkIfInRange(75, this, _owner)) getAI().tryToMoveTo(new Location(loc.getX()+rnd, loc.getY()+rnd, loc.getZ()), null); else if (checkIfInRange(30, this, _owner)) getAI().tryToIdle(); if (Config.AGATHION_HEAL_OWNER && !getCast().isCastingNow()) { if (_owner.isInOlympiadMode() || _owner.isInDuel() || _owner.getPvpFlag() != 0 || _owner.isInsideZone(ZoneId.PVP) || _owner.getKarma() != 0) return; if ((_owner.getStatus().getHpRatio() < Config.AGATHION_PERCENT_TO_HEAL)) getAI().tryToCast(_owner, 1011, 18); } else if (!Config.AGATHION_ONLY_FOLLOW && Config.AGATHION_ALLOW_SOCIAL && !isMoving() && !getCast().isCastingNow()) broadcastPacket(new SocialAction(this, 1)); }
Question
CTGavesT
Hello, I add this code here https://maxcheaters.com/topic/248730-agathions-acis-401-does-not-interfere-with-summons-or-pets/.
but i have problem with agathion movement, agathion does not move when the player moves.
The player must stop moving for Agathion to come close him.
i think the problem is here at < _followTask = ThreadPool.scheduleAtFixedRate(new Follow(this), 1000, 1000); >>
public void followToOwner()
{
if (_followTask == null)
_followTask = ThreadPool.scheduleAtFixedRate(new Follow(this), 1000, 1000);
int rnd = Rnd.get(-30, +30);
SpawnLocation loc = _owner.getPosition();
if (!checkIfInRange(1000, this, _owner))
teleport(_owner, 30);
if (_owner.isMoving())
getAI().tryToFollow(_owner, false);
else
{
if (!checkIfInRange(75, this, _owner))
getAI().tryToMoveTo(new Location(loc.getX()+rnd, loc.getY()+rnd, loc.getZ()), null);
else if (checkIfInRange(30, this, _owner))
getAI().tryToIdle();
if (Config.AGATHION_HEAL_OWNER && !getCast().isCastingNow())
{
if (_owner.isInOlympiadMode() || _owner.isInDuel() || _owner.getPvpFlag() != 0 || _owner.isInsideZone(ZoneId.PVP) || _owner.getKarma() != 0)
return;
if ((_owner.getStatus().getHpRatio() < Config.AGATHION_PERCENT_TO_HEAL))
getAI().tryToCast(_owner, 1011, 18);
}
else if (!Config.AGATHION_ONLY_FOLLOW && Config.AGATHION_ALLOW_SOCIAL && !isMoving() && !getCast().isCastingNow())
broadcastPacket(new SocialAction(this, 1));
}
0 answers to this question
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now