Visit the Ironworks Gaming Website Email the Webmaster Graphics Library Rules and Regulations Help Support Ironworks Forum with a Donation to Keep us Online - We rely totally on Donations from members Donation goal Meter

Ironworks Gaming Radio

Ironworks Gaming Forum

Go Back   Ironworks Gaming Forum > Ironworks Gaming Classics > Wizards & Warriors Forum

Reply
 
Thread Tools Search this Thread
Old 01-18-2014, 10:23 AM   #1
Shadow Stranger
Avatar
 

Join Date: December 9, 2007
Posts: 594
Ironworks Forum Decrypting File GMDATA.PAK

File GMDATA.PAK.
This file controls town quests, shops and guilds.
It has a size of 175,514 Bytes.

Offsets 0 to 776: The Table of Contents
Each section is represented by eight bytes, the first four list the starting offset while the second four give the length of the section.

Section 0: Some basic words
0 776 (?, Hail, Goodbye, Trade, Gael Serran, Crypt, Graveyard, Gareth, Serpent Temple, Nymph Lake)

Sections 2 to 22: the code behind the dialogs:
2 912 Sir Elgar
3 2,152 Onabe
4 4,000 Smitty
5 5,976 Roendalf
6 7,713 Galliwag
7 8,797 Master Wu
8 10,632 Bratsol
9 12,525 Lord Barrenhawk
10 13,865 Munsey
11 15,737 Damosh
12 17,784 Xander
13 19,548 Alonso
14 20,644 Sinsei Asami
15 22,685 Miruth
16 24,601 Duke Brinsly
17 25,668 Malakai
18 27,683 Strumbold
19 29,804 Sabastio
20 31,654 Holthorne
21 32,466 Buckly
22 32,983 Gareth's Dream

Sections 34 to 54, the actual dialog.
34 33,100 Sir Elgar
35 38,472 Onabe
36 46,662 Smitty
37 53,997 Roendalf
38 61,049 Galliwag
39 65,932 Master Wu
40 73,621 Bratsol
41 82,079 Lord Barrenhawk
42 88,611 Munsey
43 96,777 Damosh
44 104,424 Xander
45 111,864 Alonso
46 116,880 Sinsei Asami
47 125,900 Miruth
48 134,497 Duke Brinsly
49 139,850 Malakai
50 149,837 Strumbold
51 158,422 Sabastio
52 167,587 Holthorne
53 170,798 Buckly
54 172,263 Gareth's Dream

66 173,750
66 through 86, all sections are identical.
86 175,430

Explanation:
2 912 Sir Elgar
2 is the section number, 912 is the start offset and Sir Elgar is the subject of the section.

Sections 34 through 54 have tables of contents, that enable you to see what starts where. But then all dialog is separated by a 0 anyway.
My understanding of the code sections is fairly poor, I can spot item numbers that is about it. Decryption would normally be hard going indeed. But there are possible workarounds. Guilds have some classes handled in each guild but not all classes, this can be used to some effect. It is clear what classes should be found in each guild and what classes should not be.

Last edited by Shadow Stranger; 01-18-2014 at 10:26 AM.
Shadow Stranger is offline   Reply With Quote
Old 01-19-2014, 08:14 AM   #2
Wyvern
Ironworks Moderator
 

Join Date: January 7, 2001
Location: Rural Paradise, MI
Posts: 5,701
Default Re: Decrypting File GMDATA.PAK

Thanks for the post, Shadow Stranger!! =^..^=
__________________
Wyvern is offline   Reply With Quote
Old 01-20-2014, 02:51 AM   #3
Shadow Stranger
Avatar
 

Join Date: December 9, 2007
Posts: 594
Default Re: Decrypting File GMDATA.PAK

Ironworks Forum mod, this could solve a few problems in the quests and role ascensions.

Mixed up order of when Brimloch Roon Mage guild Living Seed and Open the Shrine quests are given, three possible approaches:
(1) Simplest, use items placed in a chest to achieve the desired result. Treant Seeds involved seem to be of the type Item 250. This should be easy.
(2) More complex, have Evil Treants summoned to the east of the Shrine.
(3) Most involved option, alter the file GMDATA.PAK to correct the original error.

Tome of Earth is found in Cet's pyramid, towards the end of the game. Hence you can't become a Zenmaster until then. One approach is to place the Tome of Earth in a chest somewhere near Brimloch Roon.

Valkyrie ascension would need to be brought forward via rewriting the GMData.pak file.
Shadow Stranger is offline   Reply With Quote
Old 01-21-2014, 10:29 AM   #4
Shadow Stranger
Avatar
 

