From bfeaf1cd7c352de341f52a7a1addc604761762c5 Mon Sep 17 00:00:00 2001
From: MobiusDevelopment <8391001+MobiusDevelopment@users.noreply.github.com>
Date: Sat, 17 Aug 2019 21:06:28 +0000
Subject: [PATCH] Proper Tarti AI. Contributed by gigilo1968.
---
.../ai/areas/Aden/Tarti/34360.html} | 0
.../scripts/ai/areas/Aden/Tarti/Tarti.java | 59 +++++++++++++++++++
.../dist/game/data/spawns/Aden/TownOfAden.xml | 2 +-
.../ai/areas/Aden/Tarti/34360.html} | 0
.../scripts/ai/areas/Aden/Tarti/Tarti.java | 59 +++++++++++++++++++
.../dist/game/data/spawns/Aden/TownOfAden.xml | 2 +-
.../ai/areas/Aden/Tarti/34360.html} | 0
.../scripts/ai/areas/Aden/Tarti/Tarti.java | 59 +++++++++++++++++++
.../dist/game/data/spawns/Aden/TownOfAden.xml | 2 +-
9 files changed, 180 insertions(+), 3 deletions(-)
rename L2J_Mobius_5.0_Salvation/dist/game/data/{html/default/34359.htm => scripts/ai/areas/Aden/Tarti/34360.html} (100%)
create mode 100644 L2J_Mobius_5.0_Salvation/dist/game/data/scripts/ai/areas/Aden/Tarti/Tarti.java
rename L2J_Mobius_5.5_EtinasFate/dist/game/data/{html/default/34359.htm => scripts/ai/areas/Aden/Tarti/34360.html} (100%)
create mode 100644 L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/ai/areas/Aden/Tarti/Tarti.java
rename L2J_Mobius_6.0_Fafurion/dist/game/data/{html/default/34359.htm => scripts/ai/areas/Aden/Tarti/34360.html} (100%)
create mode 100644 L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/ai/areas/Aden/Tarti/Tarti.java
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/html/default/34359.htm b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/ai/areas/Aden/Tarti/34360.html
similarity index 100%
rename from L2J_Mobius_5.0_Salvation/dist/game/data/html/default/34359.htm
rename to L2J_Mobius_5.0_Salvation/dist/game/data/scripts/ai/areas/Aden/Tarti/34360.html
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/ai/areas/Aden/Tarti/Tarti.java b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/ai/areas/Aden/Tarti/Tarti.java
new file mode 100644
index 0000000000..f45a535bbe
--- /dev/null
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/scripts/ai/areas/Aden/Tarti/Tarti.java
@@ -0,0 +1,59 @@
+/*
+ * 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 .
+ */
+package ai.areas.Aden.Tarti;
+
+import org.l2jmobius.gameserver.model.actor.Npc;
+import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
+import org.l2jmobius.gameserver.network.serverpackets.PlaySound;
+
+import ai.AbstractNpcAI;
+
+/**
+ * Tarti AI
+ * @author Gigi
+ * @date 2019-08-17 - [22:44:02]
+ */
+public class Tarti extends AbstractNpcAI
+{
+ // NPC
+ private static final int TARTI = 34360;
+ // Misc
+ private static final String[] TARTI_VOICE =
+ {
+ "Npcdialog1.tarti_ep50_greeting_8",
+ "Npcdialog1.tarti_ep50_greeting_9",
+ "Npcdialog1.tarti_ep50_greeting_10"
+ };
+
+ private Tarti()
+ {
+ addStartNpc(TARTI);
+ addFirstTalkId(TARTI);
+ }
+
+ @Override
+ public String onFirstTalk(Npc npc, PlayerInstance player)
+ {
+ player.sendPacket(new PlaySound(3, TARTI_VOICE[getRandom(3)], 0, 0, 0, 0, 0));
+ return "34360.html";
+ }
+
+ public static void main(String[] args)
+ {
+ new Tarti();
+ }
+}
diff --git a/L2J_Mobius_5.0_Salvation/dist/game/data/spawns/Aden/TownOfAden.xml b/L2J_Mobius_5.0_Salvation/dist/game/data/spawns/Aden/TownOfAden.xml
index 06f6973dee..056a46b91f 100644
--- a/L2J_Mobius_5.0_Salvation/dist/game/data/spawns/Aden/TownOfAden.xml
+++ b/L2J_Mobius_5.0_Salvation/dist/game/data/spawns/Aden/TownOfAden.xml
@@ -112,7 +112,7 @@
-
+
\ No newline at end of file
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/html/default/34359.htm b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/ai/areas/Aden/Tarti/34360.html
similarity index 100%
rename from L2J_Mobius_5.5_EtinasFate/dist/game/data/html/default/34359.htm
rename to L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/ai/areas/Aden/Tarti/34360.html
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/ai/areas/Aden/Tarti/Tarti.java b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/ai/areas/Aden/Tarti/Tarti.java
new file mode 100644
index 0000000000..f45a535bbe
--- /dev/null
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/scripts/ai/areas/Aden/Tarti/Tarti.java
@@ -0,0 +1,59 @@
+/*
+ * 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 .
+ */
+package ai.areas.Aden.Tarti;
+
+import org.l2jmobius.gameserver.model.actor.Npc;
+import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
+import org.l2jmobius.gameserver.network.serverpackets.PlaySound;
+
+import ai.AbstractNpcAI;
+
+/**
+ * Tarti AI
+ * @author Gigi
+ * @date 2019-08-17 - [22:44:02]
+ */
+public class Tarti extends AbstractNpcAI
+{
+ // NPC
+ private static final int TARTI = 34360;
+ // Misc
+ private static final String[] TARTI_VOICE =
+ {
+ "Npcdialog1.tarti_ep50_greeting_8",
+ "Npcdialog1.tarti_ep50_greeting_9",
+ "Npcdialog1.tarti_ep50_greeting_10"
+ };
+
+ private Tarti()
+ {
+ addStartNpc(TARTI);
+ addFirstTalkId(TARTI);
+ }
+
+ @Override
+ public String onFirstTalk(Npc npc, PlayerInstance player)
+ {
+ player.sendPacket(new PlaySound(3, TARTI_VOICE[getRandom(3)], 0, 0, 0, 0, 0));
+ return "34360.html";
+ }
+
+ public static void main(String[] args)
+ {
+ new Tarti();
+ }
+}
diff --git a/L2J_Mobius_5.5_EtinasFate/dist/game/data/spawns/Aden/TownOfAden.xml b/L2J_Mobius_5.5_EtinasFate/dist/game/data/spawns/Aden/TownOfAden.xml
index 06f6973dee..056a46b91f 100644
--- a/L2J_Mobius_5.5_EtinasFate/dist/game/data/spawns/Aden/TownOfAden.xml
+++ b/L2J_Mobius_5.5_EtinasFate/dist/game/data/spawns/Aden/TownOfAden.xml
@@ -112,7 +112,7 @@
-
+
\ No newline at end of file
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/html/default/34359.htm b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/ai/areas/Aden/Tarti/34360.html
similarity index 100%
rename from L2J_Mobius_6.0_Fafurion/dist/game/data/html/default/34359.htm
rename to L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/ai/areas/Aden/Tarti/34360.html
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/ai/areas/Aden/Tarti/Tarti.java b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/ai/areas/Aden/Tarti/Tarti.java
new file mode 100644
index 0000000000..f45a535bbe
--- /dev/null
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/scripts/ai/areas/Aden/Tarti/Tarti.java
@@ -0,0 +1,59 @@
+/*
+ * 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 .
+ */
+package ai.areas.Aden.Tarti;
+
+import org.l2jmobius.gameserver.model.actor.Npc;
+import org.l2jmobius.gameserver.model.actor.instance.PlayerInstance;
+import org.l2jmobius.gameserver.network.serverpackets.PlaySound;
+
+import ai.AbstractNpcAI;
+
+/**
+ * Tarti AI
+ * @author Gigi
+ * @date 2019-08-17 - [22:44:02]
+ */
+public class Tarti extends AbstractNpcAI
+{
+ // NPC
+ private static final int TARTI = 34360;
+ // Misc
+ private static final String[] TARTI_VOICE =
+ {
+ "Npcdialog1.tarti_ep50_greeting_8",
+ "Npcdialog1.tarti_ep50_greeting_9",
+ "Npcdialog1.tarti_ep50_greeting_10"
+ };
+
+ private Tarti()
+ {
+ addStartNpc(TARTI);
+ addFirstTalkId(TARTI);
+ }
+
+ @Override
+ public String onFirstTalk(Npc npc, PlayerInstance player)
+ {
+ player.sendPacket(new PlaySound(3, TARTI_VOICE[getRandom(3)], 0, 0, 0, 0, 0));
+ return "34360.html";
+ }
+
+ public static void main(String[] args)
+ {
+ new Tarti();
+ }
+}
diff --git a/L2J_Mobius_6.0_Fafurion/dist/game/data/spawns/Aden/TownOfAden.xml b/L2J_Mobius_6.0_Fafurion/dist/game/data/spawns/Aden/TownOfAden.xml
index 06f6973dee..056a46b91f 100644
--- a/L2J_Mobius_6.0_Fafurion/dist/game/data/spawns/Aden/TownOfAden.xml
+++ b/L2J_Mobius_6.0_Fafurion/dist/game/data/spawns/Aden/TownOfAden.xml
@@ -112,7 +112,7 @@
-
+
\ No newline at end of file