From 2d0fddc4907a165d795c48e4c6801d28251bd3e2 Mon Sep 17 00:00:00 2001 From: jesusalva Date: Mon, 26 Feb 2018 23:34:16 -0300 Subject: Soul Menhirs can send players to Aeros. The portal can be used to go back or enable event. --- npc/001-1/portal.txt | 20 ++++++++++++++++---- npc/commands/warp.txt | 4 ++-- npc/functions/soul_menhir.txt | 31 +++++++++++++++++++------------ 3 files changed, 37 insertions(+), 18 deletions(-) diff --git a/npc/001-1/portal.txt b/npc/001-1/portal.txt index a8c459963..5c98e3f1a 100644 --- a/npc/001-1/portal.txt +++ b/npc/001-1/portal.txt @@ -1,15 +1,27 @@ -001-1,301,43,0 script Soul Menhir NPC_SOUL_CLEAN,0,0,{ +001-1,235,25,0 script Soul Menhir NPC_HIDDEN,1,0,{ + +OnTouch: mesn; - mes l("This Soul Menhir can send your soul and body back to the ground."); + mes l("This Soul Menhir can send your soul back to the world, along any items, money and/or experience gained."); mes l("Would you like to leave this place?"); menu - "Yes.", L_Leave, - "No.", L_Close; + l("No."), L_Close, + rif(getgmlevel() && !$@GM_EVENT, l("Enable Event")), L_Enable, + rif(getgmlevel() && $@GM_EVENT, l("Disable Event")), L_Disable, + l("Yes."), L_Leave; L_Leave: warp getsavepoint(0), getsavepoint(1), getsavepoint(2); goto L_Close; +L_Enable: + $@GM_EVENT=1; + close; + +L_Disable: + $@GM_EVENT=0; + close; + L_Close: close; } diff --git a/npc/commands/warp.txt b/npc/commands/warp.txt index f62e606f3..dea307bd4 100644 --- a/npc/commands/warp.txt +++ b/npc/commands/warp.txt @@ -69,11 +69,11 @@ OnInit: // TMW2 "^TULIM", "003-1 41 48", // Tulishmar "^CANDOR", "005-1 28 92", // Candor - "^HURN", "008-1 79 64"; // hurnscald: town square + "^HURN", "008-1 79 64", // hurnscald: town square // GM Stuff "^AEROS|^GM", "001-1 235 26", // Floating Island of Aeros (GM Events) - "^JAIL|^PRISON", "sec_pri 28 25", // Jesusalva's Prison + "^JAIL|^PRISON", "sec_pri 28 25"; // Jesusalva's Prison (and last line) .count = getarraysize(.aliases$[0]); diff --git a/npc/functions/soul_menhir.txt b/npc/functions/soul_menhir.txt index 78b28a44a..838b5d868 100644 --- a/npc/functions/soul_menhir.txt +++ b/npc/functions/soul_menhir.txt @@ -1,16 +1,17 @@ function script SoulMenhir { - mes "[Soul Menhir]"; - mes "(A mystical aura surrounds this stone. You feel mysteriously attracted to it. Something tells you to touch it. What do you do?)"; + mes l("[Soul Menhir]"); + mes l("(A mystical aura surrounds this stone. You feel mysteriously attracted to it. Something tells you to touch it. What do you do?)"); menu - "Touch it.", L_Bind, - "Leave it alone.", L_Return; + l("Touch it."), L_Bind, + rif($@GM_EVENT, l("Send soul to the Mana Plane for GM events")), L_Aeros, + l("Leave it alone."), L_Return; //L_Towel: // if (TowelLastUsed > (gettimetick(2) - 1800)) // goto L_DontPanic; // TowelLastUsed = gettimetick(2); -// mes "[Soul Menhir]"; +// mes l("[Soul Menhir]"); // mes "(You touch the mysterious stone. Somehow it feels hard and soft at the same time.)"; // getitem "HitchhikersTowel", 1; // goto L_Return; @@ -19,16 +20,16 @@ L_Bind: if (Menhir_Activated == 1) goto L_Shortversion; - mes "[Soul Menhir]"; - mes "(You touch the mysterious stone. Somehow it feels warm and cold at the same time.)"; - mes "(Suddenly a strange sensation flows through you. It feels like your soul leaves your body and becomes one with the stone.)"; - mes "(As suddenly as the feeling started it stops. The strange attraction is away from one moment to the next and the menhir feels like just an ordinary stone.)"; + mes l("[Soul Menhir]"); + mes l("(You touch the mysterious stone. Somehow it feels warm and cold at the same time.)"); + mes l("(Suddenly a strange sensation flows through you. It feels like your soul leaves your body and becomes one with the stone.)"); + mes l("(As suddenly as the feeling started it stops. The strange attraction is away from one moment to the next and the menhir feels like just an ordinary stone.)"); Menhir_Activated = 1; goto L_Save; L_Shortversion: - mes "[Soul Menhir]"; - mes "(A strange sensation flows through you. It feels like your soul leaves your body and becomes one with the stone. As suddenly as the feeling started it stops.)"; + mes l("[Soul Menhir]"); + mes l("(A strange sensation flows through you. It feels like your soul leaves your body and becomes one with the stone. As suddenly as the feeling started it stops.)"); goto L_Save; L_Save: @@ -36,8 +37,14 @@ L_Save: goto L_FindPoint; goto L_Do_Save; +L_Aeros: + if (!$@GM_EVENT) goto L_DontPanic; + warp "001-1", 235, 26; + message strcharinfo(0), l("You are now at the Mana Plane of Existence, at the Floating Island of Aeros."); + close; + L_DontPanic: - message strcharinfo(0), "(A strange barrier keeps you from touching the stone at this time.)"; + message strcharinfo(0), l("(A strange barrier keeps you from touching the stone at this time.)"); goto L_Return; L_Do_Save: -- cgit v1.2.3-60-g2f50