Pagan Temple rework.
Contributed by hlwrave.
This commit is contained in:
@ -0,0 +1,74 @@
|
||||
/*
|
||||
* 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.npc.Teleports.DimensionalWarpTeleport;
|
||||
|
||||
import com.l2jmobius.gameserver.model.Location;
|
||||
import com.l2jmobius.gameserver.model.actor.L2Npc;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
|
||||
|
||||
import ai.npc.AbstractNpcAI;
|
||||
|
||||
/**
|
||||
* @author hlwrave
|
||||
*/
|
||||
final class DimensionalWarpTeleport extends AbstractNpcAI
|
||||
{
|
||||
// NPC
|
||||
private final static int RESED = 33974;
|
||||
// Misc
|
||||
private final static int MIN_LEVEL = 99;
|
||||
// Items
|
||||
private final static int WARP_CRYSTAL = 39597;
|
||||
private final static int WARP_CRYSTAL_COUNT = 3;
|
||||
// Location
|
||||
private final static Location DIMENSIONAL_WARP = new Location(-76785, -217420, 4016);
|
||||
|
||||
private DimensionalWarpTeleport()
|
||||
{
|
||||
super(DimensionalWarpTeleport.class.getSimpleName(), "ai/npc/Teleports");
|
||||
addStartNpc(RESED);
|
||||
addTalkId(RESED);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onTalk(L2Npc npc, L2PcInstance player)
|
||||
{
|
||||
if ((hasQuestItems(player, WARP_CRYSTAL)) && (player.getLevel() >= MIN_LEVEL) && (getQuestItemsCount(player, WARP_CRYSTAL) >= WARP_CRYSTAL_COUNT) && (player.isAwaken()))
|
||||
{
|
||||
takeItems(player, WARP_CRYSTAL, 3);
|
||||
player.teleToLocation(DIMENSIONAL_WARP);
|
||||
}
|
||||
else if (player.getLevel() < MIN_LEVEL)
|
||||
{
|
||||
return "no_level.htm";
|
||||
}
|
||||
else if (getQuestItemsCount(player, WARP_CRYSTAL) < WARP_CRYSTAL_COUNT)
|
||||
{
|
||||
return "no_item.htm";
|
||||
}
|
||||
else
|
||||
{
|
||||
return "non_awakened.htm";
|
||||
}
|
||||
return super.onTalk(npc, player);
|
||||
}
|
||||
|
||||
public static void main(String[] args)
|
||||
{
|
||||
new DimensionalWarpTeleport();
|
||||
}
|
||||
}
|
3
trunk/dist/game/data/scripts/ai/npc/Teleports/DimensionalWarpTeleport/no_item.htm
vendored
Normal file
3
trunk/dist/game/data/scripts/ai/npc/Teleports/DimensionalWarpTeleport/no_item.htm
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
<html><body>Resed:<br>
|
||||
You must have a <font color="LEVEL">3</font> Warp Crystal , in order to teleport Dimensional Warp.
|
||||
</body></html>
|
4
trunk/dist/game/data/scripts/ai/npc/Teleports/DimensionalWarpTeleport/no_level.htm
vendored
Normal file
4
trunk/dist/game/data/scripts/ai/npc/Teleports/DimensionalWarpTeleport/no_level.htm
vendored
Normal file
@ -0,0 +1,4 @@
|
||||
<html><body>Resed:<br>
|
||||
I do not believe our paths are meant to cross here. Perhaps later down the road.<br>
|
||||
(Only characters Lv. 99. or Above)
|
||||
</body></html>
|
3
trunk/dist/game/data/scripts/ai/npc/Teleports/DimensionalWarpTeleport/non_awakened.htm
vendored
Normal file
3
trunk/dist/game/data/scripts/ai/npc/Teleports/DimensionalWarpTeleport/non_awakened.htm
vendored
Normal file
@ -0,0 +1,3 @@
|
||||
<html><body>Resed:<br>
|
||||
Sorry, I can't teleoprt you to Dimensional Warp. Come back when you have Awakened to it.
|
||||
</body></html>
|
68
trunk/dist/game/data/scripts/ai/npc/Teleports/KargosTeleport/KargosTeleport.java
vendored
Normal file
68
trunk/dist/game/data/scripts/ai/npc/Teleports/KargosTeleport/KargosTeleport.java
vendored
Normal file
@ -0,0 +1,68 @@
|
||||
/*
|
||||
* 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.npc.Teleports.KargosTeleport;
|
||||
|
||||
import com.l2jmobius.gameserver.model.Location;
|
||||
import com.l2jmobius.gameserver.model.actor.L2Npc;
|
||||
import com.l2jmobius.gameserver.model.actor.instance.L2PcInstance;
|
||||
|
||||
import ai.npc.AbstractNpcAI;
|
||||
|
||||
/**
|
||||
* @author hlwrave
|
||||
*/
|
||||
final class KargosTeleport extends AbstractNpcAI
|
||||
{
|
||||
// NPC
|
||||
private final static int KARGOS = 33821;
|
||||
// Items
|
||||
private final static int PAGAN_MARK = 8067;
|
||||
private final static int VISITOR_MARK = 8064;
|
||||
// Locations
|
||||
private final static Location PAGAN_TEMPLE = new Location(-16350, -37579, -10725);
|
||||
private final static Location PAGAN_ROOM = new Location(-12766, -35840, -10851);
|
||||
|
||||
private KargosTeleport()
|
||||
{
|
||||
super(KargosTeleport.class.getSimpleName(), "ai/npc/Teleports");
|
||||
addStartNpc(KARGOS);
|
||||
addTalkId(KARGOS);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String onTalk(L2Npc npc, L2PcInstance player)
|
||||
{
|
||||
if (hasQuestItems(player, PAGAN_MARK, VISITOR_MARK))
|
||||
{
|
||||
player.teleToLocation(PAGAN_TEMPLE);
|
||||
}
|
||||
else if (hasQuestItems(player, VISITOR_MARK))
|
||||
{
|
||||
player.teleToLocation(PAGAN_ROOM);
|
||||
}
|
||||
else
|
||||
{
|
||||
return "noItem.htm";
|
||||
}
|
||||
return super.onTalk(npc, player);
|
||||
}
|
||||
|
||||
public static void main(String[] args)
|
||||
{
|
||||
new KargosTeleport();
|
||||
}
|
||||
}
|
4
trunk/dist/game/data/scripts/ai/npc/Teleports/KargosTeleport/noItem.htm
vendored
Normal file
4
trunk/dist/game/data/scripts/ai/npc/Teleports/KargosTeleport/noItem.htm
vendored
Normal file
@ -0,0 +1,4 @@
|
||||
<html><body>Kargos:<br>
|
||||
You have nothing that would cover the holes.<br>
|
||||
(You must have a Visitor's Mark, a Pagan's Mark in order to teleport Pagan Temple.)
|
||||
</body></html>
|
Reference in New Issue
Block a user