mirror of
https://bitbucket.org/Ioncannon/project-meteor-server.git
synced 2025-04-02 19:42:05 -04:00
All the script changes done to get the openings working.
This commit is contained in:
parent
3d5fa45730
commit
53064a7345
@ -19,9 +19,7 @@ function onEventStarted(player, command, triggerName)
|
||||
--For Opening Tutorial
|
||||
if (player:hasQuest("Man0l0") or player:hasQuest("Man0g0") or player:hasQuest("Man0u0")) then
|
||||
player:getDirector():onCommand(command);
|
||||
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
end
|
@ -1,13 +0,0 @@
|
||||
|
||||
function onEventStarted(player, actor, triggerName)
|
||||
|
||||
man0l0Quest = getStaticActor("Man0l0");
|
||||
--player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrNomal001withHQ", nil, nil, nil, nil);
|
||||
player:runEventFunction("delegateEvent", player, man0l0Quest, "processEvent000_1", nil, nil, nil, nil);
|
||||
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc ,triggerName)
|
||||
player:endEvent();
|
||||
end
|
37
data/scripts/directors/openingDire_fst0Btl03_04@0A600.lua
Normal file
37
data/scripts/directors/openingDire_fst0Btl03_04@0A600.lua
Normal file
@ -0,0 +1,37 @@
|
||||
require("/quests/man/man0g0")
|
||||
|
||||
function onEventStarted(player, actor, triggerName)
|
||||
|
||||
man0g0Quest = getStaticActor("Man0g0");
|
||||
player:runEventFunction("delegateEvent", player, man0g0Quest, "processTtrNomal001withHQ", nil, nil, nil, nil);
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc, resultId)
|
||||
|
||||
player:endEvent();
|
||||
|
||||
end
|
||||
|
||||
function onTalked(player, npc)
|
||||
|
||||
man0g0Quest = player:getQuest("Man0g0");
|
||||
|
||||
if (man0g0Quest ~= nil) then
|
||||
|
||||
yda = getWorldManager():GetActorInWorld(1000009);
|
||||
papalymo = getWorldManager():GetActorInWorld(1000010);
|
||||
|
||||
if (man0g0Quest:GetQuestFlag(MAN0G0_FLAG_TUTORIAL1_DONE) == false) then
|
||||
yda:setQuestGraphic(player, 0x0);
|
||||
papalymo:setQuestGraphic(player, 0x2);
|
||||
else
|
||||
if (man0g0Quest:GetQuestFlag(MAN0G0_FLAG_MINITUT_DONE1) == true) then
|
||||
yda:setQuestGraphic(player, 0x2);
|
||||
papalymo:setQuestGraphic(player, 0x0);
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
end
|
31
data/scripts/directors/openingDire_ocn0Btl02_04@0C100.lua
Normal file
31
data/scripts/directors/openingDire_ocn0Btl02_04@0C100.lua
Normal file
@ -0,0 +1,31 @@
|
||||
require("/quests/man/man0l0")
|
||||
|
||||
function onEventStarted(player, actor, triggerName)
|
||||
|
||||
man0l0Quest = getStaticActor("Man0l0");
|
||||
player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrNomal001withHQ", nil, nil, nil, nil);
|
||||
--player:runEventFunction("delegateEvent", player, man0l0Quest, "processEvent000_1", nil, nil, nil, nil);
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc, resultId)
|
||||
|
||||
player:endEvent();
|
||||
|
||||
end
|
||||
|
||||
function onTalked(player, npc)
|
||||
|
||||
man0l0Quest = player:getQuest("Man0l0");
|
||||
|
||||
if (man0l0Quest ~= nil) then
|
||||
if (man0l0Quest ~= nil and man0l0Quest:GetQuestFlag(MAN0L0_FLAG_MINITUT_DONE1) == true and man0l0Quest:GetQuestFlag(MAN0L0_FLAG_MINITUT_DONE2) == true and man0l0Quest:GetQuestFlag(MAN0L0_FLAG_MINITUT_DONE3) == true) then
|
||||
|
||||
doorNpc = getWorldManager():GetActorInWorld(1090025);
|
||||
player:setEventStatus(doorNpc, "pushDefault", true, 0x2);
|
||||
doorNpc:setQuestGraphic(player, 0x3);
|
||||
|
||||
end
|
||||
end
|
||||
|
||||
end
|
@ -1,13 +0,0 @@
|
||||
|
||||
function onEventStarted(player, actor, triggerName)
|
||||
|
||||
man0l0Quest = getStaticActor("Man0l0");
|
||||
--player:runEventFunction("delegateEvent", player, man0l0Quest, "processEvent000_1", nil, nil, nil, nil);
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
--man0l0Quest = getStaticActor("Man0l0");
|
||||
--player:runEventFunction("delegateEvent", player, man0l0Quest, "processEvent000_3", nil, nil, nil, nil);
|
||||
--player:endEvent();
|
||||
end
|
26
data/scripts/directors/openingDire_wil0Btl01_04@0B800.lua
Normal file
26
data/scripts/directors/openingDire_wil0Btl01_04@0B800.lua
Normal file
@ -0,0 +1,26 @@
|
||||
require("/quests/man/man0u0")
|
||||
|
||||
function onEventStarted(player, actor, triggerName)
|
||||
|
||||
man0u0Quest = getStaticActor("Man0u0");
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processTtrNomal001withHQ", nil, nil, nil, nil);
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc, resultId)
|
||||
|
||||
player:endEvent();
|
||||
|
||||
end
|
||||
|
||||
function onTalked(player, npc)
|
||||
|
||||
man0u0Quest = player:getQuest("Man0u0");
|
||||
|
||||
if (man0u0Quest ~= nil) then
|
||||
|
||||
|
||||
|
||||
end
|
||||
|
||||
end
|
21
data/scripts/directors/questDirect_fst0Btl03_01@0A615.lua
Normal file
21
data/scripts/directors/questDirect_fst0Btl03_01@0A615.lua
Normal file
@ -0,0 +1,21 @@
|
||||
|
||||
function onEventStarted(player, actor, triggerName)
|
||||
|
||||
man0g0Quest = getStaticActor("Man0g0");
|
||||
--player:runEventFunction("delegateEvent", player, man0g0Quest, "processTtrBtl001");
|
||||
player:runEventFunction("delegateEvent", player, man0g0Quest, "processTtrBtl002");
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc, resultId)
|
||||
--man0g0Quest = getStaticActor("Man0g0");
|
||||
--player:runEventFunction("delegateEvent", player, man0g0Quest, "processTtrBtl002");
|
||||
player:endEvent();
|
||||
end
|
||||
|
||||
function onCommand(player, command)
|
||||
--Check command if ActivateCommand
|
||||
player:endCommand();
|
||||
player:endEvent();
|
||||
player:kickEvent(player:getDirector(), "noticeEvent", true);
|
||||
end
|
25
data/scripts/directors/questDirect_ocn0Btl02_01@0C196.lua
Normal file
25
data/scripts/directors/questDirect_ocn0Btl02_01@0C196.lua
Normal file
@ -0,0 +1,25 @@
|
||||
|
||||
function onEventStarted(player, actor, triggerName)
|
||||
|
||||
man0u0Quest = getStaticActor("Man0u0");
|
||||
man0l0Quest = getStaticActor("Man0l0");
|
||||
--player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrBtl001");
|
||||
--player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrBtlMagic001");
|
||||
--player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrBtl002");
|
||||
--player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrBtl003");
|
||||
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processTtrBtl004");
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc, resultId)
|
||||
--man0l0Quest = getStaticActor("Man0l0");
|
||||
--player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrBtl002");
|
||||
player:endEvent();
|
||||
end
|
||||
|
||||
function onCommand(player, command)
|
||||
--Check command if ActivateCommand
|
||||
--player:kickEvent(player:getDirector(), "noticeEvent");
|
||||
--player:endCommand();
|
||||
end
|
@ -2,6 +2,20 @@ local initClassItems, initRaceItems;
|
||||
|
||||
function onBeginLogin(player)
|
||||
|
||||
--New character, set the initial quest
|
||||
if (player:getPlayTime(false) == 0) then
|
||||
initialTown = player:getInitialTown();
|
||||
|
||||
if (initialTown == 1 and player:hasQuest(110001) == false) then
|
||||
player:addQuest(110001);
|
||||
elseif (initialTown == 2 and player:hasQuest(110005) == false) then
|
||||
player:addQuest(110005);
|
||||
elseif (initialTown == 3 and player:hasQuest(110009) == false) then
|
||||
player:addQuest(110009);
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
--For Opening. Set Director and reset position incase d/c
|
||||
if (player:hasQuest(110001) == true) then
|
||||
--player:setDirector("openingDirector", false);
|
||||
@ -41,6 +55,7 @@ function onLogin(player)
|
||||
|
||||
initClassItems(player);
|
||||
initRaceItems(player);
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
|
7
data/scripts/quests/man/man0g0.lua
Normal file
7
data/scripts/quests/man/man0g0.lua
Normal file
@ -0,0 +1,7 @@
|
||||
--Quest Flags
|
||||
MAN0G0_FLAG_TUTORIAL1_DONE = 0;
|
||||
MAN0G0_FLAG_TUTORIAL2_DONE = 1;
|
||||
|
||||
MAN0G0_FLAG_MINITUT_DONE1 = 4;
|
||||
MAN0G0_FLAG_MINITUT_DONE2 = 8;
|
||||
MAN0G0_FLAG_MINITUT_DONE3 = 16;
|
13
data/scripts/quests/man/man0l0.lua
Normal file
13
data/scripts/quests/man/man0l0.lua
Normal file
@ -0,0 +1,13 @@
|
||||
|
||||
--Quest Flags
|
||||
MAN0L0_FLAG_TUTORIAL1_DONE = 0;
|
||||
MAN0L0_FLAG_TUTORIAL2_DONE = 1;
|
||||
MAN0L0_FLAG_TUTORIAL3_DONE = 2;
|
||||
|
||||
MAN0L0_FLAG_MINITUT_DONE1 = 4;
|
||||
MAN0L0_FLAG_MINITUT_DONE2 = 8;
|
||||
MAN0L0_FLAG_MINITUT_DONE3 = 16;
|
||||
|
||||
--Result Unique Ids
|
||||
RESULT_Event000_1 = 0x2B9EBC42;
|
||||
RESULT_TtrNomal001 = 0x8649D125;
|
7
data/scripts/quests/man/man0u0.lua
Normal file
7
data/scripts/quests/man/man0u0.lua
Normal file
@ -0,0 +1,7 @@
|
||||
--Quest Flags
|
||||
MAN0U0_FLAG_TUTORIAL1_DONE = 0;
|
||||
MAN0U0_FLAG_TUTORIAL2_DONE = 1;
|
||||
|
||||
MAN0U0_FLAG_MINITUT_DONE1 = 4;
|
||||
MAN0U0_FLAG_MINITUT_DONE2 = 8;
|
||||
MAN0U0_FLAG_MINITUT_DONE3 = 16;
|
@ -1,3 +1,3 @@
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Monster/Lemming/NuteaterStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 10, 1, 4, false, false, false, false, false, false, false, false, 2;
|
||||
return "/Chara/Npc/Monster/Lemming/NuteaterStandard", false, false, false, false, false, npc.getActorClassId(), true, true, 10, 1, 4, true, true, true, true, true, true, true, true, 2;
|
||||
end
|
@ -1,4 +1,4 @@
|
||||
function onInstantiate(npc)
|
||||
function init(npc)
|
||||
return "/Chara/Npc/MapObj/DoorStandard", false, false, false, false, false, 5900001 , false, false, 0, 0, 0x141, 0xB7d;
|
||||
end
|
||||
|
||||
|
61
data/scripts/zones/166/npcs/pplStd_fst0Btl03_01@0A600.lua
Normal file
61
data/scripts/zones/166/npcs/pplStd_fst0Btl03_01@0A600.lua
Normal file
@ -0,0 +1,61 @@
|
||||
require("/quests/man/man0g0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onSpawn(player, npc)
|
||||
npc:setQuestGraphic(player, 0x2);
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
man0g0Quest = player:getQuest("Man0g0");
|
||||
|
||||
if (man0g0Quest ~= nil) then
|
||||
|
||||
if (triggerName == "pushDefault") then
|
||||
player:runEventFunction("delegateEvent", player, man0g0Quest, "processTtrNomal002", nil, nil, nil);
|
||||
elseif (triggerName == "talkDefault") then
|
||||
if (man0g0Quest:GetQuestFlag(MAN0G0_FLAG_TUTORIAL1_DONE) == false) then
|
||||
player:runEventFunction("delegateEvent", player, man0g0Quest, "processTtrNomal003", nil, nil, nil);
|
||||
player:setEventStatus(npc, "pushDefault", false, 0x2);
|
||||
player:getDirector():onTalked(npc);
|
||||
man0g0Quest:SetQuestFlag(MAN0G0_FLAG_TUTORIAL1_DONE, true);
|
||||
man0g0Quest:SaveData();
|
||||
else
|
||||
if (man0g0Quest:GetQuestFlag(MAN0G0_FLAG_MINITUT_DONE1) == true) then
|
||||
man0g0Quest:SetQuestFlag(MAN0G0_FLAG_TUTORIAL2_DONE, true);
|
||||
player:runEventFunction("delegateEvent", player, man0g0Quest, "processEvent010_1", nil, nil, nil);
|
||||
else
|
||||
player:runEventFunction("delegateEvent", player, man0g0Quest, "processEvent000_1", nil, nil, nil);
|
||||
end
|
||||
end
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
else
|
||||
player:endEvent(); --Should not be here w.o this quest
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
|
||||
man0g0Quest = player:getQuest("Man0g0");
|
||||
|
||||
if (man0g0Quest:GetQuestFlag(MAN0G0_FLAG_TUTORIAL2_DONE) == true) then
|
||||
player:endEvent();
|
||||
player:setDirector("QuestDirectorMan0g001", true);
|
||||
|
||||
worldMaster = getWorldMaster();
|
||||
player:sendGameMessage(player, worldMaster, 34108, 0x20);
|
||||
player:sendGameMessage(player, worldMaster, 50011, 0x20);
|
||||
|
||||
getWorldManager():DoPlayerMoveInZone(player, 10);
|
||||
player:kickEvent(player:getDirector(), "noticeEvent", true);
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
|
||||
end
|
28
data/scripts/zones/166/npcs/pplStd_fst0Btl03_02@0A600.lua
Normal file
28
data/scripts/zones/166/npcs/pplStd_fst0Btl03_02@0A600.lua
Normal file
@ -0,0 +1,28 @@
|
||||
require("/quests/man/man0g0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
man0g0Quest = player:getQuest("Man0g0");
|
||||
|
||||
if (triggerName == "talkDefault") then
|
||||
if (man0g0Quest:GetQuestFlag(MAN0G0_FLAG_MINITUT_DONE1) == false) then
|
||||
player:runEventFunction("delegateEvent", player, man0g0Quest, "processEvent000_2", nil, nil, nil);
|
||||
man0g0Quest:SetQuestFlag(MAN0G0_FLAG_MINITUT_DONE1, true);
|
||||
man0g0Quest:SaveData();
|
||||
player:getDirector():onTalked(npc);
|
||||
else
|
||||
player:runEventFunction("delegateEvent", player, man0g0Quest, "processEvent000_2", nil, nil, nil);
|
||||
end
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
player:endEvent();
|
||||
end
|
@ -5,7 +5,7 @@ end
|
||||
|
||||
function onZoneIn(player)
|
||||
|
||||
openingQuest = player:getQuest(110001);
|
||||
openingQuest = player:getQuest(110005);
|
||||
|
||||
--Opening Quest
|
||||
if (openingQuest ~= nil) then
|
||||
|
21
data/scripts/zones/184/npcs/pplStd_wil0Btl01_01@0B800.lua
Normal file
21
data/scripts/zones/184/npcs/pplStd_wil0Btl01_01@0B800.lua
Normal file
@ -0,0 +1,21 @@
|
||||
require("/quests/man/man0u0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
man0u0Quest = getStaticActor("Man0u0");
|
||||
|
||||
if (triggerName == "talkDefault") then
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processEvent000_6", nil, nil, nil);
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
player:endEvent();
|
||||
end
|
33
data/scripts/zones/184/npcs/pplStd_wil0Btl01_02@0B800.lua
Normal file
33
data/scripts/zones/184/npcs/pplStd_wil0Btl01_02@0B800.lua
Normal file
@ -0,0 +1,33 @@
|
||||
require("/quests/man/man0u0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onSpawn(player, npc)
|
||||
npc:setQuestGraphic(player, 0x2);
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
man0u0Quest = player:getQuest("man0u0");
|
||||
|
||||
if (triggerName == "talkDefault") then
|
||||
if (man0u0Quest:GetQuestFlag(MAN0U0_FLAG_MINITUT_DONE2) == false) then
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processTtrMini002_first", nil, nil, nil);
|
||||
npc:setQuestGraphic(player, 0x0);
|
||||
man0u0Quest:SetQuestFlag(MAN0U0_FLAG_MINITUT_DONE2, true);
|
||||
man0u0Quest:SaveData();
|
||||
player:getDirector():onTalked(npc);
|
||||
else
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processTtrMini002", nil, nil, nil);
|
||||
end
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
player:endEvent();
|
||||
end
|
21
data/scripts/zones/184/npcs/pplStd_wil0Btl01_03@0B800.lua
Normal file
21
data/scripts/zones/184/npcs/pplStd_wil0Btl01_03@0B800.lua
Normal file
@ -0,0 +1,21 @@
|
||||
require("/quests/man/man0u0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
man0u0Quest = getStaticActor("Man0u0");
|
||||
|
||||
if (triggerName == "talkDefault") then
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processEvent000_8", nil, nil, nil);
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
player:endEvent();
|
||||
end
|
21
data/scripts/zones/184/npcs/pplStd_wil0Btl01_04@0B800.lua
Normal file
21
data/scripts/zones/184/npcs/pplStd_wil0Btl01_04@0B800.lua
Normal file
@ -0,0 +1,21 @@
|
||||
require("/quests/man/man0u0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
man0u0Quest = getStaticActor("Man0u0");
|
||||
|
||||
if (triggerName == "talkDefault") then
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processEvent000_9", nil, nil, nil);
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
player:endEvent();
|
||||
end
|
21
data/scripts/zones/184/npcs/pplStd_wil0Btl01_05@0B800.lua
Normal file
21
data/scripts/zones/184/npcs/pplStd_wil0Btl01_05@0B800.lua
Normal file
@ -0,0 +1,21 @@
|
||||
require("/quests/man/man0u0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
man0u0Quest = getStaticActor("Man0u0");
|
||||
|
||||
if (triggerName == "talkDefault") then
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processEvent000_10", nil, nil, nil);
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
player:endEvent();
|
||||
end
|
33
data/scripts/zones/184/npcs/pplStd_wil0Btl01_06@0B800.lua
Normal file
33
data/scripts/zones/184/npcs/pplStd_wil0Btl01_06@0B800.lua
Normal file
@ -0,0 +1,33 @@
|
||||
require("/quests/man/man0u0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onSpawn(player, npc)
|
||||
npc:setQuestGraphic(player, 0x2);
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
man0u0Quest = player:getQuest("man0u0");
|
||||
|
||||
if (triggerName == "talkDefault") then
|
||||
if (man0u0Quest:GetQuestFlag(MAN0U0_FLAG_MINITUT_DONE3) == false) then
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processTtrMini003_first", nil, nil, nil);
|
||||
npc:setQuestGraphic(player, 0x0);
|
||||
man0u0Quest:SetQuestFlag(MAN0U0_FLAG_MINITUT_DONE3, true);
|
||||
man0u0Quest:SaveData();
|
||||
player:getDirector():onTalked(npc);
|
||||
else
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processTtrMini003", nil, nil, nil);
|
||||
end
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
player:endEvent();
|
||||
end
|
21
data/scripts/zones/184/npcs/pplStd_wil0Btl01_07@0B800.lua
Normal file
21
data/scripts/zones/184/npcs/pplStd_wil0Btl01_07@0B800.lua
Normal file
@ -0,0 +1,21 @@
|
||||
require("/quests/man/man0u0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
man0u0Quest = getStaticActor("Man0u0");
|
||||
|
||||
if (triggerName == "talkDefault") then
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processEvent000_12", nil, nil, nil);
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
player:endEvent();
|
||||
end
|
21
data/scripts/zones/184/npcs/pplStd_wil0Btl01_08@0B800.lua
Normal file
21
data/scripts/zones/184/npcs/pplStd_wil0Btl01_08@0B800.lua
Normal file
@ -0,0 +1,21 @@
|
||||
require("/quests/man/man0u0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
man0u0Quest = getStaticActor("Man0u0");
|
||||
|
||||
if (triggerName == "talkDefault") then
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processEvent000_13", nil, nil, nil);
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
player:endEvent();
|
||||
end
|
16
data/scripts/zones/184/npcs/pplStd_wil0Btl01_09@0B800.lua
Normal file
16
data/scripts/zones/184/npcs/pplStd_wil0Btl01_09@0B800.lua
Normal file
@ -0,0 +1,16 @@
|
||||
require("/quests/man/man0u0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
|
||||
player:endEvent();
|
||||
|
||||
end
|
48
data/scripts/zones/184/npcs/pplStd_wil0Btl01_0a@0B800.lua
Normal file
48
data/scripts/zones/184/npcs/pplStd_wil0Btl01_0a@0B800.lua
Normal file
@ -0,0 +1,48 @@
|
||||
require("/quests/man/man0u0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onSpawn(player, npc)
|
||||
npc:setQuestGraphic(player, 0x2);
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
man0u0Quest = player:getQuest("Man0u0");
|
||||
if (man0u0Quest ~= nil) then
|
||||
|
||||
if (triggerName == "pushDefault") then
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processTtrNomal002", nil, nil, nil);
|
||||
elseif (triggerName == "talkDefault") then
|
||||
if (man0u0Quest:GetQuestFlag(MAN0U0_FLAG_TUTORIAL1_DONE) == false) then
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processTtrNomal003", nil, nil, nil);
|
||||
player:setEventStatus(npc, "pushDefault", false, 0x2);
|
||||
player:getDirector():onTalked(npc);
|
||||
man0u0Quest:SetQuestFlag(MAN0U0_FLAG_TUTORIAL1_DONE, true);
|
||||
man0u0Quest:SaveData();
|
||||
else
|
||||
player:runEventFunction("delegateEvent", player, man0u0Quest, "processTtrMini001", nil, nil, nil);
|
||||
|
||||
if (man0u0Quest:GetQuestFlag(MAN0U0_FLAG_MINITUT_DONE1) == false) then
|
||||
npc:setQuestGraphic(player, 0x0);
|
||||
man0u0Quest:SetQuestFlag(MAN0U0_FLAG_MINITUT_DONE1, true);
|
||||
man0u0Quest:SaveData();
|
||||
end
|
||||
|
||||
end
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
else
|
||||
player:endEvent(); --Should not be here w.o this quest
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
|
||||
player:endEvent();
|
||||
|
||||
end
|
16
data/scripts/zones/184/npcs/pplStd_wil0Btl01_0b@0B800.lua
Normal file
16
data/scripts/zones/184/npcs/pplStd_wil0Btl01_0b@0B800.lua
Normal file
@ -0,0 +1,16 @@
|
||||
require("/quests/man/man0u0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
|
||||
player:endEvent();
|
||||
|
||||
end
|
20
data/scripts/zones/184/zone.lua
Normal file
20
data/scripts/zones/184/zone.lua
Normal file
@ -0,0 +1,20 @@
|
||||
|
||||
|
||||
function onZoneInit(zone)
|
||||
end
|
||||
|
||||
function onZoneIn(player)
|
||||
|
||||
openingQuest = player:getQuest(110009);
|
||||
|
||||
--Opening Quest
|
||||
if (openingQuest ~= nil) then
|
||||
if (openingQuest:GetQuestFlag(0) == false) then
|
||||
player:kickEvent(player:getDirector(), "noticeEvent");
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onZoneOut(zone, player)
|
||||
end
|
@ -0,0 +1,3 @@
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Monster/Fighter/FighterAllyOpeningHealer", false, false, false, false, false, npc.getActorClassId(), false, false, 10, 1, 4, false, false, false, false, false, false, false, false, 2;
|
||||
end
|
@ -0,0 +1,3 @@
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Monster/Fighter/FighterAllyOpeningAttacker", false, false, false, false, false, npc.getActorClassId(), false, false, 10, 1, 4, false, false, false, false, false, false, false, false, 2;
|
||||
end
|
@ -0,0 +1,3 @@
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Monster/Jellyfish/JellyfishScenarioLimsaLv00", false, false, false, false, false, npc.getActorClassId(), true, true, 10, 0, 4, false, false, false, false, false, false, false, false, 2;
|
||||
end
|
@ -1,4 +1,4 @@
|
||||
function onInstantiate(npc)
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
function onInstantiate(npc)
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
function onInstantiate(npc)
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
function onInstantiate(npc)
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
|
@ -1,14 +1,36 @@
|
||||
function onInstantiate(npc)
|
||||
require("/quests/man/man0l0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onSpawn(player, npc)
|
||||
|
||||
man0l0Quest = player:getQuest("man0l0");
|
||||
|
||||
if (man0l0Quest ~= nil) then
|
||||
if (man0l0Quest ~= nil) then
|
||||
if (man0l0Quest:GetQuestFlag(MAN0L0_FLAG_MINITUT_DONE3) == false) then
|
||||
npc:setQuestGraphic(player, 0x2);
|
||||
end
|
||||
end
|
||||
end
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
man0l0Quest = getStaticActor("Man0l0");
|
||||
man0l0Quest = player:getQuest("man0l0");
|
||||
|
||||
if (triggerName == "talkDefault") then
|
||||
--player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrMini003", nil, nil, nil);
|
||||
if (man0l0Quest:GetQuestFlag(MAN0L0_FLAG_MINITUT_DONE3) == false) then
|
||||
player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrMini003", nil, nil, nil);
|
||||
npc:setQuestGraphic(player, 0x0);
|
||||
man0l0Quest:SetQuestFlag(MAN0L0_FLAG_MINITUT_DONE3, true);
|
||||
man0l0Quest:SaveData();
|
||||
player:getDirector():onTalked(npc);
|
||||
else
|
||||
player:runEventFunction("delegateEvent", player, man0l0Quest, "processEvent000_8", nil, nil, nil);
|
||||
end
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
|
@ -1,4 +1,4 @@
|
||||
function onInstantiate(npc)
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
function onInstantiate(npc)
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
function onInstantiate(npc)
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
function onInstantiate(npc)
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
|
@ -1,14 +1,40 @@
|
||||
function onInstantiate(npc)
|
||||
require("/quests/man/man0l0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onSpawn(player, npc)
|
||||
|
||||
man0l0Quest = player:getQuest("man0l0");
|
||||
|
||||
if (man0l0Quest ~= nil) then
|
||||
if (man0l0Quest:GetQuestFlag(MAN0L0_FLAG_MINITUT_DONE2) == false) then
|
||||
npc:setQuestGraphic(player, 0x2);
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
man0l0Quest = getStaticActor("Man0l0");
|
||||
man0l0Quest = player:getQuest("man0l0");
|
||||
|
||||
if (man0l0Quest ~= nil) then
|
||||
if (triggerName == "talkDefault") then
|
||||
--player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrMini002", nil, nil, nil);
|
||||
if (man0l0Quest:GetQuestFlag(MAN0L0_FLAG_MINITUT_DONE2) == false) then
|
||||
player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrMini002", nil, nil, nil);
|
||||
npc:setQuestGraphic(player, 0x0);
|
||||
man0l0Quest:SetQuestFlag(MAN0L0_FLAG_MINITUT_DONE2, true);
|
||||
man0l0Quest:SaveData();
|
||||
|
||||
player:getDirector():onTalked(npc);
|
||||
else
|
||||
player:runEventFunction("delegateEvent", player, man0l0Quest, "processEvent000_13", nil, nil, nil);
|
||||
end
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
|
@ -1,4 +1,4 @@
|
||||
function onInstantiate(npc)
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
function onInstantiate(npc)
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
function onInstantiate(npc)
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
|
@ -1,4 +1,4 @@
|
||||
function onInstantiate(npc)
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceStandard", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
|
55
data/scripts/zones/193/npcs/pplStd_0f@0C100.lua
Normal file
55
data/scripts/zones/193/npcs/pplStd_0f@0C100.lua
Normal file
@ -0,0 +1,55 @@
|
||||
require("/quests/man/man0l0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceTutorial", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onSpawn(player, npc)
|
||||
|
||||
man0l0Quest = player:getQuest("Man0l0");
|
||||
|
||||
if (man0l0Quest ~= nil) then
|
||||
if (man0l0Quest ~= nil and man0l0Quest:GetQuestFlag(MAN0L0_FLAG_MINITUT_DONE1) == true and man0l0Quest:GetQuestFlag(MAN0L0_FLAG_MINITUT_DONE2) == true and man0l0Quest:GetQuestFlag(MAN0L0_FLAG_MINITUT_DONE3) == true) then
|
||||
player:setEventStatus(npc, "pushDefault", true, 0x2);
|
||||
npc:setQuestGraphic(player, 0x3);
|
||||
else
|
||||
player:setEventStatus(npc, "pushDefault", true, 0x2);
|
||||
npc:setQuestGraphic(player, 0x3);
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
if (triggerName == "pushDefault") then
|
||||
man0l0Quest = getStaticActor("Man0l0");
|
||||
player:runEventFunction("delegateEvent", player, man0l0Quest, "processEventNewRectAsk", nil);
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc, resultId, choice)
|
||||
|
||||
if (resultId == 0x2B9EBC42) then
|
||||
player:endEvent();
|
||||
player:setDirector("QuestDirectorMan0l001", true);
|
||||
|
||||
worldMaster = getWorldMaster();
|
||||
player:sendGameMessage(player, worldMaster, 34108, 0x20);
|
||||
player:sendGameMessage(player, worldMaster, 50011, 0x20);
|
||||
|
||||
getWorldManager():DoPlayerMoveInZone(player, 9);
|
||||
player:kickEvent(player:getDirector(), "noticeEvent", true);
|
||||
else
|
||||
if (choice == 1) then
|
||||
man0l0Quest = player:getQuest("Man0l0");
|
||||
player:runEventFunction("delegateEvent", player, man0l0Quest, "processEvent000_2", nil, nil, nil, nil);
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
end
|
||||
|
||||
end
|
@ -1,24 +1,63 @@
|
||||
function onInstantiate(npc)
|
||||
require("/quests/man/man0l0")
|
||||
|
||||
function init(npc)
|
||||
return "/Chara/Npc/Populace/PopulaceTutorial", false, false, false, false, false, npc.getActorClassId(), false, false, 0, 1, "TEST";
|
||||
end
|
||||
|
||||
function onSpawn(player, npc)
|
||||
|
||||
man0l0Quest = player:getQuest("Man0l0");
|
||||
|
||||
if (man0l0Quest ~= nil) then
|
||||
if (man0l0Quest:GetQuestFlag(MAN0L0_FLAG_MINITUT_DONE1) == false) then
|
||||
npc:setQuestGraphic(player, 0x2);
|
||||
end
|
||||
|
||||
if (man0l0Quest:GetQuestFlag(MAN0L0_FLAG_TUTORIAL3_DONE) == true) then
|
||||
player:setEventStatus(npc, "pushDefault", false, 0x2);
|
||||
end
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
function onEventStarted(player, npc, triggerName)
|
||||
|
||||
man0l0Quest = getStaticActor("Man0l0");
|
||||
man0l0Quest = player:getQuest("Man0l0");
|
||||
|
||||
if (man0l0Quest ~= nil) then
|
||||
|
||||
if (triggerName == "pushDefault") then
|
||||
player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrNomal002", nil, nil, nil);
|
||||
player:setEventStatus(npc, "pushDefault", false, 0x2);
|
||||
elseif (triggerName == "talkDefault") then
|
||||
--if () then
|
||||
-- player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrNomal003", nil, nil, nil);
|
||||
--else
|
||||
--Is doing talk tutorial?
|
||||
if (man0l0Quest:GetQuestFlag(MAN0L0_FLAG_TUTORIAL3_DONE) == false) then
|
||||
player:setEventStatus(npc, "pushDefault", false, 0x2);
|
||||
player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrNomal003", nil, nil, nil);
|
||||
man0l0Quest:SetQuestFlag(MAN0L0_FLAG_TUTORIAL3_DONE, true);
|
||||
npc:setQuestGraphic(player, 0x2);
|
||||
man0l0Quest:SaveData();
|
||||
|
||||
player:getDirector():onTalked(npc);
|
||||
--Was he talked to for the mini tutorial?
|
||||
else
|
||||
player:runEventFunction("delegateEvent", player, man0l0Quest, "processTtrMini001", nil, nil, nil);
|
||||
--end
|
||||
|
||||
if (man0l0Quest:GetQuestFlag(MAN0L0_FLAG_MINITUT_DONE1) == false) then
|
||||
npc:setQuestGraphic(player, 0x0);
|
||||
man0l0Quest:SetQuestFlag(MAN0L0_FLAG_MINITUT_DONE1, true);
|
||||
man0l0Quest:SaveData();
|
||||
|
||||
player:getDirector():onTalked(npc);
|
||||
end
|
||||
|
||||
end
|
||||
|
||||
else
|
||||
player:endEvent();
|
||||
end
|
||||
|
||||
else
|
||||
player:endEvent(); --Should not be here w.o this quest
|
||||
end
|
||||
end
|
||||
|
||||
function onEventUpdate(player, npc)
|
||||
|
@ -4,6 +4,7 @@ function onZoneInit(zone)
|
||||
end
|
||||
|
||||
function onZoneIn(player)
|
||||
|
||||
openingQuest = player:getQuest(110001);
|
||||
|
||||
--Opening Quest
|
||||
|
@ -3,17 +3,7 @@
|
||||
function onZoneInit(zone)
|
||||
end
|
||||
|
||||
function onZoneIn(player)
|
||||
|
||||
openingQuest = player:getQuest(110005);
|
||||
|
||||
--Opening Quest
|
||||
if (openingQuest ~= nil) then
|
||||
if (openingQuest:GetQuestFlag(0) == false) then
|
||||
player:kickEvent(player:getDirector(), "noticeEvent");
|
||||
end
|
||||
end
|
||||
|
||||
function onZoneIn(zone, player)
|
||||
end
|
||||
|
||||
function onZoneOut(zone, player)
|
||||
|
Loading…
Reference in New Issue
Block a user