Addition of zones package.
This commit is contained in:
8
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34059-1.htm
vendored
Normal file
8
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34059-1.htm
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
<html><body>Aden Vanguard Barton:<br>
|
||||
Who are you! Identify yourself!<br>
|
||||
Well, you don't look like the enemy. What brings you to this dangerous place? <br>
|
||||
Have you come after hearing that the Aden Vanguard has secured strongholds in the Atelia Fortress? What? I wasn't captured. It's called infiltration. Hmph.<br>
|
||||
Anyway thanks to you and your friends we were to secure this stronghold, so I should reward you.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest AteliaStatus give_tp_st_1">"Thanks."</Button>
|
||||
<Button ALIGN=LEFT ICON="QUEST" action="bypass -h npc_%objectId%_Quest">Quest</Button>
|
||||
</body></html>
|
6
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34059-2.htm
vendored
Normal file
6
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34059-2.htm
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
<html><body>Aden Vanguard Barton:<br>
|
||||
Although this place is the closest to the entrance, you still have to face many Embryo on the way here.<br>
|
||||
Elikia heard of the situation and made this Teleport Device for us. If you'll be staying for a while, it will be very useful.<br>
|
||||
But I heard that it only works for 24 hours, since it's not perfect. Still, you should find it useful.<br>If you come back tomorrow, I'll prepare a new one for you.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h tutorial_close">"Thanks."</Button>
|
||||
</body></html>
|
8
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34060-1.htm
vendored
Normal file
8
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34060-1.htm
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
<html><body>Aden Vanguard Hayuk:<br>
|
||||
Who are you! Identify yourself!<br>
|
||||
Well, you don't look like the enemy. What brings you to this dangerous place? <br>
|
||||
Have you come after hearing that the Aden Vanguard has secured strongholds in the Atelia Fortress? What? I wasn't captured. It's called infiltration. Hmph.<br>
|
||||
Anyway thanks to you and your friends we were to secure this stronghold, so I should reward you.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest AteliaStatus give_tp_st_2">"Thanks."</Button>
|
||||
<Button ALIGN=LEFT ICON="QUEST" action="bypass -h npc_%objectId%_Quest">Quest</Button>
|
||||
</body></html>
|
6
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34060-2.htm
vendored
Normal file
6
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34060-2.htm
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
<html><body>Aden Vanguard Hayuk:<br>
|
||||
Although this place is the closest to the entrance, you still have to face many Embryo on the way here.<br>
|
||||
Elikia heard of the situation and made this Teleport Device for us. If you'll be staying for a while, it will be very useful.<br>
|
||||
But I heard that it only works for 24 hours, since it's not perfect. Still, you should find it useful.<br>If you come back tomorrow, I'll prepare a new one for you.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h tutorial_close">"Thanks."</Button>
|
||||
</body></html>
|
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34061-1.htm
vendored
Normal file
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34061-1.htm
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
<html><body>Aden Vanguard Elise:<br>
|
||||
Who are you? Oh, you are not the enemy. I'm sorry. This place is just so dangerous...<br>
|
||||
What brings you here? I've come to secure this stronghold. I've just been hiding away, since the resistance of the Embryo has gotten worse.<br>
|
||||
I know you've helped me here, so I'll reward you for that.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest AteliaStatus give_tp_st_3">"Thanks."</Button>
|
||||
<Button ALIGN=LEFT ICON="QUEST" action="bypass -h npc_%objectId%_Quest">Quest</Button>
|
||||
</body></html>
|
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34061-2.htm
vendored
Normal file
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34061-2.htm
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
<html><body>Aden Vanguard Elise:<br>
|
||||
You can use this Teleport Device to teleport near this stronghold. Impressing, right?<br>
|
||||
It was made by Elikia. It will be useful if you'll be staying around for a while. Here, take it.<br>
|
||||
Elikia did say that the device doesn't last long. He said it lasts for 24 hours...<br>
|
||||
But if you come back tomorrow, I'll have another one ready for you.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h tutorial_close">"Thanks."</Button>
|
||||
</body></html>
|
9
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34062-1.htm
vendored
Normal file
9
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34062-1.htm
vendored
Normal file
@@ -0,0 +1,9 @@
|
||||
<html><body>Aden Vanguard Eliyah:<br>
|
||||
Who are you? Do you want to experience the wrath of my spirit?<br>
|
||||
Hmm... You don't look like the enemy. Be glad. You would've been beat to death by my spirits.<br>
|
||||
I'm busy protecting this stronghold. What do you want? I've been taking a break, since the Embryo are so scared of me and have been trying to escape.<br>
|
||||
Well, since you helped me regain the stronghold, I'll give you a little something.<br>
|
||||
Anyway thanks to you and your friends we were to secure this stronghold, so I should reward you.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest AteliaStatus give_tp_st_4">"Thanks."</Button>
|
||||
<Button ALIGN=LEFT ICON="QUEST" action="bypass -h npc_%objectId%_Quest">Quest</Button>
|
||||
</body></html>
|
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34062-2.htm
vendored
Normal file
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34062-2.htm
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
<html><body>Aden Vanguard Eliyah:<br>
|
||||
This is a device that lets you teleport to Stronghold IV very easily.<br>
|
||||
This was made by Elikia. It will be very useful if you'll be staying here for a while.<br>
|
||||
Just remember that the device lasts for 24 hours, since this place is very unstable.<br>
|
||||
If you need it again, come back tomorrow. I'll give you a new one.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h tutorial_close">"Thanks."</Button>
|
||||
</body></html>
|
6
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34063-1.htm
vendored
Normal file
6
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34063-1.htm
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
<html><body>Blackbird Clan Member Glenkinchie:<br>
|
||||
Who are you? I'm Glenkinchie from the honorable Blackbird clan.<br>
|
||||
Those vicious Embryos are up to something in the Atelia Fortress. They are still within our sight, but we are having a hard time infiltrating the Command Post on the 3rd floor. <br>
|
||||
But I don't mind working this hard for Leona. Don't you agree?<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest AteliaStatus 34063-2.htm">"Tell me about the Command Post."</Button><Button ALIGN=LEFT ICON="QUEST" action="bypass -h npc_%objectId%_Quest">Quest</Button>
|
||||
</body></html>
|
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34063-2.htm
vendored
Normal file
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34063-2.htm
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
<html><body>Blackbird Clan Member Glenkinchie:<br>
|
||||
The <font color="LEVEL">Command Post</font> is known to be the place where new soldiers are trained. We don't know what kind of soldiers they are creating, though.<br>
|
||||
What we do know is that the gate opens when <font color="LEVEL">Burnstein</font> <font color="LEVEL">comes out and goes back inside the Command Post</font>. Since the gate rarely opens, it's hard for us to go inside the investigate.<br>
|
||||
That's why we asked Devianne for help to hold the gate open.<br>
|
||||
The only way we can get inside is by having <font color="LEVEL">Devianne</font>, who is hiding near the <font color="LEVEL">entrance to the Command Post</font>, hold the gate open when Burnstein goes back inside.<br>
|
||||
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Back</Button>
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34064-1.htm
vendored
Normal file
5
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34064-1.htm
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
<html><body>Blackbird Clan Member Hurak:<br>
|
||||
I trust Leona, but that doesn't mean I trust everyone easily.<br>
|
||||
I can't believe I fell for such a simple trick. You should be careful too. Things are just getting started...<br>They've even created a command post within the fortress, so we have to put our guard up.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest AteliaStatus 34064-2.htm">"Tell me about the Command Post."</Button><Button ALIGN=LEFT ICON="QUEST" action="bypass -h npc_%objectId%_Quest">Quest</Button>
|
||||
</body></html>
|
6
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34064-2.htm
vendored
Normal file
6
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34064-2.htm
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
<html><body>Blackbird Clan Member Hurak:<br>
|
||||
The Embryo are training their new recruits in the <font color="LEVEL">Command Post</font>.
|
||||
The security is so tight, that going inside is hard in itself.<br>The one way to go in is when <font color="LEVEL">Burnstein</font> comes out and <font color="LEVEL">tries to go back inside the Command Post</font>. We have our own method to do that.<br>
|
||||
<font color="LEVEL">Devianne</font> is hiding near the <font color="LEVEL">entrance to the Command Post</font> on the 3rd floor, to hold the gate open whenever Burnstein goes back inside. It should be helpful when you are trying to go inside.<br>
|
||||
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Back</Button>
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34065-1.htm
vendored
Normal file
5
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34065-1.htm
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
<html><body>Blackbird Clan Member Laffian:<br>
|
||||
I trust Leona, but that doesn't mean I trust everyone easily.<br>
|
||||
I can't believe I fell for such a simple trick. You should be careful too. Things are just getting started...<br>They've even created a command post within the fortress, so we have to put our guard up.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest AteliaStatus 34065-2.htm">"Tell me about the Command Post."</Button><Button ALIGN=LEFT ICON="QUEST" action="bypass -h npc_%objectId%_Quest">Quest</Button>
|
||||
</body></html>
|
6
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34065-2.htm
vendored
Normal file
6
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34065-2.htm
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
<html><body>Blackbird Clan Member Laffian:<br>
|
||||
The Embryo are training their new recruits in the <font color="LEVEL">Command Post</font>.
|
||||
The security is so tight, that going inside is hard in itself.<br>The one way to go in is when <font color="LEVEL">Burnstein</font> comes out and <font color="LEVEL">tries to go back inside the Command Post</font>. We have our own method to do that.<br>
|
||||
<font color="LEVEL">Devianne</font> is hiding near the <font color="LEVEL">entrance to the Command Post</font> on the 3rd floor, to hold the gate open whenever Burnstein goes back inside. It should be helpful when you are trying to go inside.<br>
|
||||
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Back</Button>
|
||||
</body></html>
|
5
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34066-1.htm
vendored
Normal file
5
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34066-1.htm
vendored
Normal file
@@ -0,0 +1,5 @@
|
||||
<html><body>Blackbird Clan Member Sherry:<br>
|
||||
Oh! Who are you?<br>This place is dangerous!<br>
|
||||
Stay away. The Embryo have built a Command Post and are increasing their power day by day.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest AteliaStatus 34066-2.htm">"Tell me about the Command Post."</Button><Button ALIGN=LEFT ICON="QUEST" action="bypass -h npc_%objectId%_Quest">Quest</Button>
|
||||
</body></html>
|
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34066-2.htm
vendored
Normal file
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34066-2.htm
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
<html><body>Blackbird Clan Member Sherry:<br>
|
||||
The <font color="LEVEL">Command Post</font> is on the <font color="LEVEL">3rd floor of the Atelia Fortress</font>. <font color="LEVEL">Burnstein</font> is the leader, and it is said that he comes out from time to time to train the new recruits.<br>
|
||||
No one knows what's going on inside, and it's very difficult to go inside because you have to hold the gate when <font color="LEVEL">Commander Burnstein</font> <font color="LEVEL">goes back inside the Command Post from outside</font>.<br>
|
||||
<font color="LEVEL">Devianne</font> has come all the way here, and is hiding near the <font color="LEVEL">entrance to the Command Post</font>, to hold the gate open whenever Burnstein comes and goes back in.<br>
|
||||
If you are trying to go inside the Command Post, go find Devianne.<br>
|
||||
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Back</Button>
|
||||
</body></html>
|
8
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34074-1.htm
vendored
Normal file
8
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34074-1.htm
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
<html><body>Warehouse Keeper Julia:<br>
|
||||
If you have something precious, leave it with me. I'll keep it safe at all costs.<br>
|
||||
Even if this stronghold becomes dangerous, no harm shall be done to your items!<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest AteliaStatus 34074-2.htm">Private warehouse</Button>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest AteliaStatus 34074-3.htm">Clan warehouse</Button>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/g_cube_warehouse001.htm"><font color="LEVEL">Wondrous Cubic</font></Button>
|
||||
<Button ALIGN=LEFT ICON="QUEST" action="bypass -h npc_%objectId%_Quest">Quest</Button>
|
||||
</body></html>
|
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34074-2.htm
vendored
Normal file
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34074-2.htm
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
<html><body>Warehouse Keeper Julia:<br>
|
||||
<center>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_DepositP">Deposit an item. (Private Warehouse)</Button>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_WithdrawP">Withdraw an item. (Private Warehouse)</Button><br>
|
||||
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Return</Button>
|
||||
</center>
|
||||
</body></html>
|
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34074-3.htm
vendored
Normal file
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34074-3.htm
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
<html><body>Warehouse Keeper Julia:<br>
|
||||
<center>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_DepositC" msg="1039">Deposit an item (Clan Warehouse)</Button>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_WithdrawC">Withdraw an item (Clan Warehouse)</Button>
|
||||
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Back</Button>
|
||||
</center>
|
||||
</body></html>
|
8
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34075-1.htm
vendored
Normal file
8
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34075-1.htm
vendored
Normal file
@@ -0,0 +1,8 @@
|
||||
<html><body>Warehouse Keeper Saylem:<br>
|
||||
Hello! I'm Saylem.<br>
|
||||
Do you have any precious freight? Hmm? If you do, then you're in the right place! We, the Steel Door guild, store customer freight for low, low prices! What's more, you can conveniently reclaim the freight anytime, anywhere. Even if this place becomes dangerous, no harm shall be done to your things.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest AteliaStatus 34075-2.htm">Private warehouse</Button>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h Quest AteliaStatus 34075-3.htm">Clan warehouse</Button>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Link common/g_cube_warehouse001.htm"><font color="LEVEL">Wondrous Cubic</font></Button>
|
||||
<Button ALIGN=LEFT ICON="QUEST" action="bypass -h npc_%objectId%_Quest">Quest</Button>
|
||||
</body></html>
|
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34075-2.htm
vendored
Normal file
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34075-2.htm
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
<html><body>Warehouse Keeper Saylem:<br>
|
||||
<center>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_DepositP">Deposit an item. (Private Warehouse)</Button>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_WithdrawP">Withdraw an item. (Private Warehouse)</Button><br>
|
||||
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Return</Button>
|
||||
</center>
|
||||
</body></html>
|
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34075-3.htm
vendored
Normal file
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34075-3.htm
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
<html><body>Warehouse Keeper Saylem:<br>
|
||||
<center>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_DepositC" msg="1039">Deposit an item (Clan Warehouse)</Button>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_WithdrawC">Withdraw an item (Clan Warehouse)</Button>
|
||||
<Button ALIGN=LEFT ICON="RETURN" action="bypass -h npc_%objectId%_Chat 0">Back</Button>
|
||||
</center>
|
||||
</body></html>
|
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34076-1.htm
vendored
Normal file
7
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34076-1.htm
vendored
Normal file
@@ -0,0 +1,7 @@
|
||||
<html><body>Trader Mion:<br>
|
||||
I came to this dangerous place because I thought someone might need my help. If there's anything you need, come to me, okay?<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Buy 3407700">"I want to trade consumables and minerals."</Button>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_exc_multisell 003">"I want to exchange equipment."</Button>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_TerritoryStatus">"Can you tell me about the local lord and tax rate?"</Button>
|
||||
<Button ALIGN=LEFT ICON="QUEST" action="bypass -h npc_%objectId%_Quest">Quest</Button>
|
||||
</body></html>
|
6
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34077-1.htm
vendored
Normal file
6
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/34077-1.htm
vendored
Normal file
@@ -0,0 +1,6 @@
|
||||
<html><body>Nika:<br>
|
||||
Welcome, welcome. What can I help you find?<br>
|
||||
Oh, I've seen you before. You got stuff to do here too? I came because of a request. I'll be here for a while, so come find me any time.<br>
|
||||
<Button ALIGN=LEFT ICON="NORMAL" action="bypass -h npc_%objectId%_Buy 3407700">"I want to trade consumables and minerals."</Button>
|
||||
<Button ALIGN=LEFT ICON="QUEST" action="bypass -h npc_%objectId%_Quest">Quest</Button>
|
||||
</body></html>
|
707
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/AteliaManager.java
vendored
Normal file
707
trunk/dist/game/data/scripts/ai/zones/AteliaFortress/AteliaManager/AteliaManager.java
vendored
Normal file
@@ -0,0 +1,707 @@
|
||||
/*
|
||||
* 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 ai.zones.AteliaFortress.AteliaManager;
|
||||
|
||||
import java.util.ArrayList;
|
||||
|
||||
import com.l2jmobius.gameserver.datatables.SpawnTable;
|
||||
import com.l2jmobius.gameserver.enums.ChatType;
|
||||
import com.l2jmobius.gameserver.enums.QuestSound;
|
||||
import com.l2jmobius.gameserver.model.L2Spawn;
|
||||
import com.l2jmobius.gameserver.model.Location;
|
||||
import com.l2jmobius.gameserver.model.actor.L2Npc;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
|
||||
import com.l2jmobius.gameserver.model.holders.SkillHolder;
|
||||
import com.l2jmobius.gameserver.model.skills.AbnormalType;
|
||||
import com.l2jmobius.gameserver.network.NpcStringId;
|
||||
import com.l2jmobius.gameserver.util.Util;
|
||||
|
||||
import ai.npc.AbstractNpcAI;
|
||||
|
||||
/**
|
||||
* URL https://l2wiki.com/Atelia_Fortress
|
||||
* @author hlwrave, Stayway, Mobius
|
||||
*/
|
||||
final class AteliaManager extends AbstractNpcAI
|
||||
{
|
||||
// Npc Devianne
|
||||
private static final int DEVIANNE = 34089;
|
||||
// Location Devianne
|
||||
private static final Location DEVIANNE_LOC = new Location(-50063, 49439, -1760, 40362);
|
||||
// Door Atelia Fortess Guard
|
||||
private static final int GUARD = 23539;
|
||||
private static final NpcStringId[] ATELIA_MSG =
|
||||
{
|
||||
NpcStringId.HAVE_YOU_SEEN_KELBIM_S_POWER_WE_LL_SHOW_YOU_THE_WRATH_OF_THE_EMBRYO,
|
||||
NpcStringId.I_CAN_FEEL_THE_ENERGY_FROM_THE_ATELIA_FEEL_THE_POWER_OF_KELBIM,
|
||||
NpcStringId.LIONA_AND_THE_LOWLY_SOLDIERS_WILL_BE_BURIED_HERE,
|
||||
NpcStringId.SHOW_THEM_THE_POWER_OF_KELBIM
|
||||
};
|
||||
private static final SkillHolder[] ATELIA_POISON =
|
||||
{
|
||||
new SkillHolder(23653, 2), // Poisonous Atelia
|
||||
new SkillHolder(23653, 3), // Poisonous Atelia
|
||||
new SkillHolder(23653, 4), // Poisonous Atelia
|
||||
};
|
||||
// AI (Hummel,Geork,Burnstein) in Zone
|
||||
private static final SkillHolder SUPPLY_BLOCKADE = new SkillHolder(16526, 1);
|
||||
private static final SkillHolder POOR_EQUIPMENT = new SkillHolder(16542, 2);
|
||||
private static final SkillHolder INDISCEPLINE = new SkillHolder(16542, 3);
|
||||
// Bosses
|
||||
private static final int GEORK = 23586; // Geork
|
||||
private static final int BURNSTEIN = 23587; // Burnstein
|
||||
private static final int HUMMEL = 23588; // Hummel
|
||||
// Npcs Stronghold I
|
||||
private static final int BARTON = 34059; // Barton Aden Vanguard
|
||||
private static final int GLENKI = 34063; // Glenkinchie Blackbird Clan Member
|
||||
// Location Stronghold I
|
||||
private static final Location BARTON_LOC = new Location(-45675, 59130, -2904, 54353);
|
||||
private static final Location GLENKI_LOC = new Location(-45579, 59169, -2904, 55286);
|
||||
// Flag Stronghold I
|
||||
private static final Location FLAG_1_LOC = new Location(-45690, 58901, -2864, 36407);
|
||||
private static final Location FLAG_2_LOC = new Location(-45419, 59066, -2864, 54421);
|
||||
// Npcs Stronghold II
|
||||
private static final int HAYUK = 34060; // Hayuk Aden Vanguard
|
||||
private static final int HURAK = 34064; // Hurak Blackbird Clan Member
|
||||
// Location Stronghold II
|
||||
private static final Location HURAK_LOC = new Location(-41766, 50416, -2032, 54353);//
|
||||
private static final Location HAYUK_LOC = new Location(-41879, 50389, -2032, 55286);//
|
||||
// Flag Stronghold II
|
||||
private static final Location FLAG_3_LOC = new Location(-41962, 50182, -1988, 36407);//
|
||||
private static final Location FLAG_4_LOC = new Location(-41631, 50246, -2001, 54421);//
|
||||
// Npcs Stronghold III
|
||||
private static final int ELISE = 34061; // Elise Aden Vanguard
|
||||
private static final int LAFFIAN = 34065; // Laffian Blackbird Clan Member
|
||||
// Other Stronghold III
|
||||
private static final int JULIA = 34074; // Julia Warehouse Keeper
|
||||
private static final int MION = 34076; // Mion Grocer
|
||||
// Location Stronghold III
|
||||
private static final Location ELISE_LOC = new Location(-44715, 40358, -1416, 29326);
|
||||
private static final Location LAFFIAN_LOC = new Location(-44574, 40318, -1416, 28937);
|
||||
private static final Location JULIA_LOC = new Location(-44603, 40202, -1416, 32350);
|
||||
private static final Location MION_LOC = new Location(-44525, 40430, -1416, 22568);
|
||||
// Flag Stronghold III
|
||||
private static final Location FLAG_5_LOC = new Location(-44778, 40556, -1384, 22322);
|
||||
private static final Location FLAG_6_LOC = new Location(-44860, 40254, -1376, 23239);
|
||||
// Npcs Stronghold IV
|
||||
private static final int ELIYAH = 34062; // Eliyah Aden Vanguard
|
||||
private static final int SHERRY = 34066; // Sherry Blackbird Clan Member
|
||||
// Other Stronghold IV
|
||||
private static final int SAYLEM = 34075; // Saylem Warehouse Keeper
|
||||
private static final int NIKA = 34077; // Nika Grocer
|
||||
// Location Stronghold IV
|
||||
private static final Location ELIYAH_LOC = new Location(-58480, 44000, -1552, 25300);
|
||||
private static final Location SHERRY_LOC = new Location(-58395, 43905, -1552, 28798);
|
||||
private static final Location SAYLEM_LOC = new Location(-58327, 43957, -1552, 25179);
|
||||
private static final Location NIKA_LOC = new Location(-58450, 43843, -1552, 32767);
|
||||
// Flag Stronghold IV
|
||||
private static final Location FLAG_7_LOC = new Location(-58449, 44207, -1512, 20327);
|
||||
private static final Location FLAG_8_LOC = new Location(-58693, 43986, -1520, 17904);
|
||||
// Stages (Floors)
|
||||
private static final int[] FLOOR_MOBS =
|
||||
{
|
||||
23505,
|
||||
23506,
|
||||
23507,
|
||||
23508,
|
||||
23509,
|
||||
23510,
|
||||
23511,
|
||||
23512
|
||||
};
|
||||
private static final int[] ALERT =
|
||||
{
|
||||
23595,
|
||||
23596,
|
||||
23597,
|
||||
23598,
|
||||
23599,
|
||||
23600,
|
||||
23601,
|
||||
23602
|
||||
};
|
||||
// Skills Stages
|
||||
private static final int[] ATELIA_CURSE =
|
||||
{
|
||||
23506,
|
||||
23508,
|
||||
23511,
|
||||
23512
|
||||
};
|
||||
// PART OF BOSS AI
|
||||
private static final int[] SB_GROUP =
|
||||
{
|
||||
23505,
|
||||
23506,
|
||||
23507,
|
||||
23508,
|
||||
23509,
|
||||
23510,
|
||||
23511,
|
||||
23512
|
||||
};
|
||||
static final int[][] FORTESS_SPY =
|
||||
{
|
||||
{
|
||||
23589,
|
||||
-41659,
|
||||
44081,
|
||||
-1448,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-50091,
|
||||
48822,
|
||||
-1760,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-49263,
|
||||
50204,
|
||||
-2400,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-48556,
|
||||
45595,
|
||||
-1768,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-44548,
|
||||
58729,
|
||||
-2928,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-44636,
|
||||
45261,
|
||||
-1528,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-45055,
|
||||
44769,
|
||||
-1544,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-45729,
|
||||
41010,
|
||||
-1512,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-46178,
|
||||
49001,
|
||||
-2400,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-46466,
|
||||
56947,
|
||||
-3184,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-46619,
|
||||
43794,
|
||||
-1560,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-46814,
|
||||
50187,
|
||||
-2376,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-47309,
|
||||
55932,
|
||||
-3184,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-47470,
|
||||
52576,
|
||||
-2392,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-47503,
|
||||
58967,
|
||||
-3192,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-47815,
|
||||
51378,
|
||||
-2400,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-48077,
|
||||
55335,
|
||||
-3160,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-43866,
|
||||
47379,
|
||||
-2048,
|
||||
0
|
||||
},
|
||||
{
|
||||
23589,
|
||||
-43866,
|
||||
47379,
|
||||
-2048,
|
||||
0
|
||||
}
|
||||
|
||||
};
|
||||
// Infusers
|
||||
private static final int INFUSER_1 = 23537;
|
||||
private static final int INFUSER_2 = 23538;
|
||||
// Static Npcs
|
||||
private static final int FLAG = 19594; // Stronghold Flag
|
||||
// Items
|
||||
private static final int TPST_1 = 46146; // Atelia Fortress Stronghold I Teleport Device
|
||||
private static final int TPST_2 = 46147; // Atelia Fortress Stronghold II Teleport Device
|
||||
private static final int TPST_3 = 46148; // Atelia Fortress Stronghold III Teleport Device
|
||||
private static final int TPST_4 = 46149; // Atelia Fortress Stronghold VI Teleport Device
|
||||
// Misc
|
||||
private static int _killCount = 0;
|
||||
// Other
|
||||
private static final int DESPAWN = 1800000; // Time 30 Min
|
||||
private static final int SBCANCEL = 3600000; // Time 1 Hour
|
||||
private static final int DDESPAWN = 10800000; // Time 3 Hour
|
||||
|
||||
static ArrayList<L2Npc> FortessSpawns = new ArrayList<>();
|
||||
|
||||
private AteliaManager()
|
||||
{
|
||||
super(AteliaManager.class.getSimpleName(), "ai/zones/AteliaFortress");
|
||||
addStartNpc(BARTON, GLENKI, HAYUK, HURAK, ELISE, LAFFIAN, JULIA, MION, ELIYAH, SHERRY, SAYLEM, NIKA);
|
||||
addFirstTalkId(BARTON, GLENKI, HAYUK, HURAK, ELISE, LAFFIAN, JULIA, MION, ELIYAH, SHERRY, SAYLEM, NIKA);
|
||||
addTalkId(BARTON, GLENKI, HAYUK, HURAK, ELISE, LAFFIAN, JULIA, MION, ELIYAH, SHERRY, SAYLEM, NIKA);
|
||||
addKillId(FLOOR_MOBS);
|
||||
addKillId(ALERT);
|
||||
addKillId(GEORK, BURNSTEIN, HUMMEL, GUARD, INFUSER_1, INFUSER_2);
|
||||
addSpawnId(BARTON, GLENKI, FLAG, HAYUK, HURAK);
|
||||
addSpawnId(ELISE, LAFFIAN, JULIA, MION);
|
||||
addSpawnId(ELIYAH, SHERRY, SAYLEM, NIKA);
|
||||
addSpawnId(HUMMEL, GEORK, BURNSTEIN, DEVIANNE);
|
||||
addSpawnId(SB_GROUP);
|
||||
addAttackId(ATELIA_CURSE);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onAdvEvent(String event, L2Npc npc, L2PcInstance player)
|
||||
{
|
||||
String htmltext = null;
|
||||
switch (event)
|
||||
{
|
||||
case "34059-1.htm":
|
||||
case "34060-1.htm":
|
||||
case "34061-1.htm":
|
||||
case "34062-1.htm":
|
||||
case "34063-1.htm":
|
||||
case "34063-2.htm":
|
||||
case "34064-1.htm":
|
||||
case "34064-2.htm":
|
||||
case "34065-1.htm":
|
||||
case "34065-2.htm":
|
||||
case "34066-1.htm":
|
||||
case "34066-2.htm":
|
||||
case "34074-1.htm":
|
||||
case "34074-2.htm":
|
||||
case "34074-3.htm":
|
||||
case "34075-1.htm":
|
||||
case "34075-2.htm":
|
||||
case "34075-3.htm":
|
||||
case "34076-1.htm":
|
||||
case "34077-1.htm":
|
||||
{
|
||||
htmltext = event;
|
||||
break;
|
||||
}
|
||||
case "give_tp_st_1":
|
||||
{
|
||||
if (!hasQuestItems(player, TPST_1))
|
||||
{
|
||||
giveItems(player, TPST_1, 1);
|
||||
playSound(player, QuestSound.ITEMSOUND_QUEST_ITEMGET);
|
||||
}
|
||||
else
|
||||
{
|
||||
htmltext = "34059-2.htm"; // fix
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "give_tp_st_2":
|
||||
{
|
||||
if (!hasQuestItems(player, TPST_2))
|
||||
{
|
||||
giveItems(player, TPST_2, 1);
|
||||
playSound(player, QuestSound.ITEMSOUND_QUEST_ITEMGET);
|
||||
}
|
||||
else
|
||||
{
|
||||
htmltext = "34060-2.htm"; // todo off html text
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "give_tp_st_3":
|
||||
{
|
||||
if (!hasQuestItems(player, TPST_3))
|
||||
{
|
||||
giveItems(player, TPST_3, 1);
|
||||
playSound(player, QuestSound.ITEMSOUND_QUEST_ITEMGET);
|
||||
}
|
||||
else
|
||||
{
|
||||
htmltext = "34061-2.htm"; // fix
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "give_tp_st_4":
|
||||
{
|
||||
if (!hasQuestItems(player, TPST_4))
|
||||
{
|
||||
giveItems(player, TPST_4, 1);
|
||||
playSound(player, QuestSound.ITEMSOUND_QUEST_ITEMGET);
|
||||
}
|
||||
else
|
||||
{
|
||||
htmltext = "34062-2.htm"; // fix
|
||||
}
|
||||
break;
|
||||
}
|
||||
// Stronghold's
|
||||
case "SH_1":
|
||||
{
|
||||
if (npc == null)
|
||||
{
|
||||
addSpawn(BARTON, BARTON_LOC, false, DESPAWN);
|
||||
addSpawn(GLENKI, GLENKI_LOC, false, DESPAWN);
|
||||
addSpawn(FLAG, FLAG_1_LOC, false, DESPAWN);
|
||||
addSpawn(FLAG, FLAG_2_LOC, false, DESPAWN);
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "SH_2":
|
||||
{
|
||||
if (npc == null)
|
||||
{
|
||||
addSpawn(HAYUK, HAYUK_LOC, false, DESPAWN);
|
||||
addSpawn(HURAK, HURAK_LOC, false, DESPAWN);
|
||||
addSpawn(FLAG, FLAG_3_LOC, false, DESPAWN);
|
||||
addSpawn(FLAG, FLAG_4_LOC, false, DESPAWN);
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "SH_3":
|
||||
{
|
||||
if (npc == null)
|
||||
{
|
||||
addSpawn(ELISE, ELISE_LOC, false, DESPAWN);
|
||||
addSpawn(LAFFIAN, LAFFIAN_LOC, false, DESPAWN);
|
||||
addSpawn(JULIA, JULIA_LOC, false, DESPAWN);
|
||||
addSpawn(MION, MION_LOC, false, DESPAWN);
|
||||
addSpawn(FLAG, FLAG_5_LOC, false, DESPAWN);
|
||||
addSpawn(FLAG, FLAG_6_LOC, false, DESPAWN);
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "SH_4":
|
||||
{
|
||||
if (npc == null)
|
||||
{
|
||||
addSpawn(ELIYAH, ELIYAH_LOC, false, DESPAWN);
|
||||
addSpawn(SHERRY, SHERRY_LOC, false, DESPAWN);
|
||||
addSpawn(SAYLEM, SAYLEM_LOC, false, DESPAWN);
|
||||
addSpawn(NIKA, NIKA_LOC, false, DESPAWN);
|
||||
addSpawn(FLAG, FLAG_7_LOC, false, DESPAWN);
|
||||
addSpawn(FLAG, FLAG_8_LOC, false, DESPAWN);
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "SB_1":
|
||||
{
|
||||
for (int sb : SB_GROUP)
|
||||
{
|
||||
for (L2Spawn spawn : SpawnTable.getInstance().getSpawns(sb))
|
||||
{
|
||||
for (L2Npc monster : spawn.getSpawnedNpcs())
|
||||
{
|
||||
if ((monster.getZ() <= -2759) && (monster.getZ() >= -3246))
|
||||
{
|
||||
monster.setTarget(monster);
|
||||
monster.doCast(SUPPLY_BLOCKADE.getSkill());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "SB_2":
|
||||
{
|
||||
for (int sb : SB_GROUP)
|
||||
{
|
||||
for (L2Spawn spawn : SpawnTable.getInstance().getSpawns(sb))
|
||||
{
|
||||
for (L2Npc monster : spawn.getSpawnedNpcs())
|
||||
{
|
||||
if ((monster.getZ() <= -2020) && (monster.getZ() >= -2759))
|
||||
{
|
||||
monster.setTarget(monster);
|
||||
monster.doCast(POOR_EQUIPMENT.getSkill());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "SB_3":
|
||||
{
|
||||
for (int sb : SB_GROUP)
|
||||
{
|
||||
for (L2Spawn spawn : SpawnTable.getInstance().getSpawns(sb))
|
||||
{
|
||||
for (L2Npc monster : spawn.getSpawnedNpcs())
|
||||
{
|
||||
if ((monster.getZ() <= -1477) && (monster.getZ() >= -2212)) // need correct!
|
||||
{
|
||||
monster.setTarget(monster);
|
||||
monster.doCast(INDISCEPLINE.getSkill());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "SB_1_C":
|
||||
{
|
||||
for (int sb : SB_GROUP)
|
||||
{
|
||||
for (L2Spawn spawn : SpawnTable.getInstance().getSpawns(sb))
|
||||
{
|
||||
for (L2Npc monster : spawn.getSpawnedNpcs())
|
||||
{
|
||||
monster.getEffectList().stopSkillEffects(true, AbnormalType.ALL_ATTACK_DOWN);
|
||||
monster.stopSkillEffects(true, 16526);
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "SB_2_C":
|
||||
{
|
||||
for (int sb : SB_GROUP)
|
||||
{
|
||||
for (L2Spawn spawn : SpawnTable.getInstance().getSpawns(sb))
|
||||
{
|
||||
for (L2Npc monster : spawn.getSpawnedNpcs())
|
||||
{
|
||||
monster.getEffectList().stopSkillEffects(true, AbnormalType.MAX_HP_DOWN);
|
||||
monster.stopSkillEffects(true, 16542);
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "SB_3_C":
|
||||
{
|
||||
for (int sb : SB_GROUP)
|
||||
{
|
||||
for (L2Spawn spawn : SpawnTable.getInstance().getSpawns(sb))
|
||||
{
|
||||
for (L2Npc monster : spawn.getSpawnedNpcs())
|
||||
{
|
||||
monster.getEffectList().stopSkillEffects(true, AbnormalType.MAX_HP_DOWN);
|
||||
monster.stopSkillEffects(true, 16542);
|
||||
}
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "SPY_CLEAR":
|
||||
{
|
||||
for (L2Npc spawn : FortessSpawns)
|
||||
{
|
||||
if (spawn != null)
|
||||
{
|
||||
spawn.deleteMe();
|
||||
}
|
||||
}
|
||||
FortessSpawns.clear();
|
||||
break;
|
||||
}
|
||||
case "SPY_SPAWN":
|
||||
{
|
||||
for (int[] spawn : FORTESS_SPY)
|
||||
{
|
||||
FortessSpawns.add(addSpawn(spawn[0], spawn[1], spawn[2], spawn[3], spawn[4], false, 0, false, 0));
|
||||
}
|
||||
break;
|
||||
}
|
||||
case "DOOR_CLOSE":
|
||||
{
|
||||
_killCount = 0;
|
||||
closeDoor(18190002, 0);
|
||||
closeDoor(18190004, 0);
|
||||
break;
|
||||
}
|
||||
case "ALERT":
|
||||
{
|
||||
final int rnd = getRandom(3, 4);
|
||||
for (int i = 0; i < rnd; i++)
|
||||
{
|
||||
final L2Npc alert = addSpawn(ALERT[i], npc.getX() + 10, npc.getY() + 10, npc.getZ() + 10, npc.getHeading(), false, 0, false);
|
||||
alert.setTitle("On Alert Stage 1");
|
||||
addAttackDesire(alert, player);
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
return htmltext;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onAttack(L2Npc npc, L2PcInstance attacker, int damage, boolean isSummon)
|
||||
{
|
||||
final int chance = getRandom(1000);
|
||||
if (Util.contains(ATELIA_CURSE, npc.getId()))
|
||||
{
|
||||
if (!npc.isCastingNow() && (chance <= 20))
|
||||
{
|
||||
npc.setTarget(attacker);
|
||||
npc.doCast(ATELIA_POISON[getRandom(ATELIA_POISON.length)].getSkill());
|
||||
}
|
||||
}
|
||||
else if (Util.contains(FLOOR_MOBS, npc.getId()) && (chance > 90))
|
||||
{
|
||||
broadcastNpcSay(npc, ChatType.NPC_GENERAL, ATELIA_MSG[getRandom(1)], attacker.getName());
|
||||
}
|
||||
return super.onAttack(npc, attacker, damage, isSummon);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onKill(L2Npc npc, L2PcInstance killer, boolean isSummon)
|
||||
{
|
||||
|
||||
if ((npc.getZ() <= -2804) && (npc.getZ() >= -2999) && (npc.getId() == INFUSER_1))
|
||||
{
|
||||
startQuestTimer("SH_1", 100, null, null);
|
||||
}
|
||||
if ((npc.getZ() <= -2029) && (npc.getZ() >= -2050) && (npc.getId() == INFUSER_1))
|
||||
{
|
||||
startQuestTimer("SH_2", 100, null, null);
|
||||
}
|
||||
if ((npc.getZ() <= -1419) && (npc.getZ() >= -1520) && (npc.getId() == INFUSER_2))
|
||||
{
|
||||
startQuestTimer("SH_3", 100, null, null);
|
||||
}
|
||||
if ((npc.getZ() <= -1552) && (npc.getZ() >= -1580) && (npc.getId() == INFUSER_2))
|
||||
{
|
||||
startQuestTimer("SH_4", 100, null, null);
|
||||
}
|
||||
if (npc.getId() == GUARD)
|
||||
{
|
||||
_killCount++;
|
||||
if (_killCount == 2)
|
||||
{
|
||||
openDoor(18190002, 0);
|
||||
openDoor(18190004, 0);
|
||||
startQuestTimer("DOOR_CLOSE", SBCANCEL, npc, killer);
|
||||
}
|
||||
}
|
||||
else if (npc.getId() == HUMMEL)
|
||||
{
|
||||
startQuestTimer("SB_1", 100, npc, killer);
|
||||
}
|
||||
else if (npc.getId() == GEORK)
|
||||
{
|
||||
startQuestTimer("SB_2", 100, npc, killer);
|
||||
}
|
||||
else if (npc.getId() == BURNSTEIN)
|
||||
{
|
||||
addSpawn(DEVIANNE, DEVIANNE_LOC, false, DDESPAWN);
|
||||
startQuestTimer("SPY_CLEAR", 100, npc, null);
|
||||
startQuestTimer("SB_3", 100, npc, killer);
|
||||
}
|
||||
else if (Util.contains(FLOOR_MOBS, npc.getId()) && (getRandom(100) <= 6))
|
||||
{
|
||||
startQuestTimer("ALERT", 100, npc, killer);
|
||||
}
|
||||
return super.onKill(npc, killer, isSummon);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onFirstTalk(L2Npc npc, L2PcInstance player)
|
||||
{
|
||||
return npc.getId() + "-1.htm";
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onSpawn(L2Npc npc)
|
||||
{
|
||||
switch (npc.getId())
|
||||
{
|
||||
case HUMMEL:
|
||||
{
|
||||
startQuestTimer("SB_1_C", 100, npc, null);
|
||||
break;
|
||||
}
|
||||
case GEORK:
|
||||
{
|
||||
startQuestTimer("SB_2_C", 100, npc, null);
|
||||
break;
|
||||
}
|
||||
case BURNSTEIN:
|
||||
{
|
||||
startQuestTimer("SB_3_C", 100, npc, null);
|
||||
startQuestTimer("SPY_SPAWN", 100, npc, null);
|
||||
break;
|
||||
}
|
||||
}
|
||||
return super.onSpawn(npc);
|
||||
}
|
||||
|
||||
public static void main(String[] args)
|
||||
{
|
||||
new AteliaManager();
|
||||
}
|
||||
}
|
105
trunk/dist/game/data/scripts/ai/zones/FantasyIsle/HandysBlockCheckerEvent.java
vendored
Normal file
105
trunk/dist/game/data/scripts/ai/zones/FantasyIsle/HandysBlockCheckerEvent.java
vendored
Normal file
@@ -0,0 +1,105 @@
|
||||
/*
|
||||
* 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 ai.zones.FantasyIsle;
|
||||
|
||||
import com.l2jmobius.Config;
|
||||
import com.l2jmobius.gameserver.instancemanager.HandysBlockCheckerManager;
|
||||
import com.l2jmobius.gameserver.model.ArenaParticipantsHolder;
|
||||
import com.l2jmobius.gameserver.model.actor.L2Npc;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
|
||||
import com.l2jmobius.gameserver.model.quest.Quest;
|
||||
import com.l2jmobius.gameserver.network.SystemMessageId;
|
||||
import com.l2jmobius.gameserver.network.serverpackets.ExCubeGameChangeTimeToStart;
|
||||
import com.l2jmobius.gameserver.network.serverpackets.ExCubeGameRequestReady;
|
||||
import com.l2jmobius.gameserver.network.serverpackets.ExCubeGameTeamList;
|
||||
|
||||
/**
|
||||
* Handys Block Checker Event AI.
|
||||
* @authors BiggBoss, Gigiikun
|
||||
*/
|
||||
final class HandysBlockCheckerEvent extends Quest
|
||||
{
|
||||
// Arena Managers
|
||||
private static final int A_MANAGER_1 = 32521;
|
||||
private static final int A_MANAGER_2 = 32522;
|
||||
private static final int A_MANAGER_3 = 32523;
|
||||
private static final int A_MANAGER_4 = 32524;
|
||||
|
||||
public HandysBlockCheckerEvent()
|
||||
{
|
||||
super(-1, HandysBlockCheckerEvent.class.getSimpleName(), "Handy's Block Checker Event");
|
||||
addFirstTalkId(A_MANAGER_1, A_MANAGER_2, A_MANAGER_3, A_MANAGER_4);
|
||||
HandysBlockCheckerManager.getInstance().startUpParticipantsQueue();
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onFirstTalk(L2Npc npc, L2PcInstance player)
|
||||
{
|
||||
if ((npc == null) || (player == null))
|
||||
{
|
||||
return null;
|
||||
}
|
||||
|
||||
final int arena = npc.getId() - A_MANAGER_1;
|
||||
if (eventIsFull(arena))
|
||||
{
|
||||
player.sendPacket(SystemMessageId.YOU_CANNOT_REGISTER_BECAUSE_CAPACITY_HAS_BEEN_EXCEEDED);
|
||||
return null;
|
||||
}
|
||||
|
||||
if (HandysBlockCheckerManager.getInstance().arenaIsBeingUsed(arena))
|
||||
{
|
||||
player.sendPacket(SystemMessageId.THE_MATCH_IS_BEING_PREPARED_PLEASE_TRY_AGAIN_LATER);
|
||||
return null;
|
||||
}
|
||||
|
||||
if (HandysBlockCheckerManager.getInstance().addPlayerToArena(player, arena))
|
||||
{
|
||||
final ArenaParticipantsHolder holder = HandysBlockCheckerManager.getInstance().getHolder(arena);
|
||||
|
||||
final ExCubeGameTeamList tl = new ExCubeGameTeamList(holder.getRedPlayers(), holder.getBluePlayers(), arena);
|
||||
|
||||
player.sendPacket(tl);
|
||||
|
||||
if ((holder.getBlueTeamSize() >= Config.MIN_BLOCK_CHECKER_TEAM_MEMBERS) && (holder.getRedTeamSize() >= Config.MIN_BLOCK_CHECKER_TEAM_MEMBERS))
|
||||
{
|
||||
holder.updateEvent();
|
||||
holder.broadCastPacketToTeam(new ExCubeGameRequestReady());
|
||||
holder.broadCastPacketToTeam(new ExCubeGameChangeTimeToStart(10));
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
private boolean eventIsFull(int arena)
|
||||
{
|
||||
return HandysBlockCheckerManager.getInstance().getHolder(arena).getAllPlayers().size() == 12;
|
||||
}
|
||||
|
||||
public static void main(String[] args)
|
||||
{
|
||||
if (Config.ENABLE_BLOCK_CHECKER_EVENT)
|
||||
{
|
||||
new HandysBlockCheckerEvent();
|
||||
_log.info("Handy's Block Checker Event is enabled");
|
||||
}
|
||||
else
|
||||
{
|
||||
_log.info("Handy's Block Checker Event is disabled");
|
||||
}
|
||||
}
|
||||
}
|
261
trunk/dist/game/data/scripts/ai/zones/FantasyIsle/Parade.java
vendored
Normal file
261
trunk/dist/game/data/scripts/ai/zones/FantasyIsle/Parade.java
vendored
Normal file
@@ -0,0 +1,261 @@
|
||||
/*
|
||||
* 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 ai.zones.FantasyIsle;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.concurrent.CopyOnWriteArrayList;
|
||||
import java.util.concurrent.ScheduledFuture;
|
||||
|
||||
import com.l2jmobius.gameserver.GameTimeController;
|
||||
import com.l2jmobius.gameserver.ThreadPoolManager;
|
||||
import com.l2jmobius.gameserver.ai.CtrlIntention;
|
||||
import com.l2jmobius.gameserver.model.Location;
|
||||
import com.l2jmobius.gameserver.model.actor.L2Npc;
|
||||
|
||||
import ai.npc.AbstractNpcAI;
|
||||
|
||||
/**
|
||||
* Fantasy Isle Parade
|
||||
* @author JOJO, Pandragon
|
||||
*/
|
||||
final class Parade extends AbstractNpcAI
|
||||
{
|
||||
// @formatter:off
|
||||
final int[] ACTORS =
|
||||
{
|
||||
32379, 0, 32379,
|
||||
32379, 0, 32379,
|
||||
32379, 0, 32379,
|
||||
0, 0, 0,
|
||||
32380, 0, 32380,
|
||||
32380, 32381, 32380,
|
||||
32380, 0, 32380,
|
||||
32380, 32381, 32380,
|
||||
0, 0, 0,
|
||||
32382, 32382, 32382,
|
||||
32382, 32383, 32382,
|
||||
32383, 32384, 32383,
|
||||
32383, 32384, 32383,
|
||||
0, 0, 0,
|
||||
0, 32385, 0,
|
||||
32385, 0, 32385,
|
||||
0, 32385, 0,
|
||||
0, 0, 0,
|
||||
32412, 0, 32411,
|
||||
0, 0, 0,
|
||||
32421, 0, 32409,
|
||||
32423, 0, 32422,
|
||||
0, 0, 0,
|
||||
32420, 32419, 32417,
|
||||
32418, 0, 32416,
|
||||
0, 0, 0,
|
||||
32414, 0, 32414,
|
||||
0, 32413, 0,
|
||||
32414, 0, 32414,
|
||||
0, 0, 0,
|
||||
32393, 0, 32394,
|
||||
0, 32430, 0,
|
||||
32392, 0, 32391,
|
||||
0, 0, 0,
|
||||
0, 32404, 0,
|
||||
32403, 0, 32401,
|
||||
0, 0, 0,
|
||||
0, 32408, 0,
|
||||
32406, 0, 32407,
|
||||
0, 32405, 0,
|
||||
0, 0, 0,
|
||||
32390, 32389, 32387,
|
||||
32388, 0, 32386,
|
||||
0, 0, 0,
|
||||
0, 32400, 0,
|
||||
32397, 32398, 32396,
|
||||
0, 0, 0,
|
||||
0, 32450, 0,
|
||||
32448, 32449, 32447,
|
||||
0, 0, 0,
|
||||
32380, 0, 32380,
|
||||
32380, 32381, 32380,
|
||||
32380, 0, 32380,
|
||||
32380, 32381, 32380,
|
||||
0, 0, 0,
|
||||
32379, 0, 32379,
|
||||
32379, 0, 32379,
|
||||
32379, 0, 32379,
|
||||
0, 0, 0,
|
||||
0, 32415, 0
|
||||
};
|
||||
|
||||
//(Northbound 270 degrees) Route 1
|
||||
private final int[][] START1 = {{-54780, -56810, -2015, 49152},{-54860, -56810, -2015, 49152},{-54940, -56810, -2015, 49152}};
|
||||
private final int[][] GOAL1 = {{-54780, -57965, -2015, 49152},{-54860, -57965, -2015, 49152},{-54940, -57965, -2015, 49152}};
|
||||
//(Westbound 180 degrees) Route 2
|
||||
private final int[][] START2 = {{-55715, -58900, -2015, 32768},{-55715, -58820, -2015, 32768},{-55715, -58740, -2015, 32768}};
|
||||
private final int[][] GOAL2 = {{-60850, -58900, -2015, 32768},{-60850, -58820, -2015, 32768},{-60850, -58740, -2015, 32768}};
|
||||
//(Southbound 90 degrees) Route 3
|
||||
private final int[][] START3 = {{-61790, -57965, -2015, 16384},{-61710, -57965, -2015, 16384},{-61630, -57965, -2015, 16384}};
|
||||
private final int[][] GOAL3 = {{-61790, -53890, -2116, 16384},{-61710, -53890, -2116, 16384},{-61630, -53890, -2116, 16384}};
|
||||
//(Eastbound 0 degrees) Route 4
|
||||
private final int[][] START4 = {{-60840, -52990, -2108, 0},{-60840, -53070, -2108, 0},{-60840, -53150, -2108, 0}};
|
||||
private final int[][] GOAL4 = {{-58620, -52990, -2015, 0},{-58620, -53070, -2015, 0},{-58620, -53150, -2015, 0}};
|
||||
//(To 315 degrees northeast) Route 5
|
||||
private final int[][] START5 = {{-57233, -53554, -2015, 57344},{-57290, -53610, -2015, 57344},{-57346, -53667, -2015, 57344}};
|
||||
private final int[][] GOAL5 = {{-55338, -55435, -2015, 57344},{-55395, -55491, -2015, 57344},{-55451, -55547, -2015, 57344}};
|
||||
|
||||
final int[][][] START = {START1, START2, START3, START4, START5};
|
||||
final int[][][] GOAL = {GOAL1, GOAL2, GOAL3, GOAL4, GOAL5};
|
||||
// @formatter:on
|
||||
|
||||
int npcIndex;
|
||||
CopyOnWriteArrayList<L2Npc> spawns;
|
||||
ScheduledFuture<?> spawnTask;
|
||||
ScheduledFuture<?> deleteTask;
|
||||
ScheduledFuture<?> cleanTask;
|
||||
|
||||
public Parade()
|
||||
{
|
||||
super(Parade.class.getSimpleName(), "ai/zones/FantasyIsle");
|
||||
|
||||
// Starts at 8:00 and repeats every 6 hours.
|
||||
final long diff = timeLeftMilli(8, 0, 0), cycle = 3600000L;
|
||||
ThreadPoolManager.getInstance().scheduleGeneralAtFixedRate(new Start(), diff, cycle);
|
||||
|
||||
// Test - Starts 3 minutes after server startup and repeats every 20 minutes.
|
||||
// final long diff = timeLeftMilli(8, 0, 0), cycle = 600000L;
|
||||
// ThreadPoolManager.getInstance().scheduleGeneralAtFixedRate(new Start(), 180000L, cycle);
|
||||
|
||||
_log.info("Fantasy Isle: Parade starting at " + new SimpleDateFormat("yyyy/MM/dd HH:mm").format(System.currentTimeMillis() + diff) + " and is scheduled each next " + (cycle / 3600000) + " hours.");
|
||||
}
|
||||
|
||||
void load()
|
||||
{
|
||||
npcIndex = 0;
|
||||
spawns = new CopyOnWriteArrayList<>();
|
||||
}
|
||||
|
||||
void clean()
|
||||
{
|
||||
if (spawns != null)
|
||||
{
|
||||
spawns.forEach(L2Npc::deleteMe);
|
||||
}
|
||||
spawns = null;
|
||||
}
|
||||
|
||||
private long timeLeftMilli(int hh, int mm, int ss)
|
||||
{
|
||||
final int now = (GameTimeController.getInstance().getGameTicks() * 60) / 100;
|
||||
int dd = ((hh * 3600) + (mm * 60) + ss) - (now % 86400);
|
||||
if (dd < 0)
|
||||
{
|
||||
dd += 86400;
|
||||
}
|
||||
|
||||
return (dd * 1000L) / 6L;
|
||||
}
|
||||
|
||||
class Start implements Runnable
|
||||
{
|
||||
@Override
|
||||
public void run()
|
||||
{
|
||||
load();
|
||||
spawnTask = ThreadPoolManager.getInstance().scheduleGeneralAtFixedRate(new Spawn(), 0, 5000);
|
||||
deleteTask = ThreadPoolManager.getInstance().scheduleGeneralAtFixedRate(new Delete(), 10000, 1000);
|
||||
cleanTask = ThreadPoolManager.getInstance().scheduleGeneral(new Clean(), 420000);
|
||||
}
|
||||
}
|
||||
|
||||
class Spawn implements Runnable
|
||||
{
|
||||
@Override
|
||||
public void run()
|
||||
{
|
||||
for (int i = 0; i < 3; ++i)
|
||||
{
|
||||
if (npcIndex >= ACTORS.length)
|
||||
{
|
||||
spawnTask.cancel(false);
|
||||
break;
|
||||
}
|
||||
final int npcId = ACTORS[npcIndex++];
|
||||
if (npcId == 0)
|
||||
{
|
||||
continue;
|
||||
}
|
||||
for (int route = 0; route < 5; ++route)
|
||||
{
|
||||
final int[] start = START[route][i];
|
||||
final int[] goal = GOAL[route][i];
|
||||
final L2Npc actor = addSpawn(npcId, start[0], start[1], start[2], start[3], false, 0);
|
||||
actor.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location(goal[0], goal[1], goal[2], goal[3]));
|
||||
spawns.add(actor);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
class Delete implements Runnable
|
||||
{
|
||||
@Override
|
||||
public void run()
|
||||
{
|
||||
if (spawns.size() <= 0)
|
||||
{
|
||||
return;
|
||||
}
|
||||
for (L2Npc actor : spawns)
|
||||
{
|
||||
if (actor != null)
|
||||
{
|
||||
if (actor.calculateDistance(actor.getXdestination(), actor.getYdestination(), 0, false, true) < (100 * 100))
|
||||
{
|
||||
actor.deleteMe();
|
||||
spawns.remove(actor);
|
||||
}
|
||||
else if (!actor.isMoving())
|
||||
{
|
||||
actor.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location(actor.getXdestination(), actor.getYdestination(), actor.getZdestination(), actor.getHeading()));
|
||||
}
|
||||
}
|
||||
}
|
||||
if (spawns.size() == 0)
|
||||
{
|
||||
deleteTask.cancel(false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
class Clean implements Runnable
|
||||
{
|
||||
@Override
|
||||
public void run()
|
||||
{
|
||||
spawnTask.cancel(false);
|
||||
spawnTask = null;
|
||||
deleteTask.cancel(false);
|
||||
deleteTask = null;
|
||||
cleanTask.cancel(false);
|
||||
cleanTask = null;
|
||||
clean();
|
||||
}
|
||||
}
|
||||
|
||||
public static void main(String[] args)
|
||||
{
|
||||
new Parade();
|
||||
}
|
||||
}
|
523
trunk/dist/game/data/scripts/ai/zones/FantasyIsle/TalentShow.java
vendored
Normal file
523
trunk/dist/game/data/scripts/ai/zones/FantasyIsle/TalentShow.java
vendored
Normal file
@@ -0,0 +1,523 @@
|
||||
/*
|
||||
* 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 ai.zones.FantasyIsle;
|
||||
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.HashMap;
|
||||
import java.util.Map;
|
||||
|
||||
import com.l2jmobius.gameserver.GameTimeController;
|
||||
import com.l2jmobius.gameserver.ai.CtrlIntention;
|
||||
import com.l2jmobius.gameserver.enums.ChatType;
|
||||
import com.l2jmobius.gameserver.model.Location;
|
||||
import com.l2jmobius.gameserver.model.actor.L2Npc;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
|
||||
import com.l2jmobius.gameserver.network.NpcStringId;
|
||||
import com.l2jmobius.gameserver.network.serverpackets.NpcSay;
|
||||
import com.l2jmobius.gameserver.network.serverpackets.PlaySound;
|
||||
|
||||
import ai.npc.AbstractNpcAI;
|
||||
|
||||
/**
|
||||
* Talent Show AI.
|
||||
* @author Kerberos
|
||||
*/
|
||||
final class TalentShow extends AbstractNpcAI
|
||||
{
|
||||
private static int MC = 32433;
|
||||
// @formatter:off
|
||||
private static int[] SINGERS =
|
||||
{
|
||||
32431, 32432
|
||||
};
|
||||
private static int[] CIRCUS =
|
||||
{
|
||||
32442, 32443, 32444, 32445, 32446
|
||||
};
|
||||
private static int[] INDIVIDUALS =
|
||||
{
|
||||
32439, 32440, 32441
|
||||
};
|
||||
private static int[] SHOWSTUFF =
|
||||
{
|
||||
32424, 32425, 32426, 32427, 32428
|
||||
};
|
||||
// @formatter:on
|
||||
private static boolean IS_STARTED = false;
|
||||
private static NpcStringId[] MESSAGES =
|
||||
{
|
||||
NpcStringId.LADIES_AND_GENTLEMEN_THE_SHOW_IS_ABOUT_TO_BEGIN,
|
||||
NpcStringId.MAY_I_HAVE_YOUR_ATTENTION_PLEASE,
|
||||
NpcStringId.THANK_YOU_ALL_FOR_COMING_HERE_TONIGHT,
|
||||
NpcStringId.IT_IS_AN_HONOR_TO_HAVE_YOU_ALL_IN_ATTENDANCE_THIS_EVENING,
|
||||
NpcStringId.FANTASY_ISLE_TAKES_GREAT_PRIDE_IN_PROVIDING_THE_VERY_BEST_IN_ENTERTAINMENT,
|
||||
NpcStringId.NOW_I_D_LIKE_TO_INTRODUCE_THE_MOST_BEAUTIFUL_SINGER_IN_ADEN_PLEASE_WELCOME_LEYLA_MIRA,
|
||||
NpcStringId.PERFORMING_HER_LATEST_HIT,
|
||||
NpcStringId.THANK_YOU_VERY_MUCH_LEYLA,
|
||||
NpcStringId.NOW_WE_RE_IN_FOR_A_REAL_TREAT,
|
||||
NpcStringId.JUST_BACK_FROM_THEIR_WORLD_TOUR_PUT_YOUR_HANDS_TOGETHER_FOR_THE_FANTASY_ISLE_CIRCUS,
|
||||
NpcStringId.EVERYONE_GIVE_THEM_A_HAND,
|
||||
NpcStringId.IMPRESSIVE_NO_A_VERY_TALENTED_GROUP,
|
||||
NpcStringId.NOW_WE_HAVE_A_SPECIAL_REQUEST_FROM_SOME_FOLKS_WHO_WISH_TO_PERFORM,
|
||||
NpcStringId.LET_S_WELCOME_OUR_FIRST_VOLUNTEER,
|
||||
NpcStringId.AH,
|
||||
NpcStringId.MOVING_ON_LET_S_WELCOME_OUR_NEXT_VOLUNTEER,
|
||||
NpcStringId.I_M_SURE_THEY_HAVE_SOMETHING_MUCH_MORE_EXCITING,
|
||||
NpcStringId.REALLY,
|
||||
NpcStringId.THAT_WAS_JUST_SUPER_AND_NOW_FOR_OUR_LAST_VOLUNTEER,
|
||||
NpcStringId.SIGH_AND_THAT_S_OUR_SHOW_FOLKS,
|
||||
NpcStringId.I_HOPE_EVERYONE_ENJOYED_THE_SHOW,
|
||||
NpcStringId.PLEASE_REMEMBER_THAT_FANTASY_ISLE_IS_ALWAYS_PLANNING_A_LOT_OF_GREAT_SHOWS_FOR_YOU,
|
||||
NpcStringId.WELL_WE_WISH_WE_COULD_KEEP_THIS_PARTY_GOING_BUT_WE_MUST_TAKE_A_BREAK_THANK_YOU,
|
||||
NpcStringId.WE_LOVE_YOU_ALL
|
||||
};
|
||||
|
||||
private class ShoutInfo
|
||||
{
|
||||
private final NpcStringId _npcStringId;
|
||||
private final String _nextEvent;
|
||||
private final int _time;
|
||||
|
||||
public ShoutInfo(NpcStringId npcStringId, String nextEvent, int time)
|
||||
{
|
||||
_npcStringId = npcStringId;
|
||||
_nextEvent = nextEvent;
|
||||
_time = time;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the _npcStringId
|
||||
*/
|
||||
public NpcStringId getNpcStringId()
|
||||
{
|
||||
return _npcStringId;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the _nextEvent
|
||||
*/
|
||||
public String getNextEvent()
|
||||
{
|
||||
return _nextEvent;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the _time
|
||||
*/
|
||||
public int getTime()
|
||||
{
|
||||
return _time;
|
||||
}
|
||||
}
|
||||
|
||||
private class WalkInfo
|
||||
{
|
||||
private final Location _charPos;
|
||||
private final String _nextEvent;
|
||||
private final int _time;
|
||||
|
||||
public WalkInfo(Location charPos, String nextEvent, int time)
|
||||
{
|
||||
_charPos = charPos;
|
||||
_nextEvent = nextEvent;
|
||||
_time = time;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the _charPos
|
||||
*/
|
||||
public Location getCharPos()
|
||||
{
|
||||
return _charPos;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the _nextEvent
|
||||
*/
|
||||
public String getNextEvent()
|
||||
{
|
||||
return _nextEvent;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the _time
|
||||
*/
|
||||
public int getTime()
|
||||
{
|
||||
return _time;
|
||||
}
|
||||
}
|
||||
|
||||
private static final Map<String, ShoutInfo> TALKS = new HashMap<>();
|
||||
private static final Map<String, WalkInfo> WALKS = new HashMap<>();
|
||||
|
||||
private TalentShow()
|
||||
{
|
||||
super(TalentShow.class.getSimpleName(), "ai/zones/FantasyIsle");
|
||||
addSpawnId(32433, 32431, 32432, 32442, 32443, 32444, 32445, 32446, 32424, 32425, 32426, 32427, 32428);
|
||||
load();
|
||||
scheduleTimer();
|
||||
}
|
||||
|
||||
private void load()
|
||||
{
|
||||
// TODO put this stuff in Routes.xml
|
||||
TALKS.put("1", new ShoutInfo(MESSAGES[1], "2", 1000));
|
||||
TALKS.put("2", new ShoutInfo(MESSAGES[2], "3", 6000));
|
||||
TALKS.put("3", new ShoutInfo(MESSAGES[3], "4", 4000));
|
||||
TALKS.put("4", new ShoutInfo(MESSAGES[4], "5", 5000));
|
||||
TALKS.put("5", new ShoutInfo(MESSAGES[5], "6", 3000));
|
||||
TALKS.put("8", new ShoutInfo(MESSAGES[9], "9", 5000));
|
||||
TALKS.put("9", new ShoutInfo(MESSAGES[10], "10", 5000));
|
||||
TALKS.put("12", new ShoutInfo(MESSAGES[12], "13", 5000));
|
||||
TALKS.put("13", new ShoutInfo(MESSAGES[13], "14", 5000));
|
||||
TALKS.put("15", new ShoutInfo(MESSAGES[14], "16", 5000));
|
||||
TALKS.put("16", new ShoutInfo(MESSAGES[15], "17", 5000));
|
||||
TALKS.put("18", new ShoutInfo(MESSAGES[17], "19", 5000));
|
||||
TALKS.put("19", new ShoutInfo(MESSAGES[18], "20", 5000));
|
||||
TALKS.put("21", new ShoutInfo(MESSAGES[19], "22", 5000));
|
||||
TALKS.put("22", new ShoutInfo(MESSAGES[20], "23", 400));
|
||||
TALKS.put("25", new ShoutInfo(MESSAGES[21], "26", 5000));
|
||||
TALKS.put("26", new ShoutInfo(MESSAGES[22], "27", 5400));
|
||||
|
||||
WALKS.put("npc1_1", new WalkInfo(new Location(-56546, -56384, -2008, 0), "npc1_2", 1200));
|
||||
WALKS.put("npc1_2", new WalkInfo(new Location(-56597, -56384, -2008, 0), "npc1_3", 1200));
|
||||
WALKS.put("npc1_3", new WalkInfo(new Location(-56596, -56428, -2008, 0), "npc1_4", 1200));
|
||||
WALKS.put("npc1_4", new WalkInfo(new Location(-56593, -56474, -2008, 0), "npc1_5", 1000));
|
||||
WALKS.put("npc1_5", new WalkInfo(new Location(-56542, -56474, -2008, 0), "npc1_6", 1000));
|
||||
WALKS.put("npc1_6", new WalkInfo(new Location(-56493, -56473, -2008, 0), "npc1_7", 2000));
|
||||
WALKS.put("npc1_7", new WalkInfo(new Location(-56495, -56425, -2008, 0), "npc1_1", 4000));
|
||||
WALKS.put("npc2_1", new WalkInfo(new Location(-56550, -56291, -2008, 0), "npc2_2", 1200));
|
||||
WALKS.put("npc2_2", new WalkInfo(new Location(-56601, -56293, -2008, 0), "npc2_3", 1200));
|
||||
WALKS.put("npc2_3", new WalkInfo(new Location(-56603, -56247, -2008, 0), "npc2_4", 1200));
|
||||
WALKS.put("npc2_4", new WalkInfo(new Location(-56605, -56203, -2008, 0), "npc2_5", 1000));
|
||||
WALKS.put("npc2_5", new WalkInfo(new Location(-56553, -56202, -2008, 0), "npc2_6", 1100));
|
||||
WALKS.put("npc2_6", new WalkInfo(new Location(-56504, -56200, -2008, 0), "npc2_7", 2000));
|
||||
WALKS.put("npc2_7", new WalkInfo(new Location(-56503, -56243, -2008, 0), "npc2_1", 4000));
|
||||
WALKS.put("npc3_1", new WalkInfo(new Location(-56500, -56290, -2008, 0), "npc3_2", 1200));
|
||||
WALKS.put("npc3_2", new WalkInfo(new Location(-56551, -56313, -2008, 0), "npc3_3", 1200));
|
||||
WALKS.put("npc3_3", new WalkInfo(new Location(-56601, -56293, -2008, 0), "npc3_4", 1200));
|
||||
WALKS.put("npc3_4", new WalkInfo(new Location(-56651, -56294, -2008, 0), "npc3_5", 1200));
|
||||
WALKS.put("npc3_5", new WalkInfo(new Location(-56653, -56250, -2008, 0), "npc3_6", 1200));
|
||||
WALKS.put("npc3_6", new WalkInfo(new Location(-56654, -56204, -2008, 0), "npc3_7", 1200));
|
||||
WALKS.put("npc3_7", new WalkInfo(new Location(-56605, -56203, -2008, 0), "npc3_8", 1200));
|
||||
WALKS.put("npc3_8", new WalkInfo(new Location(-56554, -56202, -2008, 0), "npc3_9", 1200));
|
||||
WALKS.put("npc3_9", new WalkInfo(new Location(-56503, -56200, -2008, 0), "npc3_10", 1200));
|
||||
WALKS.put("npc3_10", new WalkInfo(new Location(-56502, -56244, -2008, 0), "npc3_1", 900));
|
||||
WALKS.put("npc4_1", new WalkInfo(new Location(-56495, -56381, -2008, 0), "npc4_2", 1200));
|
||||
WALKS.put("npc4_2", new WalkInfo(new Location(-56548, -56383, -2008, 0), "npc4_3", 1200));
|
||||
WALKS.put("npc4_3", new WalkInfo(new Location(-56597, -56383, -2008, 0), "npc4_4", 1200));
|
||||
WALKS.put("npc4_4", new WalkInfo(new Location(-56643, -56385, -2008, 0), "npc4_5", 1200));
|
||||
WALKS.put("npc4_5", new WalkInfo(new Location(-56639, -56436, -2008, 0), "npc4_6", 1200));
|
||||
WALKS.put("npc4_6", new WalkInfo(new Location(-56639, -56473, -2008, 0), "npc4_7", 1200));
|
||||
WALKS.put("npc4_7", new WalkInfo(new Location(-56589, -56473, -2008, 0), "npc4_8", 1200));
|
||||
WALKS.put("npc4_8", new WalkInfo(new Location(-56541, -56473, -2008, 0), "npc4_9", 1200));
|
||||
WALKS.put("npc4_9", new WalkInfo(new Location(-56496, -56473, -2008, 0), "npc4_10", 1200));
|
||||
WALKS.put("npc4_10", new WalkInfo(new Location(-56496, -56429, -2008, 0), "npc4_1", 900));
|
||||
WALKS.put("npc5_1", new WalkInfo(new Location(-56549, -56335, -2008, 0), "npc5_2", 1000));
|
||||
WALKS.put("npc5_2", new WalkInfo(new Location(-56599, -56337, -2008, 0), "npc5_3", 2000));
|
||||
WALKS.put("npc5_3", new WalkInfo(new Location(-56649, -56341, -2008, 0), "npc5_4", 26000));
|
||||
WALKS.put("npc5_4", new WalkInfo(new Location(-56600, -56341, -2008, 0), "npc5_5", 1000));
|
||||
WALKS.put("npc5_5", new WalkInfo(new Location(-56553, -56341, -2008, 0), "npc5_6", 1000));
|
||||
WALKS.put("npc5_6", new WalkInfo(new Location(-56508, -56331, -2008, 0), "npc5_2", 8000));
|
||||
WALKS.put("npc6_1", new WalkInfo(new Location(-56595, -56428, -2008, 0), "npc6_2", 1000));
|
||||
WALKS.put("npc6_2", new WalkInfo(new Location(-56596, -56383, -2008, 0), "npc6_3", 1000));
|
||||
WALKS.put("npc6_3", new WalkInfo(new Location(-56648, -56384, -2008, 0), "npc6_4", 1000));
|
||||
WALKS.put("npc6_4", new WalkInfo(new Location(-56645, -56429, -2008, 0), "npc6_5", 1000));
|
||||
WALKS.put("npc6_5", new WalkInfo(new Location(-56644, -56475, -2008, 0), "npc6_6", 1000));
|
||||
WALKS.put("npc6_6", new WalkInfo(new Location(-56595, -56473, -2008, 0), "npc6_7", 1000));
|
||||
WALKS.put("npc6_7", new WalkInfo(new Location(-56542, -56473, -2008, 0), "npc6_8", 1000));
|
||||
WALKS.put("npc6_8", new WalkInfo(new Location(-56492, -56472, -2008, 0), "npc6_9", 1200));
|
||||
WALKS.put("npc6_9", new WalkInfo(new Location(-56495, -56426, -2008, 0), "npc6_10", 2000));
|
||||
WALKS.put("npc6_10", new WalkInfo(new Location(-56540, -56426, -2008, 0), "npc6_1", 3000));
|
||||
WALKS.put("npc7_1", new WalkInfo(new Location(-56603, -56249, -2008, 0), "npc7_2", 1000));
|
||||
WALKS.put("npc7_2", new WalkInfo(new Location(-56601, -56294, -2008, 0), "npc7_3", 1000));
|
||||
WALKS.put("npc7_3", new WalkInfo(new Location(-56651, -56295, -2008, 0), "npc7_4", 1000));
|
||||
WALKS.put("npc7_4", new WalkInfo(new Location(-56653, -56248, -2008, 0), "npc7_5", 1000));
|
||||
WALKS.put("npc7_5", new WalkInfo(new Location(-56605, -56203, -2008, 0), "npc7_6", 1000));
|
||||
WALKS.put("npc7_6", new WalkInfo(new Location(-56554, -56202, -2008, 0), "npc7_7", 1000));
|
||||
WALKS.put("npc7_7", new WalkInfo(new Location(-56504, -56201, -2008, 0), "npc7_8", 1000));
|
||||
WALKS.put("npc7_8", new WalkInfo(new Location(-56502, -56247, -2008, 0), "npc7_9", 1200));
|
||||
WALKS.put("npc7_9", new WalkInfo(new Location(-56549, -56248, -2008, 0), "npc7_10", 2000));
|
||||
WALKS.put("npc7_10", new WalkInfo(new Location(-56549, -56248, -2008, 0), "npc7_1", 3000));
|
||||
WALKS.put("npc8_1", new WalkInfo(new Location(-56493, -56426, -2008, 0), "npc8_2", 1000));
|
||||
WALKS.put("npc8_2", new WalkInfo(new Location(-56497, -56381, -2008, 0), "npc8_3", 1200));
|
||||
WALKS.put("npc8_3", new WalkInfo(new Location(-56544, -56381, -2008, 0), "npc8_4", 1200));
|
||||
WALKS.put("npc8_4", new WalkInfo(new Location(-56596, -56383, -2008, 0), "npc8_5", 1200));
|
||||
WALKS.put("npc8_5", new WalkInfo(new Location(-56594, -56428, -2008, 0), "npc8_6", 900));
|
||||
WALKS.put("npc8_6", new WalkInfo(new Location(-56645, -56429, -2008, 0), "npc8_7", 1200));
|
||||
WALKS.put("npc8_7", new WalkInfo(new Location(-56647, -56384, -2008, 0), "npc8_8", 1200));
|
||||
WALKS.put("npc8_8", new WalkInfo(new Location(-56649, -56362, -2008, 0), "npc8_9", 9200));
|
||||
WALKS.put("npc8_9", new WalkInfo(new Location(-56654, -56429, -2008, 0), "npc8_10", 1200));
|
||||
WALKS.put("npc8_10", new WalkInfo(new Location(-56644, -56474, -2008, 0), "npc8_11", 900));
|
||||
WALKS.put("npc8_11", new WalkInfo(new Location(-56593, -56473, -2008, 0), "npc8_12", 1100));
|
||||
WALKS.put("npc8_12", new WalkInfo(new Location(-56543, -56472, -2008, 0), "npc8_13", 1200));
|
||||
WALKS.put("npc8_13", new WalkInfo(new Location(-56491, -56471, -2008, 0), "npc8_1", 1200));
|
||||
WALKS.put("npc9_1", new WalkInfo(new Location(-56505, -56246, -2008, 0), "npc9_2", 1000));
|
||||
WALKS.put("npc9_2", new WalkInfo(new Location(-56504, -56291, -2008, 0), "npc9_3", 1200));
|
||||
WALKS.put("npc9_3", new WalkInfo(new Location(-56550, -56291, -2008, 0), "npc9_4", 1200));
|
||||
WALKS.put("npc9_4", new WalkInfo(new Location(-56600, -56292, -2008, 0), "npc9_5", 1200));
|
||||
WALKS.put("npc9_5", new WalkInfo(new Location(-56603, -56248, -2008, 0), "npc9_6", 900));
|
||||
WALKS.put("npc9_6", new WalkInfo(new Location(-56653, -56249, -2008, 0), "npc9_7", 1200));
|
||||
WALKS.put("npc9_7", new WalkInfo(new Location(-56651, -56294, -2008, 0), "npc9_8", 1200));
|
||||
WALKS.put("npc9_8", new WalkInfo(new Location(-56650, -56316, -2008, 0), "npc9_9", 9200));
|
||||
WALKS.put("npc9_9", new WalkInfo(new Location(-56660, -56250, -2008, 0), "npc9_10", 1200));
|
||||
WALKS.put("npc9_10", new WalkInfo(new Location(-56656, -56205, -2008, 0), "npc9_11", 900));
|
||||
WALKS.put("npc9_11", new WalkInfo(new Location(-56606, -56204, -2008, 0), "npc9_12", 1100));
|
||||
WALKS.put("npc9_12", new WalkInfo(new Location(-56554, -56203, -2008, 0), "npc9_13", 1200));
|
||||
WALKS.put("npc9_13", new WalkInfo(new Location(-56506, -56203, -2008, 0), "npc9_1", 1200));
|
||||
WALKS.put("24", new WalkInfo(new Location(-56730, -56340, -2008, 0), "25", 1800));
|
||||
WALKS.put("27", new WalkInfo(new Location(-56702, -56340, -2008, 0), "29", 1800));
|
||||
}
|
||||
|
||||
private void scheduleTimer()
|
||||
{
|
||||
final int gameTime = GameTimeController.getInstance().getGameTime();
|
||||
final int hours = (gameTime / 60) % 24;
|
||||
final int minutes = gameTime % 60;
|
||||
int hourDiff, minDiff;
|
||||
hourDiff = 20 - hours;
|
||||
if (hourDiff < 0)
|
||||
{
|
||||
hourDiff = 24 - (hourDiff *= -1);
|
||||
}
|
||||
minDiff = 30 - minutes;
|
||||
if (minDiff < 0)
|
||||
{
|
||||
minDiff = 60 - (minDiff *= -1);
|
||||
}
|
||||
long diff;
|
||||
hourDiff *= 3600000;
|
||||
minDiff *= 60000;
|
||||
diff = hourDiff + minDiff;
|
||||
_log.info("Fantasy Isle: MC show script starting at " + (new SimpleDateFormat("dd/MM/yyyy HH:mm:ss")).format(System.currentTimeMillis() + diff) + " and is scheduled each next 4 hours.");
|
||||
startQuestTimer("Start", diff, null, null); // first start
|
||||
}
|
||||
|
||||
private void autoChat(L2Npc npc, NpcStringId npcString, ChatType type)
|
||||
{
|
||||
npc.broadcastPacket(new NpcSay(npc.getObjectId(), type, npc.getId(), npcString));
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onSpawn(L2Npc npc)
|
||||
{
|
||||
if (IS_STARTED)
|
||||
{
|
||||
switch (npc.getId())
|
||||
{
|
||||
case 32433:
|
||||
{
|
||||
autoChat(npc, MESSAGES[0], ChatType.NPC_SHOUT);
|
||||
startQuestTimer("1", 30000, npc, null);
|
||||
break;
|
||||
}
|
||||
case 32431:
|
||||
{
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location(-56657, -56338, -2008, 33102));
|
||||
startQuestTimer("social1", 6000, npc, null, true);
|
||||
startQuestTimer("7", 215000, npc, null);
|
||||
break;
|
||||
}
|
||||
case 32432:
|
||||
{
|
||||
startQuestTimer("social1", 6000, npc, null, true);
|
||||
startQuestTimer("7", 215000, npc, null);
|
||||
break;
|
||||
}
|
||||
case 32442:
|
||||
case 32443:
|
||||
case 32444:
|
||||
case 32445:
|
||||
case 32446:
|
||||
{
|
||||
startQuestTimer("11", 100000, npc, null);
|
||||
break;
|
||||
}
|
||||
case 32424:
|
||||
case 32425:
|
||||
case 32426:
|
||||
case 32427:
|
||||
case 32428:
|
||||
{
|
||||
startQuestTimer("social1", 5500, npc, null);
|
||||
startQuestTimer("social1", 12500, npc, null);
|
||||
startQuestTimer("28", 19700, npc, null);
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
return super.onSpawn(npc);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onAdvEvent(String event, L2Npc npc, L2PcInstance player)
|
||||
{
|
||||
if ((event == null) || event.isEmpty())
|
||||
{
|
||||
_log.warning("MC_Show: Null/Empty event for npc " + npc + " and player " + player + "!");
|
||||
return null;
|
||||
}
|
||||
|
||||
if (event.equalsIgnoreCase("Start"))
|
||||
{
|
||||
IS_STARTED = true;
|
||||
addSpawn(MC, -56698, -56430, -2008, 32768, false, 0);
|
||||
startQuestTimer("Start", 14400000L, null, null); // repeat
|
||||
}
|
||||
else if ((npc != null) && IS_STARTED)
|
||||
{
|
||||
// TODO switch on event
|
||||
if (event.equalsIgnoreCase("6"))
|
||||
{
|
||||
autoChat(npc, MESSAGES[6], ChatType.NPC_SHOUT);
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location(-56511, -56647, -2008, 36863));
|
||||
npc.broadcastPacket(new PlaySound(1, "NS22_F", 0, 0, 0, 0, 0));
|
||||
addSpawn(SINGERS[0], -56344, -56328, -2008, 32768, false, 224000);
|
||||
addSpawn(SINGERS[1], -56552, -56245, -2008, 36863, false, 224000);
|
||||
addSpawn(SINGERS[1], -56546, -56426, -2008, 28672, false, 224000);
|
||||
addSpawn(SINGERS[1], -56570, -56473, -2008, 28672, false, 224000);
|
||||
addSpawn(SINGERS[1], -56594, -56516, -2008, 28672, false, 224000);
|
||||
addSpawn(SINGERS[1], -56580, -56203, -2008, 36863, false, 224000);
|
||||
addSpawn(SINGERS[1], -56606, -56157, -2008, 36863, false, 224000);
|
||||
startQuestTimer("7", 215000, npc, null);
|
||||
}
|
||||
else if (event.equalsIgnoreCase("7"))
|
||||
{
|
||||
switch (npc.getId())
|
||||
{
|
||||
case 32433:
|
||||
{
|
||||
autoChat(npc, MESSAGES[7], ChatType.NPC_SHOUT);
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location(-56698, -56430, -2008, 32768));
|
||||
startQuestTimer("8", 12000, npc, null);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
{
|
||||
cancelQuestTimer("social1", npc, null);
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location(-56594, -56064, -2008, 32768));
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (event.equalsIgnoreCase("10"))
|
||||
{
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location(-56483, -56665, -2034, 32768));
|
||||
npc.broadcastPacket(new PlaySound(1, "TP05_F", 0, 0, 0, 0, 0));
|
||||
startQuestTimer("npc1_1", 3000, addSpawn(CIRCUS[0], -56495, -56375, -2008, 32768, false, 101000), null);
|
||||
startQuestTimer("npc2_1", 3000, addSpawn(CIRCUS[0], -56491, -56289, -2008, 32768, false, 101000), null);
|
||||
startQuestTimer("npc3_1", 3000, addSpawn(CIRCUS[1], -56502, -56246, -2008, 32768, false, 101000), null);
|
||||
startQuestTimer("npc4_1", 3000, addSpawn(CIRCUS[1], -56496, -56429, -2008, 32768, false, 101000), null);
|
||||
startQuestTimer("npc5_1", 3500, addSpawn(CIRCUS[2], -56505, -56334, -2008, 32768, false, 101000), null);
|
||||
startQuestTimer("npc6_1", 4000, addSpawn(CIRCUS[3], -56545, -56427, -2008, 32768, false, 101000), null);
|
||||
startQuestTimer("npc7_1", 4000, addSpawn(CIRCUS[3], -56552, -56248, -2008, 32768, false, 101000), null);
|
||||
startQuestTimer("npc8_1", 3000, addSpawn(CIRCUS[4], -56493, -56473, -2008, 32768, false, 101000), null);
|
||||
startQuestTimer("npc9_1", 3000, addSpawn(CIRCUS[4], -56504, -56201, -2008, 32768, false, 101000), null);
|
||||
startQuestTimer("11", 100000, npc, null);
|
||||
}
|
||||
else if (event.equalsIgnoreCase("11"))
|
||||
{
|
||||
switch (npc.getId())
|
||||
{
|
||||
case 32433:
|
||||
{
|
||||
autoChat(npc, MESSAGES[11], ChatType.NPC_SHOUT);
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location(-56698, -56430, -2008, 32768));
|
||||
startQuestTimer("12", 5000, npc, null);
|
||||
break;
|
||||
}
|
||||
default:
|
||||
{
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location(-56343, -56330, -2008, 32768));
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
else if (event.equalsIgnoreCase("14"))
|
||||
{
|
||||
startQuestTimer("social1", 2000, addSpawn(INDIVIDUALS[0], -56700, -56385, -2008, 32768, false, 49000), null);
|
||||
startQuestTimer("15", 7000, npc, null);
|
||||
}
|
||||
else if (event.equalsIgnoreCase("17"))
|
||||
{
|
||||
autoChat(npc, MESSAGES[16], ChatType.NPC_SHOUT);
|
||||
startQuestTimer("social1", 2000, addSpawn(INDIVIDUALS[1], -56700, -56340, -2008, 32768, false, 32000), null);
|
||||
startQuestTimer("18", 9000, npc, null);
|
||||
}
|
||||
else if (event.equalsIgnoreCase("20"))
|
||||
{
|
||||
startQuestTimer("social1", 2000, addSpawn(INDIVIDUALS[2], -56703, -56296, -2008, 32768, false, 13000), null);
|
||||
startQuestTimer("21", 8000, npc, null);
|
||||
}
|
||||
else if (event.equalsIgnoreCase("23"))
|
||||
{
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location(-56702, -56340, -2008, 32768));
|
||||
startQuestTimer("24", 2800, npc, null);
|
||||
addSpawn(SHOWSTUFF[0], -56672, -56406, -2000, 32768, false, 20900);
|
||||
addSpawn(SHOWSTUFF[1], -56648, -56368, -2000, 32768, false, 20900);
|
||||
addSpawn(SHOWSTUFF[2], -56608, -56338, -2000, 32768, false, 20900);
|
||||
addSpawn(SHOWSTUFF[3], -56652, -56307, -2000, 32768, false, 20900);
|
||||
addSpawn(SHOWSTUFF[4], -56672, -56272, -2000, 32768, false, 20900);
|
||||
}
|
||||
else if (event.equalsIgnoreCase("28"))
|
||||
{
|
||||
autoChat(npc, MESSAGES[23], ChatType.NPC_GENERAL);
|
||||
startQuestTimer("social1", 1, npc, null);
|
||||
}
|
||||
else if (event.equalsIgnoreCase("29"))
|
||||
{
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, new Location(-56730, -56340, -2008, 32768));
|
||||
startQuestTimer("clean_npc", 4100, npc, null);
|
||||
startQuestTimer("timer_check", 60000, null, null, true);
|
||||
}
|
||||
else if (event.equalsIgnoreCase("social1"))
|
||||
{
|
||||
npc.broadcastSocialAction(1);
|
||||
}
|
||||
else if (event.equalsIgnoreCase("clean_npc"))
|
||||
{
|
||||
IS_STARTED = false;
|
||||
npc.deleteMe();
|
||||
}
|
||||
else if (TALKS.containsKey(event))
|
||||
{
|
||||
final ShoutInfo si = TALKS.get(event);
|
||||
if (si != null)
|
||||
{
|
||||
autoChat(npc, si.getNpcStringId(), ChatType.NPC_SHOUT);
|
||||
startQuestTimer(si.getNextEvent(), si.getTime(), npc, null);
|
||||
}
|
||||
}
|
||||
else if (WALKS.containsKey(event))
|
||||
{
|
||||
final WalkInfo wi = WALKS.get(event);
|
||||
if (wi != null)
|
||||
{
|
||||
npc.getAI().setIntention(CtrlIntention.AI_INTENTION_MOVE_TO, wi.getCharPos());
|
||||
startQuestTimer(wi.getNextEvent(), wi.getTime(), npc, null);
|
||||
}
|
||||
}
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
public static void main(String[] args)
|
||||
{
|
||||
new TalentShow();
|
||||
}
|
||||
}
|
23
trunk/dist/game/data/scripts/ai/zones/package-info.java
vendored
Normal file
23
trunk/dist/game/data/scripts/ai/zones/package-info.java
vendored
Normal file
@@ -0,0 +1,23 @@
|
||||
/*
|
||||
* 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/>.
|
||||
*/
|
||||
|
||||
/**
|
||||
* Zone AIs:<br>
|
||||
* This folder contains AI scripts for specific zones.
|
||||
* @author Mobius
|
||||
*/
|
||||
package ai.zones;
|
Reference in New Issue
Block a user