Comments (12)
I didn't try yet. I verified that .xml files don't differ and that NWN:EE doesn't complain (and NWN:EE parses NWN bic files well). Also GFF Editor and modified xml2gff got me exactly same results.
from xoreos-tools.
Hmm, we don't really dedup on structs. Or at least, we shouldn't.
Do you still have the original data before throwing it into xml2gff and try it with a recent xoreos-tools version (0.0.6 and/or the current master branch)? If you had used xml2gff from an earlier version (i.e. from a checkout between 0.0.5 and 0.0.6), I'm afraid a bug in the GFF3 writer created faulty files in some cases. I don't think the files are repairable then, unfortunately.
from xoreos-tools.
If it does still happen with xoreos-tools 0.0.6, can you attach an example file? Pre manipulation with the xoreos-toosl and post, ideally, so I can see what happens.
from xoreos-tools.
It happens with latest version and it's easily (always) reproducible.
I don't think these files are actually broken as GFF Editor (and old NWN) opens them just fine. XML files also look good, they are just not reconstructed properly for NWN:EE.
Not even basic character stats are recovered, so I assume that some basic check is failing. I am now trying to minimize XML file that still breaks the game to be able to fix in manually in hex editor.
Note that we are using cp1250.
from xoreos-tools.
Good news (somewhat): I believe that adding a <list> actually breaks the format with given error message.
Following file emits the error:
<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<gff3 type="BIC">
<struct id="4294967295">
<list label="ClassList">
<struct id="2">
<sint32 label="Class">0</sint32>
<sint16 label="ClassLevel">1</sint16>
</struct>
</list>
</struct>
</gff3>
from xoreos-tools.
I have created similar (hopefully same) file in GFF Editor and it works. There are some differences if you want to take a look:
minimal.zip
from xoreos-tools.
Thanks, I'll probably have a look in the evening
from xoreos-tools.
I now believe that structs inside a lists are not supposed to be in field list. They cannot have label either (because they are not in the field list). Structs which are part of other structs can and will be present in field list.
I am going to run some tests now.
from xoreos-tools.
I tested it on ~10k characters in our NWN servervault and it's really the case. I submitted example PR but feel free to implement it however you like, it's rather simple change.
from xoreos-tools.
Huh, nice, interesting, thanks! Original NWN itself still eats the files like that, yes?
from xoreos-tools.
And I Just tried a gff2xml -> xml2gff -> gff2xml roundtrip, both with and without the patch, results are identical. And old NWN seems to at least eat a localvault character without any issues. Nice :)
from xoreos-tools.
Merged #72, closing this issue, thanks! :)
from xoreos-tools.
Related Issues (20)
- xml2gff not included in xoreos-tools-0.0.5 release? HOT 7
- XML2GFF: Tool needs to be game/encoding aware HOT 1
- XML2GFF: Serialize color codes HOT 7
- NCSDIS: Control flow analysis failure in do-loop nested in while-loop HOT 15
- NCSDIS: Analyse control flow for recursive functions, and functions with incompatible fork merging HOT 1
- FEATURE: Compile xoreos-tools as a DLL/library HOT 6
- FEATURE: Make more tools read stdin for input HOT 5
- FEATURE: "File picker" for RIM/ERF/MOD files HOT 9
- ERF: MOD files have incorrect prefix HOT 4
- ERF: Recursion leads to infinite loop HOT 1
- Clarify XML format for xml2gff HOT 1
- GFF2XML -> XML2GFF (invalid base64 length) HOT 5
- UNOBB: Add support for KotOR2 Android obb archives HOT 29
- Issue running configure to build project: Syntax error near unexpected token `FT2 HOT 3
- error while compiling HOT 6
- another error while compiling HOT 1
- FEATURE: Add tool to convert TGA back to TPC
- CONVERT2DA: Code and documentation mismatch for the parameters HOT 5
- xml2tlk gives error when trying convert back cp1251 xml HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from xoreos-tools.