From 73c97478d27a62435c518bd63fa3beb2905b5acc Mon Sep 17 00:00:00 2001 From: MobiusDev <8391001+MobiusDevelopment@users.noreply.github.com> Date: Sat, 6 Jun 2015 09:57:03 +0000 Subject: [PATCH] Dark Omens drop and NPC updates. Contributed by Stayway. --- trunk/dist/game/data/scripts.cfg | 1 + .../ai/npc/Teleports/DarkOmens/31118-1.htm | 4 + .../ai/npc/Teleports/DarkOmens/31118.html | 5 ++ .../ai/npc/Teleports/DarkOmens/31124.html | 5 ++ .../ai/npc/Teleports/DarkOmens/DarkOmens.java | 75 +++++++++++++++++++ .../dist/game/data/stats/npcs/31100-31199.xml | 2 +- 6 files changed, 91 insertions(+), 1 deletion(-) create mode 100644 trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/31118-1.htm create mode 100644 trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/31118.html create mode 100644 trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/31124.html create mode 100644 trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/DarkOmens.java diff --git a/trunk/dist/game/data/scripts.cfg b/trunk/dist/game/data/scripts.cfg index dabb50ab9c..9777d65275 100644 --- a/trunk/dist/game/data/scripts.cfg +++ b/trunk/dist/game/data/scripts.cfg @@ -64,6 +64,7 @@ ai/npc/SupportUnitCaptain/SupportUnitCaptain.java ai/npc/SymbolMaker/SymbolMaker.java ai/npc/Teleports/AnghelWaterfallPortal/AnghelWaterfallPortal.java ai/npc/Teleports/CrumaTower/CrumaTower.java +ai/npc/Teleports/DarkOmens/DarkOmens.java ai/npc/Teleports/DelusionTeleport/DelusionTeleport.java ai/npc/Teleports/ElrokiTeleporters/ElrokiTeleporters.java ai/npc/Teleports/GiantServant/GiantServant.java diff --git a/trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/31118-1.htm b/trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/31118-1.htm new file mode 100644 index 0000000000..a6ca242e14 --- /dev/null +++ b/trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/31118-1.htm @@ -0,0 +1,4 @@ +Gatekeeper Ziggurat:
+A human-like voice comes from a glowing blue orb:.
+Someone already went in, and Lilith disappeared soon after. There is no point in entering right now.
+ \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/31118.html b/trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/31118.html new file mode 100644 index 0000000000..e61849ce34 --- /dev/null +++ b/trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/31118.html @@ -0,0 +1,5 @@ +Gatekeeper Ziggurat:
+A human-like voice comes from a glowing blue orb:
+Behold the gateway to the Forbidden Sanctuary! No one can pass without my permission
+ + \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/31124.html b/trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/31124.html new file mode 100644 index 0000000000..1818936cfa --- /dev/null +++ b/trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/31124.html @@ -0,0 +1,5 @@ +Gatekeeper Ziggurat:
+A human-like voice comes from a glowing blue orb:
+Behold the gateway to the Forbidden Sanctuary! No one can pass without my permission
+ + \ No newline at end of file diff --git a/trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/DarkOmens.java b/trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/DarkOmens.java new file mode 100644 index 0000000000..f6d2416bf4 --- /dev/null +++ b/trunk/dist/game/data/scripts/ai/npc/Teleports/DarkOmens/DarkOmens.java @@ -0,0 +1,75 @@ +/* + * Copyright (C) 2004-2015 L2J DataPack + * + * This file is part of L2J DataPack. + * + * L2J DataPack is free software: you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation, either version 3 of the License, or + * (at your option) any later version. + * + * L2J DataPack is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * General Public License for more details. + * + * You should have received a copy of the GNU General Public License + * along with this program. If not, see . + */ +package ai.npc.Teleports.DarkOmens; + +import ai.npc.AbstractNpcAI; + +import com.l2jserver.gameserver.model.Location; +import com.l2jserver.gameserver.model.actor.L2Npc; +import com.l2jserver.gameserver.model.actor.instance.L2PcInstance; + +/** + * Dark Omens teleport AI. + * @author Stayway + */ +public final class DarkOmens extends AbstractNpcAI +{ + // NPC + private static final int ZIGURAT_IN = 31118; + private static final int ZIGURAT_OUT = 31124; + // Locations + private static final Location TELEPORT_LOC1 = new Location(-19203, 13517, -4899); + private static final Location TELEPORT_LOC2 = new Location(-20091, 13499, -4901); + + private DarkOmens() + { + super(DarkOmens.class.getSimpleName(), "ai/npc/Teleports"); + addFirstTalkId(ZIGURAT_IN, ZIGURAT_OUT); + addStartNpc(ZIGURAT_IN, ZIGURAT_OUT); + addTalkId(ZIGURAT_IN, ZIGURAT_OUT); + } + + @Override + public final String onAdvEvent(String event, L2Npc npc, L2PcInstance player) + { + if (event.equals("chat1")) + { + if ((player.getLevel() < 90) && (player.getLevel() >= 85)) + { + player.teleToLocation(TELEPORT_LOC1, true); + return null; + } + return "31118-1.htm"; + } + else if (event.equals("chat2")) + { + if ((player.getLevel() < 90) && (player.getLevel() >= 85)) + { + player.teleToLocation(TELEPORT_LOC2, true); + return null; + } + } + return event; + } + + public static void main(String[] args) + { + new DarkOmens(); + } +} \ No newline at end of file diff --git a/trunk/dist/game/data/stats/npcs/31100-31199.xml b/trunk/dist/game/data/stats/npcs/31100-31199.xml index 05bc7a8d03..31cb4b5185 100644 --- a/trunk/dist/game/data/stats/npcs/31100-31199.xml +++ b/trunk/dist/game/data/stats/npcs/31100-31199.xml @@ -784,7 +784,7 @@ - +