Join Date: December 9, 2007
Posts: 594
Default Re: Decrypting File GMDATA.PAK

Dialog code, I can't see how it relates to Events.dcl.
Brimloch Roon
14 20,644 Sinsei Asami
15 22,685 Miruth

21,268 0 43 7 247 7 7 126 2 8 52 0 7 208 4 3 11
21,284 11 1 0 0 1 0 7 186 2 3 11 12 1 0 0 1
21,300 0 7 186 2 3 11 13 1 0 0 1 0 7 186 2 3
21,316 11 14 1 0 0 1 0 7 186 2 3 23 255 255 18 0

These list the four Tomes of Creation, items 267 thru 270:
11 11 1 0 0 1 0 7 186 2 3
11 12 1 0 0 1 0 7 186 2 3
11 13 1 0 0 1 0 7 186 2 3
11 14 1 0 0 1 0 7 186 2 3


21,908 0 8 109 0 43 7 247 7 8 110 0 8 111 0 8 112
21,924 0 8 113 0 9 2 114 0 115 0 116 0 10 2 18 5
21,940 67 5 35 255 255 18 0 0 1 0 40 13 0 0 1 0
21,956 13 11 1 13 12 1 13 13 1 13 14 1 41 0 13 0
21,972 42 117 0 8 118 0 8 119 0 8 120 0 8 121 0 43
21,988 7 247 7 35 255 255 18 0 0 2 0 8 122 0 8 123
22,004 0 8 124 0 8 125 0 7 247 7 8 126 0 7 247 7


21,908 0 8 109 0 43 7 247 7 8 110 0 8 111 0 8 112
21,924 0 8 113 0 9 2 114 0 115 0 116 0 10 2 18 5
110 You carry the four sacred Tomes of Creation!...
111 You are wise and all knowing; O great one...
112 I will teach you the way of the ZenMaster in exchange for the four Tomes...
113 Your wisdom; strength and power will be unequaled; great master...
114 Would you like to train to be a ZenMaster?
115 Yes
116 No

21,972 42 117 0 8 118 0 8 119 0 8 120 0 8 121 0 43
117 Zen Master Training Complete
118 Since Creation; there have only been twelve masters of Zen...
119 You are now the thirteenth; wise and all knowing...
120 The sacred books of Creation have taught you the secrets of our universe and its elements...
121 Go now; enlightened one; and use your knowledge to save our land!...

21,988 7 247 7 35 255 255 18 0 0 2 0 8 122 0 8 123
22,004 0 8 124 0 8 125 0 7 247 7 8 126 0 7 247 7
122 Then a ZenMaster you will not be...
123 I shall not offer you again...
124 For whoever holds the four tomes; shall have but one time beneath the Sun...
125 Your time has passed...

Last edited by Shadow Stranger; 01-21-2014 at 09:11 PM.
Shadow Stranger is offline   Reply With Quote
Old 01-21-2014, 09:20 PM   #5
Shadow Stranger
Avatar
 

Join Date: December 9, 2007
Posts: 594
Default Re: Decrypting File GMDATA.PAK

Here is the spreadsheet that shows all the dialog code in decimal form.
It was originally a Microsoft Works spreadsheet that was converted to Excel 1997-2000 format.

When a given record uses a Go To function, the address is probably between 0,0 and 248,7. (248,7 or whatever its maximum address is.) I doubt it references records for other shops/town halls.

I numbered all the lines in each shop record, then I sorted all the records by their line numbers. I have attached the relevant spreadsheet below.
In the first 80 Bytes you have clear a distinction between shops proper on the one hand and bars/town halls on the other. Shops only differ from each other in four bytes: 24,25 and 74,75.

From the Brimloch Roon Dojo record:
9 2 77 0 78 0 79 0 10 2 113 4 247 7 3
9 and 2 are the standard openings for a yes/no question. 113,4 is the offset where the training is cancelled. 247,7 is the second-last offset in this town record, it seems to be a general end of dialog for this town only.
77: Do you want to cancel your Monk training?
78: Yes
79: No

Here the four Tomes of Creation (11,1 thru 14,1) are being taken from the PC:
13 11 1 13 12 1 13 13 1 13 14 1
Here quest 4, Samurai training, is being recorded as completed:
35 255 255 4 0 0 2 0 40 6 0 0 1 0 41 0 6 0 42

In the upload I have included the text files for the town dialogs.
Attached Files
File Type: zip GMData.zip (673.2 KB, 1 views)

