From 529456b33aafda550cb97ffb13c10e5fc81a54c0 Mon Sep 17 00:00:00 2001 From: Jesusaves Date: Thu, 28 Apr 2022 16:21:45 -0300 Subject: Minimum testing so it barely works --- npc/014-2-2/gemini.txt | 13 ++++++------- npc/014-2-2/valia.txt | 9 ++++++--- 2 files changed, 12 insertions(+), 10 deletions(-) (limited to 'npc/014-2-2') diff --git a/npc/014-2-2/gemini.txt b/npc/014-2-2/gemini.txt index 898d12e9e..26317f297 100644 --- a/npc/014-2-2/gemini.txt +++ b/npc/014-2-2/gemini.txt @@ -11,12 +11,10 @@ OnCoreInit: debugmes "CORE INIT, Inst = %d", instance_id(); .@p = getcharid(1); instance_attach($@VALIA_INST[.@p]); - debugmes "Attached to %d", $@VALIA_INST[.@p]; - debugmes "New Inst = %d", instance_id(); @mystatus = 0; sleep2(200); - if (!'STATUS) - 'STATUS = 1; + if (!$@VALIA_STATUS[.@p]) + $@VALIA_STATUS[.@p] = 1; // FALLTHROUGH OnCore: if (!compare(getmap(), "val")) end; @@ -24,10 +22,11 @@ OnCore: instance_attach($@VALIA_INST[.@p]); // Always true on first interaction // This handles new stages for person - if (@mystatus != 'STATUS) { - switch ('STATUS) { + if (@mystatus != $@VALIA_STATUS[.@p]) { + // No retroaction! + @mystatus = $@VALIA_STATUS[.@p]; + switch ($@VALIA_STATUS[.@p]) { case 1: // Quest initiated - @mystatus = 1; // Spawn monsters areamonster("val1@"+.@p, 20, 20, 60, 60, strmobinfo(1, GreenSlime), GreenSlime, (BaseLevel/15), "Valia::OnGSlime"); areamonster("val1@"+.@p, 20, 20, 70, 60, strmobinfo(1, LogHead), LogHead, (BaseLevel/15), "Valia::OnLHead"); diff --git a/npc/014-2-2/valia.txt b/npc/014-2-2/valia.txt index 5d02af384..622240dad 100644 --- a/npc/014-2-2/valia.txt +++ b/npc/014-2-2/valia.txt @@ -24,15 +24,18 @@ function script GeminiCheck { // You killed a mob function script GeminiKill { if (!compare(getmap(), "val")) end; - switch ('STATUS) { + .@p=getcharid(1); + debugmes "Gemini Kill! ID: %d", killedrid; + switch ($@VALIA_STATUS[.@p]) { case 1: // Quest initiated break; case 2: // Looking for a runestone if (killedrid == GreenSlime) { + debugmes "It was a Green Slime!"; if (!rand2(40)) { getexp 8132, 657; dispbottom l("You found the Runestone! You gave it to the party leader."); - 'STATUS = 3; + $@VALIA_STATUS[.@p] = 3; } } break; @@ -257,7 +260,7 @@ OnKey3: OnLord: .@p = getcharid(1); if (mobcount("val2@"+.@p, "Valia::OnLord")) { - 'STATUS = 8; + $@VALIA_STATUS[.@p] = 8; Zeny+=15000; dispbottom l("This lord dropped a key and a stash of gold!"); } -- cgit v1.2.3-60-g2f50