From 6569f451c9c75817825c86cd3b670b0b08f96b60 Mon Sep 17 00:00:00 2001 From: Jesusaves Date: Wed, 26 Feb 2020 03:39:04 -0300 Subject: Fix bugs, add placeholders --- npc/003-1/magic.txt | 34 +--------------------------------- 1 file changed, 1 insertion(+), 33 deletions(-) (limited to 'npc/003-1') diff --git a/npc/003-1/magic.txt b/npc/003-1/magic.txt index 9fe18037b..fada53a37 100644 --- a/npc/003-1/magic.txt +++ b/npc/003-1/magic.txt @@ -12,7 +12,7 @@ OnTouch: mesc l("You cannot enter here while you have event weapons or a cart."), 1; close; } - // TODO: Main Quest Event Control + // Main Quest Event if (LUA_ASKED_TO_SAVE_PROFESSOR) { .@mapn$="0030@"+getcharid(0); // Instance doesn't exists @@ -38,35 +38,3 @@ OnTouch: end; } -function script SaggyInstCheck { - .@house=getarg(0, true); - - .@q2=getq2(HurnscaldQuest_Sagratha); - // Map name limit: 4 chars (sgt1) - .@mapn$="sgt1@"+getcharid(0); - .@map2$="sgt2@"+getcharid(0); - if (!(isinstance(.@q2) && .@q2 != 0)) { - .@inst = instance_create("Sagratha House "+getcharid(0), getcharid(3), IOT_CHAR); - instance_attachmap("014-5-1", .@inst, false, .@mapn$); - //instance_attachmap("015-8", .@inst, false, .@mapn$); - instance_attachmap("015-8-1", .@inst, false, .@map2$); - // Instance lasts one hour - instance_set_timeout(3600, 3600, .@inst); - instance_init(.@inst); - setq2 HurnscaldQuest_Sagratha, .@inst; - } - - // It broke - if (getmapinfo(MAPINFO_SIZE_X, .@mapn$) <= 0) { - setq2 HurnscaldQuest_Sagratha, 0; - // Infinite Loop? - return callfunc("SaggyInstCheck", .@house); - } - - if (.@house) { - return .@mapn$; - } else { - return .@map2$; - } -} - -- cgit v1.2.3-60-g2f50