robertjanetzko / LegendsBrowser

Legends Browser is an multi-platform, open source, java-based legends viewer for dwarf fortress 0.42.
MIT License
63 stars 19 forks source link

Version 0.47 world can't be loaded #32

Closed emma-fm closed 4 years ago

emma-fm commented 4 years ago

When trying to load a xml file of a new version's world, I get the following error:

The element type "conspirator_hfid" must be terminated by the matching end-tag ""....

I've tried with both the world attached and another one (with longer history, won't upload because it's 3 GB). It's the same error for both.

The xml was made using the "x" command in the vanilla Legends interface. I'm on Linux pop_OS! 19.10, 64 bits, and I'm using openjdk 11.0.6 to run the .jar file.

region.zip

McArcady commented 4 years ago

There is a xml formatting error in the file generated by DF. It is possible to go around it for the time being by running for example: $ sed -i 's/<\/conspirator>/<\/conspirator_hfid>/g' region1-00250-01-01-legends.xml (requires Linux package 'sed')

After that the file will load. But support for new features is yet to be implemented...

McArcady commented 4 years ago

Also required:

$ sed -i  's/<\/interrogator>/<\/interrogator_hfid>/g'  region1-00250-01-01-legends.xml 
$ sed -i  's/<interrogator_hfid>\([0-9]*\)<\/convicted/<interrogator_hfid>%1<\/interrogator/g' region1-00250-01-01-legends.xml