Merged with released L2J-Unity files.
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
<html><body>Shannon:<br>
|
||||
Did you learn a lot from Evain? Fight off the hordes of scarecrows? Travel to any exotic underground locations? Ha ha ha. You need to learn from the field! Did you learn ANYTHING there?<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 32974-02.html">"I can use shots now... that's pretty cool."</button>
|
||||
<html><body>Shannon:<br>
|
||||
Did you learn a lot from Evain? Fight off the hordes of scarecrows? Travel to any exotic underground locations? Ha ha ha. You need to learn from the field! Did you learn ANYTHING there?<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 32974-02.htm">"I can use shots now... that's pretty cool."</button>
|
||||
</body></html>
|
||||
@@ -1,4 +1,4 @@
|
||||
<html><body>Shannon:<br>
|
||||
Good, then you did learn something...<br>
|
||||
Don't forget! Along with buffs, Soulshots and Spiritshots are important items for battle.
|
||||
<html><body>Shannon:<br>
|
||||
Good, then you did learn something...<br>
|
||||
Don't forget! Along with buffs, Soulshots and Spiritshots are important items for battle.
|
||||
</body></html>
|
||||
@@ -1,4 +1,4 @@
|
||||
<html><body>Shannon:<br>
|
||||
You're wasting my time! Talk to me when you have something to say!<br>
|
||||
(Only characters of level 20 or lower, who have completed the Searching for the Mysterious Power quest, may start this quest)
|
||||
<html><body>Shannon:<br>
|
||||
You're wasting my time! Talk to me when you have something to say!<br>
|
||||
(Only characters of level 20 or lower, who have completed the Searching for the Mysterious Power quest, may start this quest)
|
||||
</body></html>
|
||||
@@ -1,4 +1,4 @@
|
||||
<html><body>Shannon:<br>
|
||||
You're wasting my time! Talk to me when you have something to say!<br>
|
||||
(Only characters of level 20 or lower, who have completed the Searching for the Mysterious Power quest, may start this quest)
|
||||
<html><body>Shannon:<br>
|
||||
You're wasting my time! Talk to me when you have something to say!<br>
|
||||
(Only characters of level 20 or lower, who have completed the Searching for the Mysterious Power quest, may start this quest)
|
||||
</body></html>
|
||||
@@ -1,4 +1,4 @@
|
||||
<html><body>Shannon:<br>
|
||||
You're wasting my time! Talk to me when you have something to say!<br>
|
||||
(You have already completed this quest)
|
||||
<html><body>Shannon:<br>
|
||||
You're wasting my time! Talk to me when you have something to say!<br>
|
||||
(You have already completed this quest)
|
||||
</body></html>
|
||||
@@ -1,4 +1,4 @@
|
||||
<html><body>Holden:<br>
|
||||
Evain sent you? That means you only had practice against a dummy. That's not enough. Wouldn't you agree that your training will only be effective if you train as if it were real combat?<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 33194-02.html">"Sound reasonable."</button>
|
||||
<html><body>Holden:<br>
|
||||
Evain sent you? That means you only had practice against a dummy. That's not enough. Wouldn't you agree that your training will only be effective if you train as if it were real combat?<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 33194-02.htm">"Sound reasonable!"</button>
|
||||
</body></html>
|
||||
@@ -1,5 +1,5 @@
|
||||
<html><body>Holden:<br>
|
||||
That's why we made a Training Golem. It's designed to attack you, but it won't be dangerous.<br>
|
||||
Can you show me what you're capable of?<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 33194-03.html">"All right."</button>
|
||||
<html><body>Holden:<br>
|
||||
That's why we made a Training Golem. It's designed to attack you, but won't be dangerous.<br>
|
||||
Can you show me what you're capable of?<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 33194-03.htm">"All right"</button>
|
||||
</body></html>
|
||||
@@ -1,3 +1,3 @@
|
||||
<html><body>Holden:<br>
|
||||
Then let's see. Try to kill the <font color=LEVEL>Training Golem</font> in front of you. Come back after you've killed plenty.<br>
|
||||
<html><body>Holden:<br>
|
||||
Then let's see. Try to kill the <font color=LEVEL>Training Golem</font> in front of you. Come back after you've killed plenty.<br>
|
||||
</body></html>
|
||||
7
trunk/dist/game/data/scripts/quests/Q10323_TrainLikeItsReal/33194-04.htm
vendored
Normal file
7
trunk/dist/game/data/scripts/quests/Q10323_TrainLikeItsReal/33194-04.htm
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
<html><body>Holden:<br>
|
||||
Good job.<br>
|
||||
Good work. But I noticed that there wasn't any light of spirits when you were fighting. Using
|
||||
<font color=LEVEL>Soulshots or Spiritshots</font> will empower you weapons temporarily to deal powerful attacks<br>
|
||||
Do you know how to use Soulshots?<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 33194-05.htm">"No, please tell me."</button>
|
||||
</body></html>
|
||||
@@ -1,3 +0,0 @@
|
||||
<html><body>Holden:<br>
|
||||
The real battle got your tongue? But you've got to overcome it one day. Kill the <font color=LEVEL>Training Golems</font> in front of you. Come back after you've killed plenty.<br>
|
||||
</body></html>
|
||||
7
trunk/dist/game/data/scripts/quests/Q10323_TrainLikeItsReal/33194-05.htm
vendored
Normal file
7
trunk/dist/game/data/scripts/quests/Q10323_TrainLikeItsReal/33194-05.htm
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
<html><body>Holden:<br>
|
||||
You don't? Then why don't you try again with these soulshot I have for you?
|
||||
Open your <font color="LEVEL">Inventory</font>, check for <font color=LEVEL>Soulshots or Spiritshots</font>.<br>
|
||||
Click and Drag</font> Soulshot/Spiritshot into your Shortcut Bar. Right Click the Soulshot/Spiritshot Shortcut Icon to use it automatically.
|
||||
After this, the lights of the spirits will help you every time you attack.<br>
|
||||
Tell me when you have that done.
|
||||
</body></html>
|
||||
@@ -1,6 +0,0 @@
|
||||
<html><body>Holden:<br>
|
||||
Good job.<br>
|
||||
Good work. But I noticed that there wasn't any lights of spirits when you were fighting. Using <font color=LEVEL>Soulshots</font> will empower your weapons temporarily to deal powerful attacks.<br>
|
||||
Do you know how to use Soulshots?<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 33194-07.html">"No, please tell me."</button>
|
||||
</body></html>
|
||||
4
trunk/dist/game/data/scripts/quests/Q10323_TrainLikeItsReal/33194-06.htm
vendored
Normal file
4
trunk/dist/game/data/scripts/quests/Q10323_TrainLikeItsReal/33194-06.htm
vendored
Normal file
@@ -0,0 +1,4 @@
|
||||
<html><body>Holden:<br>
|
||||
Are you ready? Then let's check the power of Soulshots or Spiritshots by fighting one more time. The targets are the <font color=LEVEL>Training Golems</font>.<br>
|
||||
Come back to me after killing plenty.
|
||||
</body></html>
|
||||
@@ -1,6 +0,0 @@
|
||||
<html><body>Holden:<br>
|
||||
Good job.<br>
|
||||
Good work. But I noticed that there wasn't any spirit lights when you were fighting. Using <font color=LEVEL>Spiritshots</font> will empower your weapons temporarily to deal powerful attacks.<br>
|
||||
Do you know how to use Spiritshots?<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 33194-08.html">"No, please tell me."</button>
|
||||
</body></html>
|
||||
@@ -1,5 +1,5 @@
|
||||
<html><body>Holden:<br>
|
||||
You're done. How was it? Isn't it more efficient?
|
||||
Make sure to use what you've learned in battle later.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 33194-14.html">"All right."</button>
|
||||
<html><body>Holden:<br>
|
||||
You're done. How was it? Isn't it more efficient?<br>
|
||||
Make sure to use what you've learned in battle later.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 33194-08.htm">All right</button>
|
||||
</body></html>
|
||||
@@ -1,9 +0,0 @@
|
||||
<html><body>Holden:<br>
|
||||
You don't? Then why don't you try it with this Soulshot I have for you?
|
||||
Open your <font color="LEVEL">Inventory</font> and check for <font color="LEVEL">Soulshots</font>.<br>
|
||||
Also, remember that the <font color="LEVEL">grades of the weapon and the Soulshot have to be the same</font>.<br>
|
||||
Then, check if the Soulshot in the Automatic Soulshot window is activated.<br>
|
||||
You can activate/deactivate by clicking on the icon.<br>
|
||||
It will be very handy from now on when you fight.<br>
|
||||
Tell me when you have that done.
|
||||
</body></html>
|
||||
@@ -1,3 +1,3 @@
|
||||
<html><body>Holden:<br>
|
||||
You're done with me. Now you can report to <font color=LEVEL>Shannon</font> at the <font color=LEVEL>Basic Training Grounds</font>.
|
||||
<html><body>Holden:<br>
|
||||
You're done with me. Now you can report to <font color=LEVEL>Shannon</font> at the Basic Training Grounds.
|
||||
</body></html>
|
||||
@@ -1,6 +0,0 @@
|
||||
<html><body>Holden:<br>
|
||||
You don't? Then why don't you try it with this Spiritshot I have for you?
|
||||
Open your <font color="LEVEL">Inventory</font> and look for <font color="LEVEL">Spiritshots</font>.<br>
|
||||
Click and drag the Spiritshots onto the <font color="LEVEL">Shortcut</font> bar and right click the Spiritshot shortcut icon to <font color="LEVEL">use them automatically</font>.<br>
|
||||
Tell me when you have that done.
|
||||
</body></html>
|
||||
@@ -1,4 +0,0 @@
|
||||
<html><body>Holden:<br>
|
||||
Are you ready? Then let's check the power of <font color=LEVEL>Soulshots</font> by fighting one more time. The targets are the <font color=LEVEL>Training Golems.</font><br>
|
||||
Come back to me after killing plenty.
|
||||
</body></html>
|
||||
@@ -1,4 +0,0 @@
|
||||
<html><body>Holden:<br>
|
||||
Ready? Then let's test your mettle using <font color=LEVEL>Spiritshots</font>. Target the <font color=LEVEL>Training Golems</font> and fire away.<br>
|
||||
Return to me when you've had your fill.
|
||||
</body></html>
|
||||
@@ -1,4 +0,0 @@
|
||||
<html><body>Holden:<br>
|
||||
Check the power of <font color=LEVEL>Soulshots</font> by fighting one more time. The targets are the <font color=LEVEL>Training Golems.</font><br>
|
||||
Come back to me after killing plenty.
|
||||
</body></html>
|
||||
@@ -1,4 +0,0 @@
|
||||
<html><body>Holden:<br>
|
||||
Ready? Then let's test your mettle using <font color=LEVEL>Spiritshots</font>. Target the <font color=LEVEL>Training Golems</font> and fire away.<br>
|
||||
Return to me when you've had your fill.
|
||||
</body></html>
|
||||
@@ -1,3 +0,0 @@
|
||||
<html><body>Holden:<br>
|
||||
I thought I told you. You're done. Now you can report to <font color=LEVEL>Shannon</font> at the <font color=LEVEL>Basic Training Grounds</font>.
|
||||
</body></html>
|
||||
@@ -1,4 +1,4 @@
|
||||
<html><body>Evain:<br>
|
||||
Looks like you understand the basics behind buffs. Now it's time to get some real combat experience. Ready?<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 33464-02.htm">"Ready!"</button>
|
||||
<html><body>Evain:<br>
|
||||
Looks like you understand the basics behind buffs. Now it's time to get some real combat experience. Ready?<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 33464-02.htm">Ready!</button>
|
||||
</body></html>
|
||||
@@ -1,6 +1,6 @@
|
||||
<html><body>Evain:<br>
|
||||
Good. After all, a dummy is an easy opponent.<br>
|
||||
We wanted to prepare something a little more challenging for you. You know, something that actually moves?<br>
|
||||
This training is to prepare you for battle, not to knock down straw dolls.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 33464-03.htm">"Give me the task."</button>
|
||||
<html><body>Evain:<br>
|
||||
Good. After all, a dummy is an easy opponent.<br>
|
||||
We wanted to prepare something a little more challenging for you. You know, something that actually moves?<br>
|
||||
This training is to prepare you for battle, not to knock down straw dolls.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest Q10323_TrainLikeItsReal 33464-03.htm">Give me the task</button>
|
||||
</body></html>
|
||||
@@ -1,4 +1,4 @@
|
||||
<html><body>Evain:<br>
|
||||
No need to hurry. Also, the mission is managed by <font color=LEVEL>Holden</font> at the <font color=LEVEL>Training Grounds Underground Facility Entrance</font>.
|
||||
If you tell him that I sent you, he will give you details.
|
||||
<html><body>Evain:<br>
|
||||
No need to hurry. Also, the mission is managed by <font color=LEVEL>Holden</font> at the <font color=LEVEL>Training Grounds Underground Facility Entrance</font>.
|
||||
If you tell him that I sent you, he will give you details.
|
||||
</body></html>
|
||||
@@ -1,4 +1,4 @@
|
||||
<html><body>Evain:<br>
|
||||
It's good to see you growing stronger with each passing day. Is there something you want from me?<br>
|
||||
(This quest has already been completed)
|
||||
<html><body>Evain:<br>
|
||||
It's good to see you growing stronger with each passing day. Is there something you want from me?<br>
|
||||
(This quest has already been completed)
|
||||
</body></html>
|
||||
@@ -1,5 +0,0 @@
|
||||
<html><body>Evain:<br>
|
||||
Did you forget about your mission.
|
||||
The next mission is managed by <font color=LEVEL>Holden</font> at the <font color=LEVEL>Training Grounds Underground Facility Entrance</font>.
|
||||
If you tell him that I sent you, he will give you details.
|
||||
</body></html>
|
||||
@@ -1,4 +1,4 @@
|
||||
<html><body>Evain:<br>
|
||||
Why did you come here?<br>
|
||||
(Only characters under level 20, who have completed the Looking for Mysterious Power quest, may start this quest)
|
||||
<html><body>Evain:<br>
|
||||
Why did you come here?<br>
|
||||
(Only characters under level 20, who have completed the Looking for Mysterious Power quest, may start this quest)
|
||||
</body></html>
|
||||
@@ -1,3 +0,0 @@
|
||||
<html><body>Evain:<br>
|
||||
If you've defeated all the training Golems, report to <font color=LEVEL>Shannon</font> at the <font color=LEVEL>Basic Training Grounds</font>!
|
||||
</body></html>
|
||||
@@ -1,377 +1,274 @@
|
||||
/*
|
||||
* 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 quests.Q10323_TrainLikeItsReal;
|
||||
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import com.l2jmobius.gameserver.enums.QuestSound;
|
||||
import com.l2jmobius.gameserver.enums.Race;
|
||||
import com.l2jmobius.gameserver.model.actor.L2Npc;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
|
||||
import com.l2jmobius.gameserver.model.holders.ItemHolder;
|
||||
import com.l2jmobius.gameserver.model.holders.NpcLogListHolder;
|
||||
import com.l2jmobius.gameserver.model.quest.Quest;
|
||||
import com.l2jmobius.gameserver.model.quest.QuestState;
|
||||
import com.l2jmobius.gameserver.model.quest.State;
|
||||
import com.l2jmobius.gameserver.network.NpcStringId;
|
||||
import com.l2jmobius.gameserver.network.serverpackets.ExShowScreenMessage;
|
||||
import com.l2jmobius.gameserver.network.serverpackets.TutorialShowHtml;
|
||||
|
||||
import quests.Q10322_SearchingForTheMysteriousPower.Q10322_SearchingForTheMysteriousPower;
|
||||
|
||||
/**
|
||||
* @author Sdw, Gladicek, gyo
|
||||
*/
|
||||
public class Q10323_TrainLikeItsReal extends Quest
|
||||
{
|
||||
// NPC's
|
||||
private static final int EVAIN = 33464;
|
||||
private static final int HOLDEN = 33194;
|
||||
private static final int SHANNON = 32974;
|
||||
// Mobs
|
||||
private static final int TRAINING_GOLEM = 27532;
|
||||
// Misc
|
||||
private static final int TRAINING_GOLEM_REQUIRED = 1;
|
||||
private static final int MAX_LEVEL = 20;
|
||||
// Items
|
||||
private static final ItemHolder SPIRITSHOTS = new ItemHolder(2509, 500);
|
||||
private static final ItemHolder SOULSHOTS = new ItemHolder(1835, 500);
|
||||
|
||||
public Q10323_TrainLikeItsReal()
|
||||
{
|
||||
super(10323, Q10323_TrainLikeItsReal.class.getSimpleName(), "Train Like It's Real");
|
||||
addStartNpc(EVAIN);
|
||||
addTalkId(EVAIN, HOLDEN, SHANNON);
|
||||
addKillId(TRAINING_GOLEM);
|
||||
addCondMaxLevel(MAX_LEVEL, "33464-07.html");
|
||||
addCondCompletedQuest(Q10322_SearchingForTheMysteriousPower.class.getSimpleName(), "33464-07.html");
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onAdvEvent(String event, L2Npc npc, L2PcInstance player)
|
||||
{
|
||||
final QuestState qs = getQuestState(player, false);
|
||||
if (qs == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
String htmltext = null;
|
||||
|
||||
switch (event)
|
||||
{
|
||||
case "33464-02.htm":
|
||||
case "33194-02.html":
|
||||
{
|
||||
htmltext = event;
|
||||
break;
|
||||
}
|
||||
case "showscreen_spiritshot":
|
||||
{
|
||||
showOnScreenMsg(player, NpcStringId.AUTOMATE_SPIRITSHOT_AS_SHOWN_IN_THE_TUTORIAL, ExShowScreenMessage.TOP_CENTER, 4500);
|
||||
break;
|
||||
}
|
||||
case "showscreen_soulshot":
|
||||
{
|
||||
showOnScreenMsg(player, NpcStringId.AUTOMATE_SOULSHOT_AS_SHOWN_IN_THE_TUTORIAL, ExShowScreenMessage.TOP_CENTER, 4500);
|
||||
break;
|
||||
}
|
||||
case "33464-03.htm":
|
||||
{
|
||||
qs.startQuest();
|
||||
htmltext = event;
|
||||
break;
|
||||
}
|
||||
case "33194-03.html":
|
||||
{
|
||||
if (qs.isCond(1))
|
||||
{
|
||||
// show NpcLog dialog trick
|
||||
qs.setCond(3);
|
||||
qs.setCond(2, true);
|
||||
htmltext = event;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "33194-07.html":
|
||||
{
|
||||
if (qs.isCond(3))
|
||||
{
|
||||
qs.setMemoState(0);
|
||||
giveItems(player, SOULSHOTS);
|
||||
showOnScreenMsg(player, NpcStringId.SOULSHOT_HAVE_BEEN_ADDED_TO_YOUR_INVENTORY, ExShowScreenMessage.TOP_CENTER, 4500);
|
||||
startQuestTimer("showscreen_soulshot", 4500, npc, player);
|
||||
player.sendPacket(new TutorialShowHtml(npc.getObjectId(), "..\\L2Text\\QT_003_bullet_01.htm", TutorialShowHtml.LARGE_WINDOW));
|
||||
qs.setCond(4, true);
|
||||
htmltext = event;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "33194-08.html":
|
||||
{
|
||||
if (qs.isCond(3))
|
||||
{
|
||||
qs.setMemoState(0);
|
||||
giveItems(player, SPIRITSHOTS);
|
||||
showOnScreenMsg(player, NpcStringId.SPIRITSHOT_HAVE_BEEN_ADDED_TO_YOUR_INVENTORY, ExShowScreenMessage.TOP_CENTER, 4500);
|
||||
startQuestTimer("showscreen_spiritshot", 4500, npc, player);
|
||||
player.sendPacket(new TutorialShowHtml(npc.getObjectId(), "..\\L2Text\\QT_003_bullet_01.htm", TutorialShowHtml.LARGE_WINDOW));
|
||||
qs.setCond(5, true);
|
||||
htmltext = event;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "33194-14.html":
|
||||
{
|
||||
if (qs.isCond(8))
|
||||
{
|
||||
qs.setCond(9, true);
|
||||
htmltext = event;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "32974-02.html":
|
||||
{
|
||||
if (qs.isCond(9))
|
||||
{
|
||||
addExpAndSp(player, 1700, 5);
|
||||
giveAdena(player, 90, true);
|
||||
qs.exitQuest(false, true);
|
||||
htmltext = event;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
return htmltext;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onTalk(L2Npc npc, L2PcInstance player)
|
||||
{
|
||||
final QuestState qs = getQuestState(player, true);
|
||||
String htmltext = null;
|
||||
|
||||
switch (qs.getState())
|
||||
{
|
||||
case State.CREATED:
|
||||
{
|
||||
switch (npc.getId())
|
||||
{
|
||||
case EVAIN:
|
||||
{
|
||||
htmltext = "33464-01.htm";
|
||||
break;
|
||||
}
|
||||
case SHANNON:
|
||||
{
|
||||
htmltext = "32974-03.html";
|
||||
break;
|
||||
}
|
||||
case HOLDEN:
|
||||
{
|
||||
htmltext = getNoQuestMsg(player);
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case State.STARTED:
|
||||
{
|
||||
if (npc.getId() == EVAIN)
|
||||
{
|
||||
switch (qs.getCond())
|
||||
{
|
||||
case 1:
|
||||
{
|
||||
htmltext = "33464-04.html";
|
||||
break;
|
||||
}
|
||||
case 9:
|
||||
{
|
||||
htmltext = "33464-05.html";
|
||||
break;
|
||||
}
|
||||
default:
|
||||
{
|
||||
htmltext = getNoQuestMsg(player);
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
else if (npc.getId() == HOLDEN)
|
||||
{
|
||||
switch (qs.getCond())
|
||||
{
|
||||
case 1:
|
||||
{
|
||||
htmltext = "33194-01.html";
|
||||
break;
|
||||
}
|
||||
case 2:
|
||||
{
|
||||
htmltext = "33194-04.html";
|
||||
break;
|
||||
}
|
||||
case 3:
|
||||
{
|
||||
// Orc Mystic will get Soulshots
|
||||
if (!player.isMageClass() || (player.getRace() == Race.ORC))
|
||||
{
|
||||
htmltext = "33194-05.html";
|
||||
}
|
||||
else
|
||||
{
|
||||
htmltext = "33194-06.html";
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 4:
|
||||
{
|
||||
htmltext = "33194-09.html";
|
||||
qs.setCond(6, true);
|
||||
break;
|
||||
}
|
||||
case 5:
|
||||
{
|
||||
htmltext = "33194-10.html";
|
||||
qs.setCond(7, true);
|
||||
break;
|
||||
}
|
||||
case 6:
|
||||
{
|
||||
htmltext = "33194-11.html";
|
||||
break;
|
||||
}
|
||||
case 7:
|
||||
{
|
||||
// same text as 33194-10.html
|
||||
htmltext = "33194-12.html";
|
||||
break;
|
||||
}
|
||||
case 8:
|
||||
{
|
||||
htmltext = "33194-13.html";
|
||||
break;
|
||||
}
|
||||
case 9:
|
||||
{
|
||||
htmltext = "33194-15.html";
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
else if (npc.getId() == SHANNON)
|
||||
{
|
||||
if (qs.isCond(9))
|
||||
{
|
||||
htmltext = "32974-01.html";
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
case State.COMPLETED:
|
||||
{
|
||||
switch (npc.getId())
|
||||
{
|
||||
case EVAIN:
|
||||
{
|
||||
htmltext = "33464-06.html";
|
||||
break;
|
||||
}
|
||||
case SHANNON:
|
||||
{
|
||||
htmltext = "32974-05.html";
|
||||
break;
|
||||
}
|
||||
case HOLDEN:
|
||||
{
|
||||
htmltext = getNoQuestMsg(player);
|
||||
break;
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
return htmltext;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onKill(L2Npc npc, L2PcInstance killer, boolean isSummon)
|
||||
{
|
||||
final QuestState qs = getQuestState(killer, false);
|
||||
|
||||
if ((qs != null) && qs.isStarted())
|
||||
{
|
||||
int killedGolem = qs.getMemoState();
|
||||
|
||||
if (qs.isCond(2))
|
||||
{
|
||||
killedGolem++;
|
||||
sendNpcLogList(killer);
|
||||
|
||||
if (killedGolem >= TRAINING_GOLEM_REQUIRED)
|
||||
{
|
||||
qs.setCond(3, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
qs.setMemoState(killedGolem);
|
||||
playSound(killer, QuestSound.ITEMSOUND_QUEST_ITEMGET);
|
||||
}
|
||||
}
|
||||
else if (qs.isCond(6) || qs.isCond(7))
|
||||
{
|
||||
killedGolem++;
|
||||
sendNpcLogList(killer);
|
||||
|
||||
if (killedGolem >= TRAINING_GOLEM_REQUIRED)
|
||||
{
|
||||
qs.setCond(8, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
qs.setMemoState(killedGolem);
|
||||
playSound(killer, QuestSound.ITEMSOUND_QUEST_ITEMGET);
|
||||
}
|
||||
}
|
||||
}
|
||||
return super.onKill(npc, killer, isSummon);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Set<NpcLogListHolder> getNpcLogList(L2PcInstance activeChar)
|
||||
{
|
||||
final QuestState qs = getQuestState(activeChar, false);
|
||||
final Set<NpcLogListHolder> npcLogList = new HashSet<>(1);
|
||||
|
||||
if ((qs != null) && qs.isCond(2))
|
||||
{
|
||||
npcLogList.add(new NpcLogListHolder(NpcStringId.ELIMINATE_THE_TRAINING_GOLEM, qs.getMemoState()));
|
||||
return npcLogList;
|
||||
}
|
||||
else if ((qs != null) && (qs.isCond(6) || qs.isCond(7)))
|
||||
{
|
||||
npcLogList.add(new NpcLogListHolder(NpcStringId.ELIMINATE_THE_TRAINING_GOLEM2, qs.getMemoState()));
|
||||
return npcLogList;
|
||||
}
|
||||
return super.getNpcLogList(activeChar);
|
||||
}
|
||||
}
|
||||
/*
|
||||
* 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 quests.Q10323_TrainLikeItsReal;
|
||||
|
||||
import java.util.HashSet;
|
||||
import java.util.Set;
|
||||
|
||||
import com.l2jmobius.gameserver.enums.QuestSound;
|
||||
import com.l2jmobius.gameserver.model.actor.L2Npc;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
|
||||
import com.l2jmobius.gameserver.model.holders.ItemHolder;
|
||||
import com.l2jmobius.gameserver.model.holders.NpcLogListHolder;
|
||||
import com.l2jmobius.gameserver.model.quest.Quest;
|
||||
import com.l2jmobius.gameserver.model.quest.QuestState;
|
||||
import com.l2jmobius.gameserver.model.quest.State;
|
||||
import com.l2jmobius.gameserver.network.NpcStringId;
|
||||
import com.l2jmobius.gameserver.network.serverpackets.ExShowScreenMessage;
|
||||
import com.l2jmobius.gameserver.network.serverpackets.TutorialShowHtml;
|
||||
|
||||
import quests.Q10322_SearchingForTheMysteriousPower.Q10322_SearchingForTheMysteriousPower;
|
||||
|
||||
/**
|
||||
* Train Like Its Real (10323)
|
||||
* @author Sdw, Gladicek
|
||||
*/
|
||||
public final class Q10323_TrainLikeItsReal extends Quest
|
||||
{
|
||||
// NPCs
|
||||
private static final int EVAIN = 33464;
|
||||
private static final int HOLDEN = 33194;
|
||||
private static final int SHANNON = 32974;
|
||||
private static final int TRAINING_GOLEM = 27532;
|
||||
// Items
|
||||
private static final ItemHolder SPIRITSHOTS = new ItemHolder(2509, 500);
|
||||
private static final ItemHolder SOULSHOTS = new ItemHolder(1835, 500);
|
||||
// Misc
|
||||
private static final int MAX_LEVEL = 20;
|
||||
|
||||
public Q10323_TrainLikeItsReal()
|
||||
{
|
||||
super(10323);
|
||||
addStartNpc(EVAIN);
|
||||
addTalkId(HOLDEN, EVAIN, SHANNON);
|
||||
addKillId(TRAINING_GOLEM);
|
||||
addCondMaxLevel(MAX_LEVEL, "33464-05.htm");
|
||||
addCondCompletedQuest(Q10322_SearchingForTheMysteriousPower.class.getSimpleName(), "33464-05.htm");
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onAdvEvent(String event, L2Npc npc, L2PcInstance player)
|
||||
{
|
||||
final QuestState qs = getQuestState(player, false);
|
||||
if (qs == null)
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
String htmltext = null;
|
||||
|
||||
switch (event)
|
||||
{
|
||||
case "33464-02.htm":
|
||||
case "33194-02.htm":
|
||||
{
|
||||
htmltext = event;
|
||||
break;
|
||||
}
|
||||
case "33464-03.htm":
|
||||
{
|
||||
qs.startQuest();
|
||||
htmltext = event;
|
||||
break;
|
||||
}
|
||||
case "33194-03.htm":
|
||||
{
|
||||
if (qs.isCond(1))
|
||||
{
|
||||
qs.setCond(2, true);
|
||||
htmltext = event;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "33194-05.htm":
|
||||
{
|
||||
if (qs.isCond(3))
|
||||
{
|
||||
qs.setMemoState(0);
|
||||
player.sendPacket(new TutorialShowHtml(npc.getObjectId(), "..\\L2Text\\QT_003_bullet_01.htm", TutorialShowHtml.LARGE_WINDOW));
|
||||
if (player.isMageClass())
|
||||
{
|
||||
giveItems(player, SPIRITSHOTS);
|
||||
showOnScreenMsg(player, NpcStringId.SPIRITSHOT_HAVE_BEEN_ADDED_TO_YOUR_INVENTORY, ExShowScreenMessage.TOP_CENTER, 4500);
|
||||
getTimers().addTimer("SHOW_SCREENMSG", 4500, evnt -> showOnScreenMsg(player, NpcStringId.AUTOMATE_SPIRITSHOT_AS_SHOWN_IN_THE_TUTORIAL, ExShowScreenMessage.TOP_CENTER, 4500));
|
||||
qs.setCond(5, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
giveItems(player, SOULSHOTS);
|
||||
showOnScreenMsg(player, NpcStringId.SOULSHOT_HAVE_BEEN_ADDED_TO_YOUR_INVENTORY, ExShowScreenMessage.TOP_CENTER, 4500);
|
||||
getTimers().addTimer("SHOW_SCREENMSG", 4500, evnt -> showOnScreenMsg(player, NpcStringId.AUTOMATE_SOULSHOT_AS_SHOWN_IN_THE_TUTORIAL, ExShowScreenMessage.TOP_CENTER, 4500));
|
||||
qs.setCond(4, true);
|
||||
}
|
||||
htmltext = event;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "33194-08.htm":
|
||||
{
|
||||
if (qs.isCond(8))
|
||||
{
|
||||
qs.setCond(9, true);
|
||||
htmltext = event;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "32974-02.htm":
|
||||
{
|
||||
if (qs.isCond(9))
|
||||
{
|
||||
addExpAndSp(player, 1700, 5);
|
||||
giveAdena(player, 90, true);
|
||||
qs.exitQuest(false, true);
|
||||
htmltext = event;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
return htmltext;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onTalk(L2Npc npc, L2PcInstance player, boolean isSimulated)
|
||||
{
|
||||
final QuestState qs = getQuestState(player, true);
|
||||
String htmltext = null;
|
||||
|
||||
switch (qs.getState())
|
||||
{
|
||||
case State.CREATED:
|
||||
{
|
||||
if (npc.getId() == EVAIN)
|
||||
{
|
||||
htmltext = "33464-01.htm";
|
||||
}
|
||||
else if (npc.getId() == SHANNON)
|
||||
{
|
||||
htmltext = "32974-03.htm";
|
||||
}
|
||||
break;
|
||||
}
|
||||
case State.STARTED:
|
||||
{
|
||||
if (npc.getId() == EVAIN)
|
||||
{
|
||||
htmltext = "33464-03.htm";
|
||||
}
|
||||
else if (npc.getId() == HOLDEN)
|
||||
{
|
||||
switch (qs.getCond())
|
||||
{
|
||||
case 1:
|
||||
{
|
||||
htmltext = "33194-01.htm";
|
||||
break;
|
||||
}
|
||||
case 3:
|
||||
{
|
||||
htmltext = "33194-04.htm";
|
||||
break;
|
||||
}
|
||||
case 4:
|
||||
{
|
||||
if (!isSimulated)
|
||||
{
|
||||
qs.setCond(6, true);
|
||||
}
|
||||
htmltext = "33194-06.htm";
|
||||
break;
|
||||
}
|
||||
case 5:
|
||||
{
|
||||
if (!isSimulated)
|
||||
{
|
||||
qs.setCond(7, true);
|
||||
}
|
||||
htmltext = "33194-06.htm";
|
||||
break;
|
||||
}
|
||||
case 8:
|
||||
{
|
||||
htmltext = "33194-07.htm";
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if ((npc.getId() == SHANNON) && qs.isCond(9))
|
||||
{
|
||||
htmltext = "32974-01.htm";
|
||||
}
|
||||
break;
|
||||
}
|
||||
case State.COMPLETED:
|
||||
{
|
||||
if (npc.getId() == EVAIN)
|
||||
{
|
||||
htmltext = "33464-04.htm";
|
||||
}
|
||||
else if (npc.getId() == SHANNON)
|
||||
{
|
||||
htmltext = "32974-05.htm";
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
return htmltext;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onKill(L2Npc npc, L2PcInstance killer, boolean isSummon)
|
||||
{
|
||||
final QuestState qs = getQuestState(killer, false);
|
||||
|
||||
if ((qs != null) && qs.isStarted())
|
||||
{
|
||||
if (qs.isCond(2))
|
||||
{
|
||||
qs.setMemoState(1);
|
||||
qs.setCond(3, true);
|
||||
playSound(killer, QuestSound.ITEMSOUND_QUEST_ITEMGET);
|
||||
}
|
||||
else if (qs.isCond(6) || qs.isCond(7))
|
||||
{
|
||||
qs.setMemoState(1);
|
||||
qs.setCond(8, true);
|
||||
playSound(killer, QuestSound.ITEMSOUND_QUEST_ITEMGET);
|
||||
}
|
||||
}
|
||||
return super.onKill(npc, killer, isSummon);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Set<NpcLogListHolder> getNpcLogList(L2PcInstance activeChar)
|
||||
{
|
||||
final QuestState qs = getQuestState(activeChar, false);
|
||||
if (qs != null)
|
||||
{
|
||||
final Set<NpcLogListHolder> npcLogList = new HashSet<>(1);
|
||||
if (qs.isCond(2))
|
||||
{
|
||||
npcLogList.add(new NpcLogListHolder(NpcStringId.ELIMINATE_THE_TRAINING_GOLEM, qs.getMemoState()));
|
||||
}
|
||||
else if (qs.isCond(6) || qs.isCond(7))
|
||||
{
|
||||
npcLogList.add(new NpcLogListHolder(NpcStringId.ELIMINATE_THE_TRAINING_GOLEM2, qs.getMemoState()));
|
||||
}
|
||||
return npcLogList;
|
||||
}
|
||||
return super.getNpcLogList(activeChar);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user