Add direct whisper or teleport#1293
Closed
Mizkii wants to merge 3 commits into
Closed
Conversation
Nightblade
reviewed
Sep 4, 2025
Comment on lines
+1166
to
+1189
| local index = self.itemIndexTbl[row_idx] | ||
| if not index then return end | ||
|
|
||
| local selectedItem = self.resultTbl[row_idx][index] | ||
| local queryId = self.queryIdTbl and self.queryIdTbl[row_idx] | ||
|
|
||
| if selectedItem and queryId then | ||
| -- ConPrintf("Fetching tokens for item %s in row %d", selectedItem.id, row_idx) | ||
| self.tradeQueryRequests:FetchSingleItem(selectedItem.id, queryId, function(newItemData, errMsg) | ||
| if errMsg then | ||
| -- ConPrintf("Error fetching single item token: %s", errMsg) | ||
| selectedItem.whisper_token = nil | ||
| selectedItem.hideout_token = nil | ||
| return | ||
| end | ||
| if newItemData then | ||
| selectedItem.whisper_token = newItemData.whisper_token | ||
| selectedItem.hideout_token = newItemData.hideout_token | ||
| -- ConPrintf("Successfully updated tokens for item %s", selectedItem.id) | ||
| end | ||
| end) | ||
| else | ||
| -- ConPrintf("Missing item data or queryId for row %d, cannot fetch fresh token.", row_idx) | ||
| end |
Contributor
There was a problem hiding this comment.
Hi, just a couple of minor things I noticed -- these lines should use TABs for indentation , and it's spelled "referrer".
Contributor
There was a problem hiding this comment.
Actually I think it's probably better if I add a spelling exception for "referer" given its historical (mis)use in this context, so please disregard that part of my review.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Fixes #748
Includes #1289
Description of the problem being solved:
The new functionality includes:
hideout_token, the button changes to "Teleport" and sends the user directly to the seller's hideout.whisper_token, the button sends the trade whisper directly to the player in-game.Steps taken to verify a working solution:
hideout_tokenorwhisper_tokenpresent in the API response.docker-compose up.Link to a build that showcases this PR:
Before screenshot:
The Trader pane UI before this change, with only a single "Whisper" button that copied text.
After screenshot:
Whisper :
Teleport :


The Trader pane UI with the new dynamic button, showing "Whisper" with a whisper_token or "Teleport" for an item with a hideout token.
Docker Test: