Closed RevontuletCXVII closed 1 month ago
I just started trying to work with this project today, so I could be wrong here. But digging through the code, I'm pretty sure the problem is that UKMM, through the msyt
crate, does not understand text log files correctly.
Looking at the section of logs/texts.json
where this error message comes up (I'm doing this for the NX version of the dialogue mod so my error location was different, 27:10 to be exact), it looks like this:
"Demo148_0_Text003": {
"contents": [
...
{
"control": {
"kind": "raw",
"zero": {
"four": {
"field_1": 0
}
}
} // < ERROR HERE: expected the "control" object to contain a "type" field
},
...
]
},
And of course I have no big idea what any of this means, but this file should know. It's all defined through Serde, and "kind": "raw"
means we get a RawControl
(whatever that is).
The problem is that the "code" parsing this RawControl
is wrong. Since I'm unfortunately not well-practiced with serde
I'm not 100% sure what the expected structure would be, but I imagine it'd be sth like
"control": {
"kind": "raw",
"type": "zero",
"four": {
"field_1": 0
}
}
This is, of course, not what we find in the real mod. Which does work properly in BCML, so this is a regression. It's very possible this entire problem is solved just by removing tag = "type"
from the Serde annotation for RawControl
, but if there are mods that use this other format instead then that would cause problems for those, and special handling for both cases would be needed.
EDIT: I just tested this change, and now it imports the mod correctly and everything seems to work flawlessly. Will be making a (very small) PR to https://github.com/NiceneNerd/msyt
I ran into quite a number of issues trying to update various dependencies and tweak stuff a while back, so for now I've reverted to the last pre-TOTK version of msyt until I can sort it all out for sure.
Will you be pushing a build with this reversion?
Yes, after finishing a couple other patches.
Error log:
I have tried unpacking it and repacking it using the packager in UKMM, it causes a crash when the game is loading.