SUBSIM Radio Room Forums

SUBSIM Radio Room Forums (https://www.subsim.com/radioroom/index.php)
-   Classic Subsims (https://www.subsim.com/radioroom/forumdisplay.php?f=173)
-   -   Command Aces of the Deep (Win95) - HexEdit questions (https://www.subsim.com/radioroom/showthread.php?t=240392)

Jeff-Groves 12-15-21 02:12 PM

Just having a couple days checking somethings and reading from past information?
I know the Subs identifications and so forth.
I can see those in all the different files. Which leads me to think One could change things up in a lot of different ways.

I also saw model information in some files. So with some work? Could export and possibly import new 3D models.

Also have a very good clue on the compression used for the DYN files.

Silent Otto 12-15-21 10:05 PM

Hi guys,


Just getting back to this forum today, so perhaps I can add to what Steven wrote up in the past. I am still experimenting with some of the codes to see what I can change and how those changes take affect throughout the game but, I am finding out some of the changes prevent other things from occurring as they normally would.


I'll get back on this shortly.


Tim

Silent Otto 12-15-21 10:33 PM

First,


In case someone doesn't know...


If you look at the .sav files in CAOD, it's all gibberish. As Windows doesn't have a file program set to open these type files, you need to download a Hex Editor to view the files.


Here's a basic editor, it's freeware and fairly easy to use. I'll list a couple of links and you can decide for yourselves. No ads, appears adware and malware safe!


https://mh-nexus.de/en/hxd/ (one I used)
https://download.cnet.com/HxD-Hex-Ed...-10891068.html




When making changes to the .sav file, it will automatically create a .sav.bak file and add it to the game files. The .bak is the original file, so if you manage to screw something up, the .bak will put you back to where you started; the game doesn't recognize the .sav.bak so you have to delete the .bak portion of the file name in order for the game to function with that file.

Silent Otto 12-15-21 11:18 PM

2 Attachment(s)
Working with Stevens information here:
http://www.subsim.com/ssr/tipaod4.html


One of the things that always bothered me was the lack of promotion beyond Korvettenkapitan, which occurs fairly early in the game career. Understand, a U-boat was a "small" command and small commands usually rate a more junior officer for C.O. (normally LCDR. and below). As Korvettenkapitan is equivalent to LCDR...


Still, there were Fregattenkapitans that commanded U-boats from early on. Less so for Leutnants which came later (circa '44) and were limited to relocating boats back to Germany after the allied invasion.



Here's a question: In AOD, do you get the options to have ranks of Leutnant (Ensign) and Fregattankapitan (Commander) in that game?


I ask, as the files for CAOD do list both ranks in the file shell text, but no where does the game actually offer you either of these ranks in play. This leads me to think that if they were in AOD originally, the decision was made to remove them from CAOD as these ranks were not as common as the Oberleutnant to Korvettenkapitan ranks. Or, as CAOD hit the streets just before the Christmas holidays, someone pushed to get the game out before the software engineers could work out all the bugs and include all the items. We may never know but, that could explain why there are so many bugs and why Sierra could not control the quality between products.



I'll include some snippet attachements but at the allowed file size here, they may be small to read, sorry.

Silent Otto 12-16-21 12:42 AM

3 Attachment(s)
Staying with "Rank" for a moment.


Yes, I know the images are small but you get the idea...


As per Steven's notes, you can change the ranks in the game and the changes to line 48 (00000040) on the left and (08) on top will change the rank. That change will register on both the "Patrol Summary" and "Career" score pages.


HOWEVER...


What I am seeing is that once, that change alone is completed, that rank will remain the same throughout the game and you will not automatically promote. I have played two games now, starting out once as a Leutnant and once as a Kapitanleutnant and after 11 patrols, not a single promotion!


Considering, a U-boat Kapitan being awarded the Knight's Cross or above would have been promoted on the spot at the Leutnant level and after 11 patrols wearing the diamonds level award, still nothing in either case??


I was hoping to see the normal accession that one normally sees to the next higher ranks around patrols 4 or 5 (Oblt to Kptlt) and again around patrols 14 or 15 (Kptlt to KrvKpt), with the idea if I started out as Kptlt, I eventually would see FrgKpt. No such luck.

Silent Otto 12-16-21 01:09 AM

3 Attachment(s)
I think somehow and somewhere, these are tied in and in order for the rank changes to modify, the code needs to change wherever these lines are as well.

Silent Otto 12-16-21 01:24 AM

1 Attachment(s)
Last note on "Ranks" and I'll wait to hear what others might think or know.


When selecting a "New career" to start a new game, you are automatically given the rank of Oberleutnant. If you want to change rank prior to the first patrol, you need to hex edit line 48 in the save file before actually starting play.


I wonder, if we can change that opening page coding, will it affect everything else and then everything falls into place?

Jeff-Groves 12-17-21 12:19 PM

Leutnant
Oberleutnant
Kapitanleutnant
Korvettenkapitan
Fregattenkapitan

Are the only things I found in the Subsim.exe

Jeff-Groves 12-21-21 02:18 PM

Quote:

Originally Posted by Silent Otto (Post 2783172)
you need to hex edit line 48 in the save file

I think you mean an absolute address and not just a LINE.

Silent Otto 12-23-21 03:05 AM

Hi Jeff,


Yes, I just don't get too detailed here as most seem uninterested in hex editing or lost completely by it and just want to play the game and even that seems to be few these days.


I'll PM you a bit later today, time depending and show some things I've found out. :up:


Tim

Silent Otto 12-23-21 03:18 AM

4 Attachment(s)
I see Andreas is working some image files so thought maybe there are a few more people working on things and I'll add some of my findings.

You can change a lot in the game files, like Captain's Log, Patrol Summaries, Career Scores, etc. I am trying to figure out more along the lines of what Andreas is doing with images.

Here's and example: Gunther Prien in U-47:


If you compare the Hex addresses with the options Steven Hildebrand listed, you can see you can adjust quite a bit. Once this takes, as in this case, Prien returns to get awarded the Knight's Cross and address 49 will change to 01.

Silent Otto 12-23-21 03:35 AM

1 Attachment(s)
Letters and numbers.


Numbering is patterned in Hex. I'll show some examples and you can see the pattern to apply as you see fit.


00 = 0 ... 10 = 16 …... Some random examples: 30 = 48
01 = 1 ... 11 = 17 …... 40 = 64
02 = 2 ... 12 = 18 …... 60 = 96
03 = 3 ... 13 = 19 …... 71 = 113
04 = 4 ... 14 = 20 …... 72 = 114
05 = 5 ... 15 = 21
06 = 6 ... 16 = 22
07 = 7 ... 17 = 23 …... You get the idea.
08 = 8 ... 18 = 24
09 = 9 ... 19 = 25
0A = 10 .. 1A = 26
0B = 11 .. 1B = 27
0C = 12 .. 1C = 28
0D = 13 .. 1D = 29
0E = 14 .. 1E = 30
0F = 15 .. 1F = 31


Letter's are numbered both upper and lower case; see attached below.

Jeff-Groves 12-24-21 12:17 PM

A lot of people freak when they see things in Hex!
:haha:
It's like reading a different language! Now I've been working in Hex for over 30+ years! I can pick out patterns as to how a file is constructed. There is usually a lot of information about the file size, content numbers, how much data to read, and so on. Usually the header is a Map of sorts.
Then you just need to follow the data. That may mean looking at a bunch of different files to get the 'BIG' picture.

In one of your images above you have a captains log. I'd like the save game with a captains log image that goes with it!
Cross referencing other files? I may be able to track down where that is in the save game.

Jeff-Groves 12-24-21 02:28 PM

The AOD and ShellVol.dyn files are defiantly packed files.
SO We need to unpack them then decompress things like the BMP files in them.

Jeff-Groves 12-25-21 09:56 AM

Game Extractor will dump the dyn files.
It will not repack them.
Might be able to figure out how to repack by studying the format as the .dyn is not compressed.

http://www.watto.org/game_extractor.html

Here's the file format specs for the .dyn files

20 - Header (Dynamix Volume File) + null
2 - Unknown
4 - Unknown
2 - Unknown
2 - Unknown
2 - Unknown
4 - numFiles

// for each file
4 - Unknown

// for each file
13 - Filename (null)
4 - File Size
X - File Data
0-3 - null padding (to a multiple of 4 bytes)

Jeff-Groves 12-25-21 12:02 PM

From Steve's information...............
"On the save file I used for exploration, my total tonnage sunk was 181,244. This value, expressed in Hexidecimal, is "02 C3 FC" but in the gamesave file, it was written as "FC C3 02." My career score was 92270, or "01 68 6E" but it was written as "6E 68 01." Weird, eh??"

It's merely a matter of Endian set on your Editor for some things.
Little Endian (intel) or Big Endian (Motorola)
So as We look at the files in Hex We may need to switch back and forth to get the true answer for UnKnown Values.

Nice thing about working with Scripts and Templates in 010 is that I can account for Endian at anytime.
Swapping Endian in files is not that uncommon by the way.

Now if you want to know where the term 'Endian' came from? I can tell you that also!
:har:

Jeff-Groves 12-25-21 02:37 PM

I know there's data not defined in the format for the .dyn files.
I took several bytes out and the file will not open in Game Extracter.

Jeff-Groves 12-25-21 04:46 PM

So... are the HIST??.GAM files what controls Historic Missions?

Silent Otto 12-25-21 10:37 PM

That would be my guess, though I haven't played around with the hex files. If I remember correctly, historic games would not need to modify anything like player's name, hull numbers or homeports, type of boat, etc.

Game play is what the historic mission is set as, the only variable is the player's use of the assigned boat as far as course, whether or not he finds the convoy and his attacking results.

I don't remember offhand if you get any award page/s after a successful mission or not? Been awhile since playing historic missions, sorry.

BTW, two emails sent on the other files.
Tim


All times are GMT -5. The time now is 07:06 AM.

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright © 1995- 2025 Subsim®
"Subsim" is a registered trademark, all rights reserved.