Link: http://rghost.net/47332524
Dungeon Lords MMXII [.DAT]
- lostprophet
- mega-veteran

- Posts: 202
- Joined: Wed Apr 07, 2010 7:38 pm
- Has thanked: 35 times
- Been thanked: 7 times
Dungeon Lords MMXII [.DAT]
If I'm not mistaken, these .DAT files hold the game's texts. If somebody could take a look at it, I would be grateful 
Link: http://rghost.net/47332524
Link: http://rghost.net/47332524
Hungarian translator | Previous translations: http://lostprophet.hu
- lostprophet
- mega-veteran

- Posts: 202
- Joined: Wed Apr 07, 2010 7:38 pm
- Has thanked: 35 times
- Been thanked: 7 times
Re: Dungeon Lords MMXII [.DAT]
Bumping the thread, updated the links.
Hungarian translator | Previous translations: http://lostprophet.hu
-
Thief1987
- advanced
- Posts: 72
- Joined: Wed Jan 18, 2012 5:11 am
- Has thanked: 1 time
- Been thanked: 29 times
Re: Dungeon Lords MMXII [.DAT]
strings files is simple
But d6Item have strange structure for text. That's for sure text files?
Code: Select all
get fname FILENAME
string fname - ".dat"
string fname + ".txt"
get strings long
log MEMORY_FILE 0 0
for i = 0 < strings
get dummy long
get stringoffset long
savepos tableoffset
goto stringoffset
getct str string 0x00
strlen str_size str
putdstring str str_size MEMORY_FILE
put 0x0a0d short MEMORY_FILE
goto tableoffset
next i
get size asize MEMORY_FILE
log fname 0x00 size MEMORY_FILE
Last edited by Thief1987 on Wed Jul 10, 2013 9:08 pm, edited 1 time in total.
- lostprophet
- mega-veteran

- Posts: 202
- Joined: Wed Apr 07, 2010 7:38 pm
- Has thanked: 35 times
- Been thanked: 7 times
Re: Dungeon Lords MMXII [.DAT]
Well, I wasn't sure, but uploaded it anyway, thought it had a different structure.
The code you posted, is that a BMS script? Because Quickbms crashes, when I import it.
The code you posted, is that a BMS script? Because Quickbms crashes, when I import it.
You do not have the required permissions to view the files attached to this post.
Hungarian translator | Previous translations: http://lostprophet.hu
-
Thief1987
- advanced
- Posts: 72
- Joined: Wed Jan 18, 2012 5:11 am
- Has thanked: 1 time
- Been thanked: 29 times
Re: Dungeon Lords MMXII [.DAT]
Yes for quickbms.
This is what i get after applying script
http://rghost.ru/private/47339674/6a8f1 ... 602604e56a
This is what i get after applying script
http://rghost.ru/private/47339674/6a8f1 ... 602604e56a
- lostprophet
- mega-veteran

- Posts: 202
- Joined: Wed Apr 07, 2010 7:38 pm
- Has thanked: 35 times
- Been thanked: 7 times
Re: Dungeon Lords MMXII [.DAT]
Thank you, got it to work, but it can't be used to reimport the file back into the archive with QuickBMS, right? It says "Script invalid for reimporting, it uses MEMORY_FILEs".Thief1987 wrote:Yes for quickbms.
This is what i get after applying script
http://rghost.ru/private/47339674/6a8f1 ... 602604e56a
Hungarian translator | Previous translations: http://lostprophet.hu
- lostprophet
- mega-veteran

