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.

recompressing into .pxp files (Castlestorm)

Featured Replies

  • Author
  • Localization

firas724, posted Tue May 05, 2015 7:55 am (5053)


Hi guys, I recently was interested in modding Castle storm and play around with the stats and game rules, I managed to decompress it using quickBMS, first using this code to unpack the .pxp
Code:
# Extracts the compressed resources from the .PXP
# file but does NOT decompress them
idstring "PX"
get DUMMY short
get INFO_SIZE long
get DATA_OFFSET long
get FILES long
get DUMMY long
for i = 0 < FILES
    get OFFSET long
    get SIZE long
    get TYPE byte
    get NAMESZ byte
    getdstring NAME NAMESZ
    padding 4
    get ZSIZE long
   log NAME OFFSET ZSIZE
next i


Then I used this code to decompress the files the were in .pxp
Code:
# Zen Studios .PXP file decompresser
# (CastleStorm, Pinball FX2)
# Adrian Dale 09/10/2013
#
# Needs NeoWizLib.dll provided by Ekey
# http://forum.xentax.com/viewtopic.php?f=10&t=10654
#
# This script decompresses a single resource file that has previously
# been extracted from a .PXP file.
# This has been tested with files from Pinball FX2 and appears to
# successfully decompress most of the files in the archives.
log MEMORY_FILE3 0 0

do
  get CHUNKTYPE byte
  If CHUNKTYPE == 0x03
    get ZSIZE threebyte
    SavePos IN_OFFSET
   set SIZE long 0x80000
   #print "%CHUNKTYPE% %ZSIZE|hex% %SIZE|hex% %IN_OFFSET|hex%\n"
    log MEMORY_FILE IN_OFFSET ZSIZE
    putvarchr MEMORY_FILE2 SIZE 0
    CallDLL NeoWizLib.dll NWDecompress stdcall "" MEMORY_FILE MEMORY_FILE2 SIZE
   
   math IN_OFFSET ZSIZE
    goto IN_OFFSET
   
  ElseIf CHUNKTYPE == 0x04
    get SIZE threebyte
   get ZSIZE threebyte
   SavePos IN_OFFSET
   #print "%CHUNKTYPE% %SIZE% %ZSIZE|hex% %IN_OFFSET|hex%\n"
   log MEMORY_FILE IN_OFFSET ZSIZE
   putvarchr MEMORY_FILE2 SIZE 0
    CallDLL NeoWizLib.dll NWDecompress stdcall "" MEMORY_FILE MEMORY_FILE2 SIZE
  Endif
 
  # Now tag MEMORY_FILE2, which is the decompressed chunk
  # onto the end of MEMORY_FILE3
  append
  log MEMORY_FILE3 0 SIZE MEMORY_FILE2
  append
 
while CHUNKTYPE != 0x04

get NAME basename
get EXT extension
string NAME = "_unpacked."
string NAME = EXT

get FULL_SIZE asize MEMORY_FILE3
log NAME 0 FULL_SIZE MEMORY_FILE3


Until now I have only decompressed the .cfg , and modified the contents, then tried to pack it again into .pxp, by just packing it into a different extension then renaming it,but ultimately failed. I really would appreciate it if someone would give me a way of re-compressing the .cfg into its original form, and packing it into the original extension settings.
  • Author
  • Localization

firas724, posted Fri Apr 22, 2016 11:16 pm (12779)


Hi guys,

I came back to castlestorm, and I want to know if a solution to the problem has been found ( a way to compress into pxp).
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.