Some extra checks for disabled tutorials.

This commit is contained in:
MobiusDev
2016-12-22 20:46:08 +00:00
parent 6dfa3603b3
commit cddb566c34
4 changed files with 39 additions and 0 deletions

View File

@@ -19,6 +19,7 @@ package instances.MemoryOfDisaster;
import java.util.List;
import java.util.stream.Collectors;
import com.l2jmobius.Config;
import com.l2jmobius.commons.util.CommonUtil;
import com.l2jmobius.commons.util.Rnd;
import com.l2jmobius.gameserver.ai.CtrlIntention;
@@ -1022,6 +1023,11 @@ public final class MemoryOfDisaster extends AbstractInstance
@RegisterType(ListenerRegisterType.GLOBAL_PLAYERS)
public void OnPlayerLogin(OnPlayerLogin event)
{
if (Config.DISABLE_TUTORIAL)
{
return;
}
final L2PcInstance player = event.getActiveChar();
if ((player.getLevel() > 84) && player.isInCategory(CategoryType.FOURTH_CLASS_GROUP) && !player.isSubClassActive() && (player.getClassId() != ClassId.JUDICATOR))
{
@@ -1037,6 +1043,11 @@ public final class MemoryOfDisaster extends AbstractInstance
@RegisterType(ListenerRegisterType.GLOBAL_PLAYERS)
public void OnPlayerLevelChanged(OnPlayerLevelChanged event)
{
if (Config.DISABLE_TUTORIAL)
{
return;
}
final L2PcInstance player = event.getActiveChar();
if ((player.getLevel() > 84) && player.isInCategory(CategoryType.FOURTH_CLASS_GROUP) && !player.isSubClassActive() && (player.getClassId() != ClassId.JUDICATOR))
{