Sync with L2JServer Jan 24th 2015.

This commit is contained in:
mobius
2015-01-24 20:02:32 +00:00
parent d349bd3924
commit 1c6301c46d
1012 changed files with 23069 additions and 6307 deletions

View File

@@ -236,15 +236,18 @@ public abstract class AbstractOlympiadGame
// Remove Summon's Buffs
if (player.hasSummon())
{
final L2Summon summon = player.getSummon();
summon.stopAllEffectsExceptThoseThatLastThroughDeath();
summon.abortAttack();
summon.abortCast();
if (summon.isPet())
final L2Summon pet = player.getPet();
if (pet != null)
{
summon.unSummon(player);
pet.unSummon(player);
}
player.getServitors().values().forEach(s ->
{
s.stopAllEffectsExceptThoseThatLastThroughDeath();
s.abortAttack();
s.abortCast();
});
}
// stop any cubic that has been given by other player.
@@ -319,16 +322,25 @@ public abstract class AbstractOlympiadGame
{
player.setAgathionId(0);
}
final L2Summon summon = player.getSummon();
if ((summon != null) && !summon.isDead())
final L2Summon pet = player.getPet();
if ((pet != null) && !pet.isDead())
{
summon.setTarget(null);
summon.abortAttack();
summon.abortCast();
summon.getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE);
summon.stopAllEffectsExceptThoseThatLastThroughDeath();
pet.setTarget(null);
pet.abortAttack();
pet.abortCast();
pet.getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE);
pet.stopAllEffectsExceptThoseThatLastThroughDeath();
}
player.getServitors().values().stream().filter(s -> !s.isDead()).forEach(s ->
{
s.setTarget(null);
s.abortAttack();
s.abortCast();
s.getAI().setIntention(CtrlIntention.AI_INTENTION_IDLE);
s.stopAllEffectsExceptThoseThatLastThroughDeath();
});
player.setCurrentCp(player.getMaxCp());
player.setCurrentHp(player.getMaxHp());
player.setCurrentMp(player.getMaxMp());