Skip to content

[Module] Quest "Chocobo's Wounds" - Era-Wait-Time#9771

Merged
Xaver-DaRed merged 1 commit into
LandSandBoat:basefrom
JerokeXI:ChocoboEraWait
Apr 17, 2026
Merged

[Module] Quest "Chocobo's Wounds" - Era-Wait-Time#9771
Xaver-DaRed merged 1 commit into
LandSandBoat:basefrom
JerokeXI:ChocoboEraWait

Conversation

@JerokeXI
Copy link
Copy Markdown
Contributor

@JerokeXI JerokeXI commented Apr 12, 2026

[Module] Quest "Chocobo's Wounds" - Era Wait-Time

I affirm:

  • I understand that if I do not agree to the following points by completing the checkboxes my PR will be ignored.
  • I understand I should leave resolving conversations to the LandSandBoat team so that reviewers won't miss what was said.
  • I have read and understood the Contributing Guide and the Code of Conduct.
  • I have tested my code and the things my code has changed since the last commit in the PR and will test after any later commits.

What does this pull request do?

  1. Modify the "Chocobo's Wounds" quest wait time between trades
    from 1 minute to wait for a new unique Vanadiel day.
    Proposal Co-Authored-By: Xaver-DaRed
  • Makes the quest function like it did in Era prior to Feb. 2015 updates.

Steps to test these changes

  1. Run command in map.exe: gm "player" 4 (5 if you're going to use !addtime)
  2. Run the following GM commands in FFXI client

!setplayerlevel 20
!zone Upper Jeuno
!gotoname Brutus
!additem CLUMP_OF_GAUSEBIT_WILDGRASS x4

  1. Talk to brutus and start the quest
  2. Attempt to trade CLUMP_OF_GAUSEBIT_WILDGRASS to Chocobo every new in game day
  • 1st, 2nd, and "too soon" attempts return appropriate dialogue
  • Cutscene shows on 3rd attempt
  • 3rd, 4th, 5th, and 6th attempts return appropriate dialogue and remove 1 grass from player
  1. Quest completed with a cutscene and player received chocobo license

Copy link
Copy Markdown
Contributor

@CriticalXI CriticalXI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

An overall adjustment we should make too is that we should adjust this file to be a general quest adjustments file rather than being specifically for the Chocobo Wounds quest. Let's rename the file to "quest_adjustments.lua"

Comment thread modules/soa/lua/quest_adjustments.lua
Comment thread modules/soa/lua/quest_adjustments.lua
-- onEventFinish handlers confirmTrade() and set Timer.
-- Event 73 is "too soon" response, confirms trade and gives item back without setting a new timer or progress.
-- Other events where the Chocobo is not ready confirm the trade, give the item back, and set a new timer and progress.
quest.sections[2][xi.zone.UPPER_JEUNO].onEventFinish[73] = function(player, csid, option, npc)
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Small nit but we should order these onEventFinish in numerical order.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will re-order this event to the bottom. Thank You.

Comment on lines +34 to +36
-- TODO: needs capture for retail event data to determine how the trades are completed.
-- Retail doesn't print the gausebit grass obtained by player after each "too soon" trade.
-- Suggests the event may be giving the item back or zoning player.
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think trying to module this quest is surfacing an issue we have with the tradeComplete. Looks like it currently doesn't take the item but it locks it in a weird state like we were talking about on Discord. This might require another PR to fix the trade binding so this npcUtil.giveItem isn't needed.

Copy link
Copy Markdown
Contributor

@Xaver-DaRed Xaver-DaRed Apr 12, 2026

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If one isnt completing/terminating a trade, One isnt supposed to use the tradeHasExactly() util.

And example of a trade that doesnt consume items but performs an action would be the beastcoin doors at Sea Serpent Grotto.

entity.onTrade = function(player, npc, trade)
    -- The coin isn't consumed, so we only need to know if one was in the trade window
    if trade:getItemQty(xi.item.GOLD_BEASTCOIN) > 0 then
        if player:getCharVar('SSG_GoldDoor') == 7 then
            npc:openDoor(5) -- Open the door if a gold beastcoin has been traded after checking the door the required number of times
        end
    end
end

This logic doesn't consude the item, nor changes it's state to reserved
trade:getItemQty(ITEM_ID) Should be used for those.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll work changing the non-consuming events to use this function.

local timer = tonumber(quest:getVar(player, 'Timer')) or 0
-- Allow one attempt on first day (timer defaults 0) and once per new Vanadiel day
if timer < VanadielUniqueDay() then
local prog = tonumber(quest:getVar(player, 'Prog')) or 1
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

getVar always returns an int type.

if npcUtil.tradeHasExactly(trade, xi.item.BUNCH_OF_GYSAHL_GREENS) then
return quest:progressEvent(76)
elseif npcUtil.tradeHasExactly(trade, xi.item.CLUMP_OF_GAUSEBIT_WILDGRASS) then
local timer = tonumber(quest:getVar(player, 'Timer')) or 0
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Int type by default, no need to cast

-- Allow one attempt on first day (timer defaults 0) and once per new Vanadiel day
if timer < VanadielUniqueDay() then
local prog = tonumber(quest:getVar(player, 'Prog')) or 1
local chocoboFeedTrades = { 57, 58, 59, 60, 63, 64 }
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Its a module, but magic numbers are never appreciated for future maintainers

@JerokeXI JerokeXI force-pushed the ChocoboEraWait branch 3 times, most recently from 534dc23 to 911f1e2 Compare April 17, 2026 02:42
@JerokeXI JerokeXI marked this pull request as ready for review April 17, 2026 03:16
@Xaver-DaRed Xaver-DaRed merged commit ea84f33 into LandSandBoat:base Apr 17, 2026
10 checks passed
@JerokeXI JerokeXI deleted the ChocoboEraWait branch April 19, 2026 04:02
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants