Index: scripts/globals/quests.lua =================================================================== --- scripts/globals/quests.lua (revision 2115) +++ scripts/globals/quests.lua (working copy) @@ -243,14 +243,14 @@ ALL_AT_SEA = 23; THE_ALL_NEW_C_2000 = 24; -- ± -- MIHGO_S_AMIGO = 25; -- + -- -ROCK_RACKETTER = 26; +ROCK_RACKETTER = 26; -- + -- CHOCOBILIOUS = 27; -- + -- TEACHER_S_PET = 28; -- + -- REAP_WHAT_YOU_SOW = 29; -- + -- GLYPH_HANGER = 30; -- + -- THE_FANGED_ONE = 31; -- + -- CURSES_FOILED_AGAIN_1 = 32; -- + -- -CURSES_FOILED_AGAIN_2 = 33; +CURSES_FOILED_AGAIN_2 = 33; -- + -- MANDRAGORA_MAD = 34; -- + -- TO_BEE_OR_NOT_TO_BEE = 35; -- + -- TRUTH_JUSTICE_AND_THE_ONION_WAY = 36; -- + -- @@ -262,7 +262,7 @@ ONION_RINGS = 42; -- + -- A_GREETING_CARDIAN = 43; -- + -- LEGENDARY_PLAN_B = 44; -- + -- -IN_A_STEW = 45; +IN_A_STEW = 45; -- + -- LET_SLEEPING_DOGS_LIE = 46; CAN_CARDIANS_CRY = 47; -- + -- WONDER_WANDS = 48; -- + -- @@ -275,7 +275,7 @@ PAYING_LIP_SERVICE = 60; -- + -- THE_AMAZIN_SCORPIO = 61; -- + -- TWINSTONE_BONDING = 62; -- + -- -CURSES_FOILED_A_GOLEM = 63; +CURSES_FOILED_A_GOLEM = 63; -- + -- ACTING_IN_GOOD_FAITH = 64; -- ± -- FLOWER_CHILD = 65; -- ± -- THE_THREE_MAGI = 66; -- ± -- @@ -404,7 +404,7 @@ SHADOWS_OF_THE_DEPARTED = 88; APOCALYPSE_NIGH = 89; LURE_OF_THE_WILDCAT_JEUNO = 90; -THE_ROAD_TO_AHT_URHGAN = 91; +THE_ROAD_TO_AHT_URHGAN = 91; -- + -- CHOCOBO_ON_THE_LOOSE = 92; THE_GOBBIEBAG_PART_VII = 93; -- + -- THE_GOBBIEBAG_PART_VIII = 94; -- + -- @@ -603,4 +603,4 @@ ----------------------------------- -- Abyssea ------------------------------------ \ No newline at end of file +----------------------------------- Index: scripts/zones/Windurst_Waters/npcs/Ranpi-Monpi.lua =================================================================== --- scripts/zones/Windurst_Waters/npcs/Ranpi-Monpi.lua (revision 2015) +++ scripts/zones/Windurst_Waters/npcs/Ranpi-Monpi.lua (working copy) @@ -1,8 +1,8 @@ ----------------------------------- -- Area: Windurst Waters -- NPC: Ranpi-Monpi --- Starts and Finished Quest: A Crisis in the Making --- Working 100% +-- Starts and Finishes Quest: A Crisis in the Making +-- Involved in quest: In a Stew, For Want of a Pot, The Dawn of Delectability -- @zone = 238 -- @pos = -116 -3 52 (outside the shop he is in) ----------------------------------- @@ -20,6 +20,20 @@ ----------------------------------- function onTrade(player,npc,trade) + + IASvar = player:getVar("IASvar"); + + -- In a Stew + if (IASvar == 3) then + count = trade:getItemCount(); + if (trade:hasItemQty(4373,3) and count == 3) then + player:startEvent(0x022C); -- Correct items given, advance quest + else + player:startEvent(0x022B,0,4373); -- incorrect or not enough, play reminder dialog + end + + end + end; ----------------------------------- @@ -28,7 +42,19 @@ function onTrigger(player,npc) crisisstatus = player:getQuestStatus(WINDURST,A_CRISIS_IN_THE_MAKING); - if (crisisstatus == QUEST_AVAILABLE and player:getFameLevel(WINDURST) >= 2 and player:needToZone() == false) then -- A Crisis in the Making + ITEM: Quest Offer + IAS = player:getQuestStatus(WINDURST,IN_A_STEW); + IASvar = player:getVar("IASvar"); + + -- In a Stew + if (IAS == QUEST_ACCEPTED and IASvar == 2) then + player:startEvent(0x022A,0,4373); -- start fetch portion of quest + elseif (IAS == QUEST_ACCEPTED and IASvar == 3) then + player:startEvent(0x022B,0,4373); -- reminder dialog + elseif (IAS == QUEST_ACCEPTED and IASvar == 4) then + player:startEvent(0x022D); -- new dialog before finish of quest + + -- A Crisis in the Making + elseif (crisisstatus == QUEST_AVAILABLE and player:getFameLevel(WINDURST) >= 2 and player:needToZone() == false) then -- A Crisis in the Making + ITEM: Quest Offer player:startEvent(0x0102,0,625); elseif (crisisstatus == QUEST_ACCEPTED) then prog = player:getVar("QuestCrisisMaking_var"); @@ -44,10 +70,11 @@ elseif (crisisstatus == QUEST_COMPLETED and player:getVar("QuestCrisisMaking_var") == 2) then -- A Crisis in the Making: Repeatable Quest Finish player:startEvent(0x010c); else + --Standard dialogs rand = math.random(1,3); - if (rand == 1) then -- STANDARD CONVO: sings song about engredients + if (rand == 1) then -- STANDARD CONVO: sings song about ingredients player:startEvent(0x00f9); - elseif (rand == 2) then -- STANDARD CONVO 2: sings song about engredients + elseif (rand == 2) then -- STANDARD CONVO 2: sings song about ingredients player:startEvent(0x00fb); elseif (rand == 3) then -- STANDARD CONVO 3: player:startEvent(0x0100); @@ -71,6 +98,8 @@ function onEventFinish(player,csid,option) --printf("CSID: %u",csid); --printf("RESULT: %u",option); + + -- A Crisis in the Making if (csid == 0x0102 and option == 1) then -- A Crisis in the Making + ITEM: Quest Offer - ACCEPTED player:addQuest(WINDURST,A_CRISIS_IN_THE_MAKING); player:setVar("QuestCrisisMaking_var",1); @@ -97,5 +126,15 @@ player:delKeyItem(39,OFF_OFFERING); player:addFame(WINDURST,WIN_FAME*8); player:needToZone(true); + + -- In a Stew + elseif (csid == 0x022A) then -- start fetch portion + player:setVar("IASvar",3); + elseif (csid == 0x022C) then + player:tradeComplete(); + player:setVar("IASvar",4); + player:addKeyItem(RANPIMONPIS_SPECIAL_STEW); + player:messageSpecial(KEYITEM_OBTAINED,RANPIMONPIS_SPECIAL_STEW); + end end; Index: scripts/zones/Windurst_Woods/npcs/Kuoh_Rhel.lua =================================================================== --- scripts/zones/Windurst_Woods/npcs/Kuoh_Rhel.lua (revision 2015) +++ scripts/zones/Windurst_Woods/npcs/Kuoh_Rhel.lua (working copy) @@ -1,11 +1,12 @@ ----------------------------------- -- Area: Windurst Woods --- NPC: Kuoh Rhel +-- NPC: Kuoh Rhel -- Type: Standard NPC --- @zone: 241 +-- @zone: 241 -- @pos: 131.437 -6 -102.723 --- --- Auto-Script: Requires Verification (Verfied by Brawndo) +-- Starts quests: Chocobilious, In a Stew +-- Note: In a Stew should only repeat once per conquest tally. The tally is not implemented at time of +-- writing this quest. Once it is working please feel free to add it in ^^ ----------------------------------- package.loaded["scripts/zones/Windurst_Woods/TextIDs"] = nil; ----------------------------------- @@ -27,10 +28,35 @@ ----------------------------------- function onTrigger(player,npc) - --player:delQuest(WINDURST,CHOCOBILIOUS); - local chocobilious = player:getQuestStatus(WINDURST,CHOCOBILIOUS); - if (chocobilious == QUEST_AVAILABLE and player:getFameLevel(WINDURST) >= 2) then + chocobilious = player:getQuestStatus(WINDURST,CHOCOBILIOUS); + IAS = player:getQuestStatus(WINDURST,IN_A_STEW); + IASvar = player:getVar("IASvar"); + + -- In a Stew + if (IAS == QUEST_AVAILABLE and chocobilious == QUEST_COMPLETED and player:getFameLevel (WINDURST) >= 3) then + if(player:needToZone()) then + player:startEvent(0x00E8); -- Post quest dialog from Chocobilious + else + player:startEvent(0x00EB); -- IAS start + end + + elseif (IASvar == 4 and player:hasKeyItem(RANPIMONPIS_SPECIAL_STEW)) then + player:startEvent(0x00EF); -- IAS turn in + + elseif (IAS == QUEST_ACCEPTED) then + player:startEvent(0x00EC); -- reminder dialog + + + -- Uncomment once conquest tally in place + --elseif (IAS == QUEST_COMPLETED) then + --player:startEvent(0x00F0); -- new dialog between repeats + + elseif (IAS == QUEST_COMPLETED) then + player:startEvent(0x00EA); -- start repeat + + -- Chocobilious + elseif (chocobilious == QUEST_AVAILABLE and player:getFameLevel(WINDURST) >= 2) then player:startEvent(0x00e0); -- Start quest elseif (chocobilious == QUEST_COMPLETED and player:needToZone() == true) then player:startEvent(0x00e8); -- Quest complete @@ -39,7 +65,8 @@ elseif (chocobilious == QUEST_ACCEPTED) then player:startEvent(0x00e1); -- Post quest accepted else - player:startEvent(0x00de); -- default cs + -- Standard dialog + player:startEvent(0x00de); end end; @@ -58,11 +85,13 @@ ----------------------------------- function onEventFinish(player,csid,option) -printf("CSID: %u",csid); +--printf("CSID: %u",csid); --printf("RESULT: %u",option); - if (csid == 0x00e0 and option == 1) then + + --Chocobilious + if (csid == 0x00e0 and option == 1) then -- Quest start player:addQuest(WINDURST,CHOCOBILIOUS); - elseif (csid == 0x00e7) then + elseif (csid == 0x00e7) then -- finish Quest player:completeQuest(WINDURST,CHOCOBILIOUS); player:addFame(WINDURST,WIN_FAME*220); player:addGil(GIL_RATE*1500); @@ -70,5 +99,20 @@ player:tradeComplete(); player:setVar("ChocobiliousQuest",0) player:needToZone(true); + + -- In a Stew + elseif (csid == 0x00EB) then + player:addQuest(WINDURST,IN_A_STEW); -- Quest start + player:setVar("IASvar",1); + elseif (csid == 0x00EF) then + player:completeQuest(WINDURST,IN_A_STEW); -- finish Quest + player:setVar("IASvar",0); + player:addFame(WINDURST,WIN_FAME*50); + player:addGil(GIL_RATE*900); + player:messageSpecial(GIL_OBTAINED,GIL_RATE*900); + player:delKeyItem(RANPIMONPIS_SPECIAL_STEW); + elseif (csid == 0x0EA and option == 1) then -- start repeat + player:setVar("IASvar",3); + end end; Index: scripts/zones/Windurst_Woods/npcs/Matata.lua =================================================================== --- scripts/zones/Windurst_Woods/npcs/Matata.lua (revision 2015) +++ scripts/zones/Windurst_Woods/npcs/Matata.lua (working copy) @@ -1,10 +1,16 @@ ----------------------------------- -- Area: Windurst Woods -- NPC: Matata --- Working 100% +-- Type: Standard NPC +-- @zone: 241 +-- @pos: 131 -5 -109 +-- Involved in quest: In a Stew ----------------------------------- require("scripts/globals/settings"); +require("scripts/globals/quests"); +require("scripts/globals/titles"); +require("scripts/zones/Windurst_Woods/TextIDs"); ----------------------------------- -- onTrade Action @@ -18,7 +24,25 @@ ----------------------------------- function onTrigger(player,npc) + + CB = player:getQuestStatus(WINDURST,CHOCOBILIOUS); + IAS = player:getQuestStatus(WINDURST,IN_A_STEW); + IASvar = player:getVar("IASvar"); + + if (IAS == QUEST_ACCEPTED and IASvar == 1) then + player:startEvent(0x00E9,0,0,4545); -- In a Stew in progress + elseif (IAS == QUEST_ACCEPTED and IASvar == 2) then + player:startEvent(0x00ED); -- In a Stew reminder + elseif (IAS == QUEST_COMPLETED) then + player:startEvent(0x00F1); -- new dialog after In a Stew + + elseif (CB == QUEST_COMPLETED) then + player:startEvent(0x00E2); -- Chocobilious complete + + else + -- Standard Dialog player:startEvent(0xdf); + end end; ----------------------------------- @@ -37,6 +61,11 @@ function onEventFinish(player,csid,option) --printf("CSID: %u",csid); --printf("RESULT: %u",option); + + -- In a Stew + if (csid == 0x00E9) then + player:setVar("IASvar",2); + end end;