-
Notifications
You must be signed in to change notification settings - Fork 447
Fixed bug in return of completed data for assault extdata #2435
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
Open
Traelblaser
wants to merge
2
commits into
Windower:dev
Choose a base branch
from
Traelblaser:assault-extdata-2
base: dev
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -1972,88 +1972,88 @@ end | |
|
|
||
| function decode.AssaultLog(itemid, str) | ||
| local missions = T{ | ||
| [2491] = T{ | ||
| [2491] = { | ||
| -- "Leujaoam Log" | ||
| [1] = "Leujaom Cleansing", | ||
| [2] = "Orichalcum Survey", | ||
| [3] = "Escort Professor Chanoix", | ||
| [4] = "Shanarha Grass Conservation", | ||
| [5] = "Counting Sheep", | ||
| [6] = "Supplies Recovery", | ||
| [7] = "Azure Experiments", | ||
| [8] = "Imperial Code", | ||
| [9] = "Red Versus Blue", | ||
| [10] = "Bloody Rhondo" | ||
|
|
||
| [1] = {name="Leujaom Cleansing"}, | ||
| [2] = {name="Orichalcum Survey"}, | ||
| [3] = {name="Escort Professor Chanoix"}, | ||
| [4] = {name="Shanarha Grass Conservation"}, | ||
| [5] = {name="Counting Sheep"}, | ||
| [6] = {name="Supplies Recovery"}, | ||
| [7] = {name="Azure Experiments"}, | ||
| [8] = {name="Imperial Code"}, | ||
| [9] = {name="Red Versus Blue"}, | ||
| [10] = {name="Bloody Rhondo"}, | ||
| }, | ||
| [2492] = T{ | ||
| [2492] = { | ||
| -- "Mamool Ja Journal" | ||
| [1] = "Imperial Agent Rescue", | ||
| [2] = "Preemptive Strike", | ||
| [3] = "Sagelord Elimination", | ||
| [4] = "Breaking Morale", | ||
| [5] = "The Double Agent", | ||
| [6] = "Imperial Treasure Retrieval", | ||
| [7] = "Blitzkrieg", | ||
| [8] = "Marids in the Mist", | ||
| [9] = "Azure Ailments", | ||
| [10] = "The Susanoo Shuffle" | ||
| [1] = {name="Imperial Agent Rescue"}, | ||
| [2] = {name="Preemptive Strike"}, | ||
| [3] = {name="Sagelord Elimination"}, | ||
| [4] = {name="Breaking Morale"}, | ||
| [5] = {name="The Double Agent"}, | ||
| [6] = {name="Imperial Treasure Retrieval"}, | ||
| [7] = {name="Blitzkrieg"}, | ||
| [8] = {name="Marids in the Mist"}, | ||
| [9] = {name="Azure Ailments"}, | ||
| [10] = {name="The Susanoo Shuffle"}, | ||
| }, | ||
|
|
||
| [2493] = T{ | ||
| [2493] = { | ||
| -- "Lebros Chronicle" | ||
| [1] = "Excavation Duty", | ||
| [2] = "Lebros Supplies", | ||
| [3] = "Troll Fugitives", | ||
| [4] = "Evade and Escape", | ||
| [5] = "Siegemaster Assassination", | ||
| [6] = "Apkallu Breeding", | ||
| [7] = "Wamoura Farm Raid", | ||
| [8] = "Egg Conservation", | ||
| [9] = "Operation: Black Pearl", | ||
| [10] = "Better than One", | ||
| [1] = {name="Excavation Duty"}, | ||
| [2] = {name="Lebros Supplies"}, | ||
| [3] = {name="Troll Fugitives"}, | ||
| [4] = {name="Evade and Escape"}, | ||
| [5] = {name="Siegemaster Assassination"}, | ||
| [6] = {name="Apkallu Breeding"}, | ||
| [7] = {name="Wamoura Farm Raid"}, | ||
| [8] = {name="Egg Conservation"}, | ||
| [9] = {name="Operation: Black Pearl"}, | ||
| [10] = {name="Better than One"}, | ||
| }, | ||
| [2494] = T{ | ||
| [2494] = { | ||
| -- "Periqia Diary" | ||
| [1] = "Seagull Grounded", | ||
| [2] = "Requiem", | ||
| [3] = "Saving Private Ryaaf", | ||
| [4] = "Shooting Down the Baron", | ||
| [5] = "Building Bridges", | ||
| [6] = "Stop the Bloodshed", | ||
| [7] = "Defuse the Threat", | ||
| [8] = "Operation: Snake Eyes", | ||
| [9] = "Wake the Puppet", | ||
| [10] = "The Price Is Right", | ||
| [1] = {name="Seagull Grounded"}, | ||
| [2] = {name="Requiem"}, | ||
| [3] = {name="Saving Private Ryaaf"}, | ||
| [4] = {name="Shooting Down the Baron"}, | ||
| [5] = {name="Building Bridges"}, | ||
| [6] = {name="Stop the Bloodshed"}, | ||
| [7] = {name="Defuse the Threat"}, | ||
| [8] = {name="Operation: Snake Eyes"}, | ||
| [9] = {name="Wake the Puppet"}, | ||
| [10] = {name="The Price Is Right"}, | ||
| }, | ||
| [2495] = T{ | ||
| [2495] = { | ||
| -- "Ilrusi Ledger" | ||
| [1] = "Golden Salvage", | ||
| [2] = "Lamia No.13", | ||
| [3] = "Extermination", | ||
| [4] = "Demolition Duty", | ||
| [5] = "Searat Salvation", | ||
| [6] = "Apkallu Seizure", | ||
| [7] = "Lost and Found", | ||
| [8] = "Deserter", | ||
| [9] = "Desperately Seeking Cephalopods", | ||
| [10] = "Bellerophon's Bliss", | ||
| [1] = {name="Golden Salvage"}, | ||
| [2] = {name="Lamia No.13"}, | ||
| [3] = {name="Extermination"}, | ||
| [4] = {name="Demolition Duty"}, | ||
| [5] = {name="Searat Salvation"}, | ||
| [6] = {name="Apkallu Seizure"}, | ||
| [7] = {name="Lost and Found"}, | ||
| [8] = {name="Deserter"}, | ||
| [9] = {name="Desperately Seeking Cephalopods"}, | ||
| [10] = {name="Bellerophon's Bliss"}, | ||
| }, | ||
| } | ||
|
|
||
| local names = missions[itemid] | ||
| local flags = {str:unpack("<q10")} | ||
| local data = T{flags}:key_map(function(id) return names[id] end) | ||
| local flags = T{str:unpack("<q10")} | ||
| for key, val in ipairs(flags) do | ||
| names[key].completed = val | ||
| end | ||
|
|
||
| local rettab = { | ||
| type='Assault Log', | ||
| completed = S{data}, | ||
| completed = names, | ||
| flags = flags, | ||
| } | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Not too happy with the structure of the result table. I would return something like this: return {
type = 'Assault Log',
area = 'Ilrusi', -- will need to be looked up based on ID
log = {
{ name = 'Golden Salvage', completed = false },
...
},
}With my above suggestion, this could be: return {
type = 'Assault Log',
area = missions[item_id].name,
log = table.range(10):map(function(index)
return {
name = missions[item_id][index],
completed = flags[index],
}
end),
} |
||
| return rettab | ||
| end | ||
|
|
||
|
|
||
|
|
||
| function decode.BonanzaMarble(str) | ||
| local event_list = { | ||
| [0x00] = 'CS Event Race', | ||
|
|
||
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would change this back to being raw strings, and assemble the
nameattribute later. Also, please move themissionstable outside of the function and close over it, like this: