View Single Post
Old 09-06-11, 01:19 PM   #2
aanker
Pacific Thunder
 
aanker's Avatar
 
Join Date: Apr 2004
Location: Yellow Sea
Posts: 1,896
Downloads: 236
Uploads: 14


Default

Quote:
Originally Posted by Sheppard View Post
I've looked through the SUBS.DAT file for SH:CE and deciphered maybe 65-70% of it using UGE -- Universal Game Editor, a old DOS-era editor that still works quite well for old style games.

A lot of these variables are inter-related; such as Surfaced/Submerged Power and the Surfaced/Submerged Speed Coefficients.

I've been able to edit in a pretty decent SSN-571 Nautilus into the game, but have been unable to find the numbers that handle battery capacity in SUBS.DAT; hence me posting this.
With the PTC SH1 Database project by Kim Rønhof, Kim and others deciphered just about everything possible except for creation of new Patrol Zones. We were even playing with that idea when SH4 came out.

Kim created a program that combined all of Hawks Utilities plus changing the torpedo loadout and is called the Torpedo Change Tool - TCT.

Furthermore, WEAPONT.DAT, ROSTERXX, Subs.dat, Ships.dat, RosterX.dat, Carsub.dat, and PZ.dat were all deciphered with a hex editor and almost all important bytes and bits were located for everything. The introduction:
Quote:
The PTC SH Database project main target is to decrypt the database structure of the Sh (1) game making it possible to change elements in the game.

The database structure of SH is not available, as the members of PTC do not have access to the source code. The Database projects object is to create a insight into the database structure making changes in the game possible.

Information produced by the project is the database structure as we think it is, but there is always a element of uncertainty, please keep this in mind.

A few of the database file have been analyzed by Kim’s Hex program, this program has made it relatively easy to gain insight into database such as patrol files and Data files, where different closely related data can be compared such as 2 nearly equal patrols where only firing 1 torpedo
differs, and comparing the different torpedoes (mark10/mark14 ex.)

A short test faze has evaluated changes in the databases, to se if change create the expected results (this has not always been the case)

SH Database structure : the elements :
The directory structure – under the silent hunter main directory there are the following subdirectories :
The result of all this work was the TCT.
Quote:
The Subs.dat file
The Subs.dat file starts with byte 09
Then it lists
The different Sub types in text
Each listing is 32 bytes long the ending last 4 bytes hold the address where the
Data for the specific Subtype data is.

The specific Sub type data are each 1704 bytes long.
And start as follows Dec Hex
Type - - - - Address - - - - Low Byte - - - High byte
S-Class - - - 289 - - - - - - 21 01 - - - - 00 00
Barracuda - - 1993 - - - - - C9 07 - - - - 00 00
Narwhal - - - 3697 - - - - - 71 0E - - - - 00 00
P-Class - - - 5401 - - - - - 19 15 - - - - 00 00
Salmon - - - - 7105 - - - - - C1 1B - - - - 00 00
T-Class - - - 8809 - - - - - 69 22 - - - - 00 00
Gato - - - - 10513 - - - - - 11 29 - - - - 00 00
Balao - - - - 12217 - - - - - B9 2F - - - - 00 00
Tench - - - - 13921 - - - - - 61 36 - - - - 00 00
Quote:
00000465:19 00 00 00 1C 00 00 00 A0 00 00 00 31 33 00 00 13 speed surface
00005577:18 00 00 00 1C 00 00 00 78 00 00 00 31 39 00 00 19 in text
00007281:18 00 00 00 1D 00 00 00 78 00 00 00 32 30 00 00 20
00010689:1A 00 00 00 1E 00 00 00 64 00 00 00 32 30 2E 37 20.75

00000481:00 00 00 00 00 00 39 00 00 00 00 00 00 00 00 00 9 speed subm.
00005593:00 00 00 00 00 00 38 00 00 00 00 00 00 00 00 00 8 in text
00007297:00 00 00 00 00 00 39 00 00 00 00 00 00 00 00 00 9
00010705:35 00 00 00 00 00 38 2E 37 35 00 00 00 00 00 00 8,75
for example - I don't see battery capacity....... yet... Are you past the excerpts posted above and is this type of information that you're after?

Happy Hunting!
__________________
" Bless those who serve beneath the deep,
Through lonely hours their vigil keep.
May peace their mission ever be,
Protect each one we ask of thee.
Bless those at home who wait and pray,
For their return by night and day."

aanker is offline   Reply With Quote