Last edited by Shadow Stranger; 09-21-2018 at 11:00 AM.
Shadow Stranger is offline   Reply With Quote
Old 08-27-2016, 10:17 AM   #6
Shadow Stranger
Avatar
 

Join Date: December 9, 2007
Posts: 594
Default Re: Decrypting File GMDATA.PAK

From post #3:

Mixed up order of when Brimloch Roon Mage guild Living Seed and Open the Shrine quests are given, three possible approaches:
(1) Simplest, use items placed in a chest to achieve the desired result. Treant Seeds involved seem to be of the type Item 250. This should be easy.
(2) More complex, have Evil Treants summoned to the east of the Shrine. This involves straightforward alterations or additions to spoke11.tol
(3) Most involved option, alter the file GMDATA.PAK to correct the original error.

Another option:
(4) Alter the GMData.pak file so that a line of dialog is replaced by Sabastaio giving the PC a Treant Seed.
Post 12 of the topic "Ironworks Forum mod for W&W" shows how you can do this.

With option (2), will the party be strong enough to fight wandering Evil Treants before they enter the Shrine of Anephas?
You can replace six of the eleven entries for Desert Raptors with the Treants.
Alternately you can add six new entries for Evil Treants. Cracking the coordinate system will tell you where to place your new Treants. In this file there are a lot of monsters whose locations are known: Bloodbeard, Talrik, Leprechaun, Oakenmir, Mystical Sphynx and 3-Headed Hydra... These can help you do the cracking.
Shadow Stranger is offline   Reply With Quote
Old 08-27-2016, 10:28 AM   #7
Wyvern
Ironworks Moderator
 

Join Date: January 7, 2001
Location: Rural Paradise, MI
Posts: 5,701
Default Re: Decrypting File GMDATA.PAK

That's great that you're still working on these things, SS!! =^..^=
__________________
Wyvern is offline   Reply With Quote
Old 08-28-2016, 10:44 PM   #8
Shadow Stranger
Avatar
 

Join Date: December 9, 2007
Posts: 594
Default Re: Decrypting File GMDATA.PAK

W&W does have some appeal for reasons that are not clear.

To check that (2) actually works, you need to do a new game: once you enter the third outdoor area you will find all its details are written into your save game!
Ditto (4) should be verified. Fortunately there is the ability to do a speed run-through.
Shadow Stranger is offline   Reply With Quote
Old 09-05-2016, 03:32 AM   #9
Shadow Stranger
Avatar
 

Join Date: December 9, 2007
Posts: 594
Default Re: Decrypting File GMDATA.PAK

Option (4) has been checked and definitely works in practice.

Option (2) worked too. Where Bark Horrors are appearing:
2 were found to the east of the Shrine of Anephas and at least 4 more were found near Talrik...
That means the party can get six Seeds before it opens the Shrine of Anephas.
With option (2), will the party be strong enough to fight wandering Evil Treants before they enter the Shrine of Anephas? Hit and run is possible here, especially once you get the Call of Home spell.

Relevant tol file is enclosed below:
Attached Files
File Type: zip TreantSeedWorkaround.zip (2.8 KB, 2 views)

Last edited by Shadow Stranger; 09-05-2016 at 09:56 AM.
Shadow Stranger is offline   Reply With Quote
Old 09-07-2016, 09:49 AM   #10
Wyvern
Ironworks Moderator
 

Join Date: January 7, 2001
Location: Rural Paradise, MI
Posts: 5,701
Default Re: Decrypting File GMDATA.PAK

THat should be super useful to any playing and running into the Seed problem!!
THANKS SS!!!
__________________
Wyvern is offline   Reply With Quote
Reply


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Decrypting D6Mons.dat Shadow Stranger Wizards & Warriors Forum 5 02-26-2014 08:56 AM
Decrypting Item.dat Shadow Stranger Wizards & Warriors Forum 4 02-24-2014 08:37 AM
Decrypting Save Game Files Shadow Stranger Wizards & Warriors Forum 12 01-28-2014 08:56 AM
Decrypting FRUA Save Game Files Shadow Stranger Dungeon Craft - RPG Game Maker 3 05-23-2009 09:18 PM
Decrypting Save Game Files: SSI Gold Box Shadow Stranger Miscellaneous Games (RPG or not) 0 05-06-2009 09:47 PM


All times are GMT -4. The time now is 08:17 AM.


Powered by vBulletin® Version 3.8.3
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
©2024 Ironworks Gaming & ©2024 The Great Escape Studios TM - All Rights Reserved