Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[lua][Quest] Fear of the Dark to IF #7072

Merged
merged 1 commit into from
Feb 18, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion scripts/globals/quests.lua
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ xi.quest.id =
THE_RIVALRY = 75, -- ±
THE_COMPETITION = 76, -- ±
STARTING_A_FLAME = 77, -- ±
FEAR_OF_THE_DARK = 78, -- +
FEAR_OF_THE_DARK = 78, -- + Converted
WARDING_VAMPIRES = 79, -- +
SLEEPLESS_NIGHTS = 80, -- ±
LUFETS_LAKE_SALT = 81, -- ±
Expand Down
70 changes: 70 additions & 0 deletions scripts/quests/sandoria/Fear_of_the_Dark.lua
Original file line number Diff line number Diff line change
@@ -0,0 +1,70 @@
-----------------------------------
-- Fear of the Dark
-----------------------------------
-- Log ID: 0, Quest ID: 78
-----------------------------------
-- Secodiand : !pos -160 -0 137 231
-----------------------------------

local quest = Quest:new(xi.questLog.SANDORIA, xi.quest.id.sandoria.FEAR_OF_THE_DARK)

quest.reward =
{
gil = 200,
}

quest.sections =
{
{
check = function(player, status, vars)
return status == xi.questStatus.QUEST_AVAILABLE
end,

[xi.zone.NORTHERN_SAN_DORIA] =
{
['Secodiand'] = quest:progressEvent(19),

onEventFinish =
{
[19] = function(player, csid, option, npc)
if option == 1 then
quest:begin(player)
end
end,
},
},
},
{
check = function(player, status, vars)
return status >= xi.questStatus.QUEST_ACCEPTED
end,

[xi.zone.NORTHERN_SAN_DORIA] =
{
['Secodiand'] =
{
onTrade = function(player, npc, trade)
if npcUtil.tradeHas(trade, { { xi.item.BAT_WING, 2 } }) then
return quest:progressEvent(18)
end
end,
},

onEventFinish =
{
[18] = function(player, csid, option, npc)
if player:getQuestStatus(xi.questLog.SANDORIA, xi.quest.id.sandoria.FEAR_OF_THE_DARK) == xi.questStatus.QUEST_ACCEPTED then
quest:complete(player)
else
npcUtil.giveCurrency(player, 'gil', 200)
player:addFame(xi.fameArea.SANDORIA, 5)
end

player:confirmTrade()
end,
},
},
},
}

return quest
1 change: 1 addition & 0 deletions scripts/zones/Northern_San_dOria/DefaultActions.lua
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ return {
['Rodaillece'] = { text = ID.text.RODAILLECE_DIALOG },
['Rondipur'] = { event = 721 },
['Ronpaurege'] = { event = 669 },
['Secodiand'] = { event = 17 },
['Shakir'] = { event = 538 },
['Sochiene'] = { text = ID.text.SOCHIENE_DIALOG },
['Suspicious_Elvaan'] = { event = 881 },
Expand Down
43 changes: 0 additions & 43 deletions scripts/zones/Northern_San_dOria/npcs/Secodiand.lua

This file was deleted.