Disable Tutorial config.

This commit is contained in:
MobiusDev
2016-07-06 18:26:20 +00:00
parent 88b1fc057d
commit b234222668
8 changed files with 70 additions and 0 deletions

View File

@@ -16,6 +16,7 @@
*/
package quests;
import com.l2jmobius.Config;
import com.l2jmobius.commons.util.CommonUtil;
import com.l2jmobius.gameserver.enums.CategoryType;
import com.l2jmobius.gameserver.enums.Race;
@@ -326,6 +327,11 @@ public abstract class ThirdClassTransferQuest extends Quest
@RegisterType(ListenerRegisterType.GLOBAL_PLAYERS)
public void OnPlayerLevelChanged(OnPlayerLevelChanged event)
{
if (Config.DISABLE_TUTORIAL)
{
return;
}
final L2PcInstance player = event.getActiveChar();
final int oldLevel = event.getOldLevel();
final int newLevel = event.getNewLevel();
@@ -340,6 +346,11 @@ public abstract class ThirdClassTransferQuest extends Quest
@RegisterType(ListenerRegisterType.GLOBAL_PLAYERS)
public void OnPlayerLogin(OnPlayerLogin event)
{
if (Config.DISABLE_TUTORIAL)
{
return;
}
final L2PcInstance player = event.getActiveChar();
if ((player.getLevel() >= _minLevel) && (player.getRace() == _race) && (player.isInCategory(CategoryType.THIRD_CLASS_GROUP)))