- Posts: 202
- Joined: Wed Apr 07, 2010 7:38 pm
- Has thanked: 35 times
- Been thanked: 7 times
Re: Dungeon Lords MMXII [.DAT]
Thank you very muchThief1987 wrote:For repack need new script. Format not hard, i will write script tomorrow
Hungarian translator | Previous translations: http://lostprophet.hu
-
Thief1987
- advanced
- Posts: 72
- Joined: Wed Jan 18, 2012 5:11 am
- Has thanked: 1 time
- Been thanked: 29 times
Re: Dungeon Lords MMXII [.DAT]
Sorry for delaying.
This is repack script, i unpack and repack without change ds6strings.dat file for testing. Repack and original dat same. If you don't break structure of unpacking txt files(don't delete dummy strings for example) script must work correctly. Although write if you have problem
Code: Select all
open FDDE "DAT" 0
open FDDE "txt" 1
get fname FILENAME
string fname + "repack"
log MEMORY_FILE 0 0
get strings long
put strings long MEMORY_FILE
savepos ftoffset MEMORY_FILE
math ftoffset + 0x8
math TMP = strings
math TMP * 0x8
getdstring stringtable TMP
putdstring stringtable TMP MEMORY_FILE
math strings - 1
for i = 0 < strings
savepos tmpoff 1
get prov short
if prov != 2573
goto tmpoff 1
getct str string 0x0d 1
strlen str_size str
putdstring str str_size MEMORY_FILE
getdstring dummy 0x1 1
put 0x00 byte MEMORY_FILE
savepos stroffset MEMORY_FILE
goto ftoffset MEMORY_FILE
get dummy long MEMORY_FILE
put stroffset long MEMORY_FILE
savepos ftoffset MEMORY_FILE
goto stroffset MEMORY_FILE
else
put 0x00 byte MEMORY_FILE
savepos stroffset MEMORY_FILE
goto ftoffset MEMORY_FILE
get dummy long MEMORY_FILE
put stroffset long MEMORY_FILE
savepos ftoffset MEMORY_FILE
goto stroffset MEMORY_FILE
endif
next i
getct str string 0x0d 1
strlen str_size str
putdstring str str_size MEMORY_FILE
put 0x00 byte MEMORY_FILE
get size asize MEMORY_FILE
log fname 0x00 size MEMORY_FILE- lostprophet
- mega-veteran

- Posts: 202
- Joined: Wed Apr 07, 2010 7:38 pm
- Has thanked: 35 times
- Been thanked: 7 times
Re: Dungeon Lords MMXII [.DAT]
Thank you. Could you write the whole commandline command you used? I think I'm doing something wrong.
I use: quickbms.exe -r -w repack.bms D6STRING.DAT D6STRING
It says "Incomplete input file number 1, can't read 1 bytes."
D6STRING is the directory, where I extracted D6STRINGS.txt.
I use: quickbms.exe -r -w repack.bms D6STRING.DAT D6STRING
It says "Incomplete input file number 1, can't read 1 bytes."
D6STRING is the directory, where I extracted D6STRINGS.txt.
Hungarian translator | Previous translations: http://lostprophet.hu
-
Thief1987
- advanced
- Posts: 72
- Joined: Wed Jan 18, 2012 5:11 am
- Has thanked: 1 time
- Been thanked: 29 times
Re: Dungeon Lords MMXII [.DAT]
Unpack and repack doing with the same command. Just choose script and .DAT file, and unpacking .TXT must be in the same folder. Not need use repack function of quickbms.
- lostprophet
- mega-veteran

- Posts: 202
- Joined: Wed Apr 07, 2010 7:38 pm
- Has thanked: 35 times
- Been thanked: 7 times
Re: Dungeon Lords MMXII [.DAT]
One small thing tho. Does anyone know how to edit these .FNT files (font files)?
You do not have the required permissions to view the files attached to this post.
Hungarian translator | Previous translations: http://lostprophet.hu
-
merlinsvk
- ultra-veteran

- Posts: 411
- Joined: Mon Oct 27, 2008 12:11 am
- Location: Slovakia
- Has thanked: 35 times
- Been thanked: 117 times
Re: Dungeon Lords MMXII [.DAT]
I'm not good at this kind of thing, but here's my try:
Whole "description" is 0x8B4 bytes long. After it goes the texture until end of file.
It seems like RGBA format, so 4 bytes per pixel.
If I rename it to .raw extension, I can open it in Photoshop with these params.
Example for DLII_Font01.FNT.raw

And it looks like

But I'm not really sure if am I right
Code: Select all
Offset 0x0
4 bytes = texture width
4 bytes = texture height
4 bytes = number of glyphs
8 bytes = zeros
Offset 0x14 - description start
4 bytes = ascii code of glyph
4 bytes = x coordinate
4 bytes = y coordinate
4 bytes = glyph's width
4 bytes = glyph's height
4 bytes = have no clue
... and so on
It seems like RGBA format, so 4 bytes per pixel.
If I rename it to .raw extension, I can open it in Photoshop with these params.
Example for DLII_Font01.FNT.raw

And it looks like

But I'm not really sure if am I right
Last edited by merlinsvk on Mon Jul 22, 2013 8:05 pm, edited 1 time in total.
- lostprophet
- mega-veteran

- Posts: 202
- Joined: Wed Apr 07, 2010 7:38 pm
- Has thanked: 35 times
- Been thanked: 7 times
Re: Dungeon Lords MMXII [.DAT]
Thanks, I'll try this 
Hungarian translator | Previous translations: http://lostprophet.hu
