Brothers Bound in Chains quest improvements.

Contributed by Mathael.
This commit is contained in:
MobiusDev
2016-07-22 20:12:02 +00:00
parent dad40c433d
commit 727c668980
20 changed files with 209 additions and 101 deletions

View File

@ -99,6 +99,7 @@ import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerLogin
import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerLogout;
import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerProfessionChange;
import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerSkillLearn;
import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerSummonAgathion;
import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerSummonSpawn;
import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerSummonTalk;
import com.l2jmobius.gameserver.model.events.impl.character.player.OnTrapAction;
@ -1382,6 +1383,13 @@ public abstract class AbstractScript extends ManagedScript implements IEventTime
return registerConsumer(callback, EventType.ON_INSTANCE_STATUS_CHANGE, ListenerRegisterType.INSTANCE, templateIds);
}
// ---------------------------------------------------------------------------------------------------------------------------
protected final List<AbstractEventListener> setPlayerSummonAgathion(Consumer<OnPlayerSummonAgathion> callback)
{
return registerConsumer(callback, EventType.ON_PLAYER_SUMMON_AGATHION, ListenerRegisterType.GLOBAL);
}
// --------------------------------------------------------------------------------------------------
// --------------------------------Default listener register methods---------------------------------
// --------------------------------------------------------------------------------------------------

View File

@ -105,6 +105,7 @@ import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerSelec
import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerSkillLearn;
import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerSocialAction;
import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerSubChange;
import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerSummonAgathion;
import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerSummonSpawn;
import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerSummonTalk;
import com.l2jmobius.gameserver.model.events.impl.character.player.OnPlayerTransform;
@ -266,6 +267,7 @@ public enum EventType
ON_PLAYER_SUB_CHANGE(OnPlayerSubChange.class, void.class),
ON_PLAYER_QUEST_ABORT(OnPlayerQuestAbort.class, void.class),
ON_PLAYER_QUEST_COMPLETE(OnPlayerQuestComplete.class, void.class),
ON_PLAYER_SUMMON_AGATHION(OnPlayerSummonAgathion.class, void.class),
// Trap events
ON_TRAP_ACTION(OnTrapAction.class, void.class),

View File

@ -0,0 +1,52 @@
/*
* This file is part of the L2J Mobius project.
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package com.l2jmobius.gameserver.model.events.impl.character.player;
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
import com.l2jmobius.gameserver.model.events.EventType;
import com.l2jmobius.gameserver.model.events.impl.IBaseEvent;
/**
* @author Mathael
*/
public class OnPlayerSummonAgathion implements IBaseEvent
{
private final L2PcInstance _player;
private final int _agathionId;
public OnPlayerSummonAgathion(L2PcInstance player, int agathionId)
{
_player = player;
_agathionId = agathionId;
}
public L2PcInstance getPlayer()
{
return _player;
}
public int getAgathionId()
{
return _agathionId;
}
@Override
public EventType getType()
{
return EventType.ON_PLAYER_SUMMON_AGATHION;
}
}