nifskope icon indicating copy to clipboard operation
nifskope copied to clipboard

Unable to open .NIF file (failed to load block number)

Open jacksw32 opened this issue 1 year ago • 4 comments

I cannot open this file for some reason, it gives me the error: failed to load block number 16 (NiDataStream) previous block was NiMaterialProperty, I am currently using Nifskopes latest version and for debugging purposes I attached the file here too. Moskvoretsky_bridge.zip

jacksw32 avatar Oct 04 '23 20:10 jacksw32

There may have been a regression in nifxml, I'll take a look.

hexabits avatar Oct 06 '23 22:10 hexabits

There may have been a regression in nifxml, I'll take a look.

Alright is there a fix for it?

jacksw32 avatar Oct 12 '23 22:10 jacksw32

No, not yet. The latest nifxml had some changes to the specification that I didn't know about and it affects NiDataStream reading. I will have to find a way to compensate for it.

You can however revert that part of nif.xml if you want. Change:

<field name="Data" type="DataStreamData" arg1="Num Bytes" arg2="Component Formats" />

to

<field name="Data" type="byte" binary="true" length="Num Bytes" />

Should be around Line 7200.

hexabits avatar Oct 12 '23 23:10 hexabits

No, not yet. The latest nifxml had some changes to the specification that I didn't know about and it affects NiDataStream reading. I will have to find a way to compensate for it.

You can however revert that part of nif.xml if you want. Change:

<field name="Data" type="DataStreamData" arg1="Num Bytes" arg2="Component Formats" />

to

<field name="Data" type="byte" binary="true" length="Num Bytes" />

Should be around Line 7200.

Alright thank you. I will try it and see if it works :)

jacksw32 avatar Oct 19 '23 20:10 jacksw32