Skip to content
View in the app

A better way to browse. Learn more.

ResHax

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.
Help us keep the site running.

Commandos 3 - HD Remaster game.pak

Featured Replies

  • Author
  • Localization

Slappy, posted Wed Aug 31, 2022 1:51 am (73266)


The remastered version of the game uses different format of the game archives.

Can anyone unpack/repack this new format? (preview attached)

File is huge (1.7 GB) but there is a free demo version available.

Commandos 3 HD Remaster game.pak
  • Author
  • Localization

herbert3000, posted Sun Sep 04, 2022 7:07 pm (73328)


Here you go!

The SDPC files are compressed though, they require further research.

Code:
# Commandos 3 - HD Remaster
#    \Data\Game.pak
# script for QuickBMS http://quickbms.aluigi.org

idstring "30KP"
endian little

get UNKNOWN long # 00000000
get FILE_COUNT long

for i = 0 < FILE_COUNT
   get ID long
   get UNKNOWN long # 00000000
   get OFFSET long
   get UNKNOWN long  # 00000000
   get SIZE long
   get UNKNOWN long  # 00000000 or 80000000
   
   savepos HEADER
   goto OFFSET
   
   set NAME string "OUT_"
   string NAME = i
   
   getdstring MAGIC 4
   if MAGIC == "SDPC"
      string NAME = ".sdpc"
   elif MAGIC == "DDS "
      string NAME = ".dds"
   elif MAGIC == "RIFF"
      string NAME = ".wav"
   elif MAGIC == "GFRL"
      string NAME = ".grl"
   elif MAGIC == "[sha"
      string NAME = ".shader"
   else
      string NAME = ".txt"
   endif
   
   log NAME OFFSET SIZE
   
   goto HEADER
next i

c3hd_pak.bms

  • Author
  • Localization

herbert3000, posted Sun Sep 04, 2022 9:00 pm (73334)


Here are some of the compressed files.
I've also added the files from the original Commandos 3 for reference.
  • Author
  • Localization

Slappy, posted Mon Sep 05, 2022 8:35 am (73340)


@herbert3000 amazing, thanks!

I found the exact compressed file for Missiones.dat (both attached)

How to detect the file compression? Looks like some LZ to me. (23 kB to 4.6 kB)

Image
  • Author
  • Localization

herbert3000, posted Tue Sep 06, 2022 9:12 pm (73362)


Found the compression algorithm! It's the LZO1X compression algorithm, whatever the F that means.
Used this awesome guide to find it: https://zenhax.com/viewtopic.php?t=23

Here's the updated script:
Code:
# Commandos 3 - HD Remaster
#    \Data\Game.pak
# script for QuickBMS http://quickbms.aluigi.org
#   2022-09-07

idstring "30KP"
endian little
comtype COMP_LZO1X

get UNKNOWN long # 00000000
get FILE_COUNT long

for i = 0 < FILE_COUNT
   get ID long
   get UNKNOWN long # 00000000
   get OFFSET longlong
   get SIZE long
   get UNKNOWN long  # 00000000=compressed 80000000=raw
   
   savepos HEADER
   goto OFFSET
   
   set NAME string "OUT_"
   string NAME = i
   
   getdstring MAGIC 4
   if MAGIC == "SDPC"
      string NAME = ".sdpc"
      
      get UNCOMPRESSED_SIZE long
      math OFFSET = 8
      clog MEMORY_FILE OFFSET SIZE UNCOMPRESSED_SIZE
      
      getdstring MAGIC2 4 MEMORY_FILE
      if MAGIC2 == "DDS "
         string NAME = ".dds"
      elif MAGIC2 == "XPrt"
         string NAME = ".xprt"
      elif MAGIC2 == "DXBC"
         string NAME = ".dxbc"
      elif MAGIC2 == "LDMB"
         string NAME = ".abi"   # C3 file format
      elif MAGIC2 == "2IBM"
         string NAME = ".mbi"   # C3 file format
      elif MAGIC2 == "BSMB"
         string NAME = ".bsmb"   # C3 file format
      elif MAGIC2 == "GFRL"
         string NAME = ".grl"   # C3 file format
      elif MAGIC2 == "TOKE"
         string NAME = ".mac"   # C3 file format
      elif MAGIC2 == "[sha"
         string NAME = ".shader"
      elif MAGIC2 == "#ver"
         string NAME = ".glsl"
      elif MAGIC2 == "-- L"
         string NAME = ".lua"
      else
         goto 0 MEMORY_FILE
         getdstring MAGIC2 1 MEMORY_FILE
         if  MAGIC2 == "["   # C3 script
            string NAME = ".txt"
         else
            goto 0 MEMORY_FILE
            get v0 long MEMORY_FILE
            get v1 long MEMORY_FILE
            if v0 == 2 && v1 == 1
               string NAME = ".sec"   # C3 file format
            else
               string NAME = ".unk"
            endif
         endif
      endif
      
      log NAME 0 UNCOMPRESSED_SIZE MEMORY_FILE
      
   elif MAGIC == "DDS "
      string NAME = ".dds"
   elif MAGIC == "RIFF"
      string NAME = ".wav"
   elif MAGIC == "GFRL"
      string NAME = ".grl"
   elif MAGIC == "[sha"
      string NAME = ".shader"
   else
      string NAME = ".txt"
   endif
   
   if MAGIC != "SDPC"
      log NAME OFFSET SIZE
   endif
   
   goto HEADER
next i
Guest
This topic is now closed to further replies.

Account

Navigation

Search

Search

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.