The VG Resource

Full Version: Hero of the Kingdom .tpx file extraction help
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I've been trying to extract the assets from all the Hero of the Kingdom games for the last couple of months
They've got TPX (figuring that these files are texture files), TSG files and EMT files

I've attached one of the TPX files if someone wants to have a go at figuring it out

https://mega.nz/file/XQw0AbwT#pVNHX4ZKXs...51sN7ORUtg
(09-28-2024, 09:59 AM)bdeggers Wrote: [ -> ]I've been trying to extract the assets from all the Hero of the Kingdom games for the last couple of months
They've got TPX (figuring that these files are texture files), TSG files and EMT files

I've attached one of the TPX files if someone wants to have a go at figuring it out

https://mega.nz/file/XQw0AbwT#pVNHX4ZKXs...51sN7ORUtg

Pretty easy, the header is 32 bytes while width and height are stored as 2 u32s at 0x0c and 0x10 respectively. The image data itself is BGRA8888. Did you expect something like this?
[attachment=16431]
Thank you. I was expecting something like this
I'm figuring that you edited it via a hex editor of some kind

I'm not so cluey when it comes to using it. I normally just use AssetStudio or umodel to extract the game assets
(10-01-2024, 09:28 AM)bdeggers Wrote: [ -> ]Thank you. I was expecting something like this
I'm figuring that you edited it via a hex editor of some kind

I'm not so cluey when it comes to using it. I normally just use AssetStudio or umodel to extract the game assets

I didn't really edit the file with the hex editor per se, it's more about messing around until you find the right details. After that, you import that raw data into something like PVRTexTool and you export it as a PNG.
(10-02-2024, 02:09 AM)applecuckoo Wrote: [ -> ]
(10-01-2024, 09:28 AM)bdeggers Wrote: [ -> ]Thank you. I was expecting something like this
I'm figuring that you edited it via a hex editor of some kind

I'm not so cluey when it comes to using it. I normally just use AssetStudio or umodel to extract the game assets

I didn't really edit the file with the hex editor per se, it's more about messing around until you find the right details. After that, you import that raw data into something like PVRTexTool and you export it as a PNG.

Thank you so much for your help, I ended up downloading a program called TextureFinder, and messing with the width, height and pixel format, I was able to manage to get it to work somewhat
and got it to work with PVRTex Tool too

[Image: LXD9vHN.png]
(10-02-2024, 10:40 AM)bdeggers Wrote: [ -> ]
(10-02-2024, 02:09 AM)applecuckoo Wrote: [ -> ]
(10-01-2024, 09:28 AM)bdeggers Wrote: [ -> ]Thank you. I was expecting something like this
I'm figuring that you edited it via a hex editor of some kind

I'm not so cluey when it comes to using it. I normally just use AssetStudio or umodel to extract the game assets

I didn't really edit the file with the hex editor per se, it's more about messing around until you find the right details. After that, you import that raw data into something like PVRTexTool and you export it as a PNG.

Thank you so much for your help, I ended up downloading a program called TextureFinder, and messing with the width, height and pixel format, I was able to manage to get it to work somewhat
and got it to work with PVRTex Tool too

[Image: LXD9vHN.png]
Seems like part of the character is shifted to the right? I only use TextureFinder to figure out the details and I never use it for export, mainly because TextureFinder doesn't preserve transparency.

Anyways, your PVRTexTool import settings should look like this:

[Image: uaY2JB8.png]
To recap, file size is 130x154, the data offset is 32 bytes, the color space should be set to sRGB, and the pixel format should be set up as uncompressed BGRA8888. Everything else isn't really important here.