Classmasters with 4th class support.

This commit is contained in:
MobiusDev
2015-05-17 00:46:27 +00:00
parent 1a7e7554a0
commit add48c6f5b
10 changed files with 122 additions and 19 deletions

View File

@@ -157,25 +157,26 @@ EffectTickRatio = 666
# Default: False
AllowClassMasters = False
# ConfigClassMaster=1;[57(100000)];[];2;[57(1000000)];[];3;[57(10000000)],[5575(1000000)];[6622(1)]
# 1st occupation change for 100.000 Adena (item id 57)
# 2nd occupation change for 1.000.0000 Adena (item id 57)
# 3rd occupation change for 10.000.0000 Adena (item id 57) and 1.000.000 Ancient Adena (item id 5575)
# on 3rd occupation change player will be rewarded with 1 Book of Giants (item id 6622)
# ConfigClassMaster=1;[];[];2;[];[];3;[];[]
# 1st, 2nd, 3rd occupation change for free, without rewards.
# ConfigClassMaster=1;[57(100000)];[];2;[57(1000000)];[];3;[57(10000000)],[5575(1000000)];[6622(1)];4;[57(100000000)];[]
# 1st occupation change for 100.000 Adena (item id 57)
# 2nd occupation change for 1.000.0000 Adena (item id 57)
# 3rd occupation change for 10.000.0000 Adena (item id 57) and 1.000.000 Ancient Adena (item id 5575)
# on 3rd occupation change player will be rewarded with 1 Book of Giants (item id 6622)
# 4th occupation change for 100.000.0000 Adena (item id 57)
# ConfigClassMaster=1;[];[];2;[];[]
# Allow only first and second change.
ConfigClassMaster = 1;[];[];2;[];[];3;[];[]
# ConfigClassMaster=1;[];[];2;[];[];3;[];[];4;[];[]
# 1st, 2nd, 3rd, 4th occupation change for free, without rewards.
ConfigClassMaster = 1;[];[];2;[];[];3;[];[];4;[];[]
# Class Masters will allow changing to any occupation on any level inside class tree
# For example, Dwarven Fighter will be able to advance to:
# Artisan, Scavenger, Warsmith, Bounty Hunter, Maestro, Fortune Seeker.
# But Warsmith will be able to change only to Maestro.
# But Warsmith will be able to change only to Maestro.
# Default = False
AllowEntireTree = False
# When character reach levels 20,40,76 he will receive tutorial page
# When character reach levels 20,40,76,85 he will receive tutorial page
# with list of the all possible variants, and can select and immediately
# change to the new occupation, or decide to choose later (on next login).
# Can be used with or without classic Class Masters.

View File

@@ -2,7 +2,8 @@
How may I assist you?<br>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_1stClass">Complete the first class transfer.</Button>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_2ndClass">Complete the second class transfer.</Button>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_3rdClass">Transfer from the second class to the third class.</Button>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_3rdClass">Complete the third class transfer.</Button>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_4thClass">Complete the fourth class transfer.</Button>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_become_noble">Become Noblesse</Button>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_multisell 201">Purchase wearable items</Button>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_increase_clan_level">Raise the clan's level</Button>

View File

@@ -2,7 +2,8 @@
How may I assist you?<br>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_1stClass">Complete the first class transfer.</Button>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_2ndClass">Complete the second class transfer.</Button>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_3rdClass">Transfer from the second class to the third class.</Button>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_3rdClass">Complete the third class transfer.</Button>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_4thClass">Complete the fourth class transfer.</Button>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_become_noble">Become Noblesse</Button>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_multisell 201">Purchase wearable items</Button>
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_increase_clan_level">Raise the clan's level</Button>

View File

@@ -6,5 +6,5 @@ Item(s) required for class change:
%req_items%
</table>
<br><br>
<a action="link COXX">Ask me next time.</a>
<a action="bypass -h AlternateClassMaster close_window">Ask me next time.</a>
</body></html>

View File

@@ -109,6 +109,7 @@ import handlers.admincommandhandlers.AdminTvTEvent;
import handlers.admincommandhandlers.AdminUnblockIp;
import handlers.admincommandhandlers.AdminVitality;
import handlers.admincommandhandlers.AdminZone;
import handlers.bypasshandlers.AlternateClassMaster;
import handlers.bypasshandlers.ArcanCityMovie;
import handlers.bypasshandlers.Augment;
import handlers.bypasshandlers.Buy;
@@ -409,6 +410,7 @@ public class MasterHandler
},
{
// Bypass Handlers
AlternateClassMaster.class,
ArcanCityMovie.class,
Augment.class,
Buy.class,

View File

@@ -0,0 +1,48 @@
/*
* Copyright (C) 2004-2015 L2J DataPack
*
* This file is part of L2J DataPack.
*
* L2J DataPack 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.
*
* L2J DataPack 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 handlers.bypasshandlers;
import com.l2jserver.gameserver.handler.IBypassHandler;
import com.l2jserver.gameserver.model.actor.L2Character;
import com.l2jserver.gameserver.model.actor.instance.L2ClassMasterInstance;
import com.l2jserver.gameserver.model.actor.instance.L2PcInstance;
/**
* @author Mobius
*/
public class AlternateClassMaster implements IBypassHandler
{
private static final String[] COMMANDS =
{
"AlternateClassMaster",
};
@Override
public boolean useBypass(String command, L2PcInstance activeChar, L2Character target)
{
L2ClassMasterInstance.onTutorialLink(activeChar, command);
return false;
}
@Override
public String[] getBypassList()
{
return COMMANDS;
}
}