![]() |
|
|
#1 |
|
"I go fast!1!11!1!"
Join Date: Oct 2008
Location: IA, USA
Posts: 10,583 (6.28/day)
Thanks: 1,755
Thanked 2,600 Times in 1,962 Posts
|
Tropico 3/4 HPK Archiver
Everything for Tropico 3 are stored in HPK files except movies. This application can extract and archive data into and out of the HPK formatted file.
![]() You need .NET Framework 3.5 or Mono to run it. 1.0.3: Tons of bug fixes including the ability to decompress/extract challenges and ShaderCache.hpk. 1.0.2: No longer crashes if the output directory doesn't exist. It will simply create it. 1.0.1: Added bug fixes for abnormal files in Game.hpk. 1.0.0: Fixed a bug with the time stamps when archiving and also added support for Tropico 4 (experimental). Beta 7: Fixed a bug in the archival code. Beta 6: Archive feature is now functional, it automatically saves/loads settings, and many other tweaks. Beta 5: Overhauled the GUI. It now shows statistics about the file and how far along it is while extracting. Beta 4: It applies the "_filedates" to the files (modified date) and deletes the _filedates file because it is now irrelevant. Made the Zip decompression algorithm more efficient (one output stream per file). Beta 3: Added Unix support for use on Mono. Beta 2: Extracts all files successfully via C#ZipLib. Beta 1: Erred on some files during extracting using zlib.
__________________
Golden Rule of Programming: Never assume. try { SteamDownload(); } catch (Steamception ex) { RageQuit(); } Last edited by FordGT90Concept; Feb 1, 2013 at 01:52 PM. |
|
|
|
|
|
#2 |
|
"I go fast!1!11!1!"
Join Date: Oct 2008
Location: IA, USA
Posts: 10,583 (6.28/day)
Thanks: 1,755
Thanked 2,600 Times in 1,962 Posts
|
As far as I can tell, Extracting is complete in beta 4. Next is archiving, followed by multithreading and other GUI improvements.
__________________
Golden Rule of Programming: Never assume. try { SteamDownload(); } catch (Steamception ex) { RageQuit(); } |
|
|
|
| The Following User Says Thank You to FordGT90Concept For This Useful Post: |
|
|
#3 |
![]() Join Date: Jul 2008
Location: Clifton Park, NY
Posts: 3,131 (1.77/day)
Thanks: 98
Thanked 612 Times in 459 Posts
|
i dont get why we'd need this
__________________
|
|
|
|
|
|
#4 |
|
"I go fast!1!11!1!"
Join Date: Oct 2008
Location: IA, USA
Posts: 10,583 (6.28/day)
Thanks: 1,755
Thanked 2,600 Times in 1,962 Posts
|
If you want to mod the game, you need it.
Beta 5 uploaded. I'm going to start work on the archiving component soon.
__________________
Golden Rule of Programming: Never assume. try { SteamDownload(); } catch (Steamception ex) { RageQuit(); } |
|
|
|
| The Following User Says Thank You to FordGT90Concept For This Useful Post: |
|
|
#5 |
|
"I go fast!1!11!1!"
Join Date: Oct 2008
Location: IA, USA
Posts: 10,583 (6.28/day)
Thanks: 1,755
Thanked 2,600 Times in 1,962 Posts
|
Beta 6 upload. The application is now fully functional and fully featured.
__________________
Golden Rule of Programming: Never assume. try { SteamDownload(); } catch (Steamception ex) { RageQuit(); } |
|
|
|
| The Following User Says Thank You to FordGT90Concept For This Useful Post: |
|
|
#6 |
|
Join Date: Oct 2010
Posts: 1 (0.00/day)
Thanks: 0
Thanked 0 Times in 0 Posts
|
Thanks
Thanks for this great tool. I was able to extract the music from the game using this.
|
|
|
|
|
|
#7 |
|
"I go fast!1!11!1!"
Join Date: Oct 2008
Location: IA, USA
Posts: 10,583 (6.28/day)
Thanks: 1,755
Thanked 2,600 Times in 1,962 Posts
|
Heh, finally someone uses it. XD
You are welcome.
__________________
Golden Rule of Programming: Never assume. try { SteamDownload(); } catch (Steamception ex) { RageQuit(); } |
|
|
|
| The Following User Says Thank You to FordGT90Concept For This Useful Post: |
|
|
#8 |
|
Join Date: Oct 2010
Posts: 1 (0.00/day)
Thanks: 0
Thanked 0 Times in 0 Posts
|
HEY FORDGT90!
This is going to make you double-take, but it's Michael Adames. I used to moderate Hardware Analysis. Ya. Big Tropico 3 player here, really enjoying the game! Found myself quite bothered with El Presidente's annoying sayings as well as some of the ambient files such as the seagull and rooster. This tool worked perfectly for me and did just as you said. This has made the game infinitely more enjoyable, thanks again. When I downloaded this and saw your name I was like "OH SHI---" clicked on your name and recognized a few people from Hardware Analysis and knew it was you. Hope all is well with you. Thanks again for the tool. |
|
|
|
|
|
#9 |
|
"I go fast!1!11!1!"
Join Date: Oct 2008
Location: IA, USA
Posts: 10,583 (6.28/day)
Thanks: 1,755
Thanked 2,600 Times in 1,962 Posts
|
Heh, yeah I remember you. Stick around.
__________________
Golden Rule of Programming: Never assume. try { SteamDownload(); } catch (Steamception ex) { RageQuit(); } |
|
|
|
| The Following User Says Thank You to FordGT90Concept For This Useful Post: |
|
|
#10 |
|
Join Date: Nov 2010
Posts: 4 (0.00/day)
Thanks: 9
Thanked 1 Time in 1 Post
|
Hello, thank you for this program, but I need two components to the archive file .hpk someone advise me how to do it?
Please reply. Thank I need to archive two folders. How do I do? it must be in format .hpk Last edited by Ignasius; Nov 6, 2010 at 01:00 PM. Reason: add text |
|
|
|
|
|
#11 |
|
"I go fast!1!11!1!"
Join Date: Oct 2008
Location: IA, USA
Posts: 10,583 (6.28/day)
Thanks: 1,755
Thanked 2,600 Times in 1,962 Posts
|
Code:
selected folder
-> folder 1
-> file 1
-> file 2
-> folder 2
-> file 1
-> file 2
-> file 1
-> file 2
__________________
Golden Rule of Programming: Never assume. try { SteamDownload(); } catch (Steamception ex) { RageQuit(); } |
|
|
|
| The Following User Says Thank You to FordGT90Concept For This Useful Post: |
|
|
#12 |
|
Join Date: Nov 2010
Posts: 4 (0.00/day)
Thanks: 9
Thanked 1 Time in 1 Post
|
Please, try to decompress and re-archiving.
Please try this file. HPK unpack and wrap http://www.megaupload.com/?d=S2D8ROSO after unpacking, you will receive two components Last edited by Ignasius; Nov 6, 2010 at 05:38 PM. Reason: add text |
|
|
|
|
|
#13 |
|
"I go fast!1!11!1!"
Join Date: Oct 2008
Location: IA, USA
Posts: 10,583 (6.28/day)
Thanks: 1,755
Thanked 2,600 Times in 1,962 Posts
|
It says it is unavailable.
__________________
Golden Rule of Programming: Never assume. try { SteamDownload(); } catch (Steamception ex) { RageQuit(); } |
|
|
|
| The Following User Says Thank You to FordGT90Concept For This Useful Post: |
|
|
#14 |
|
Join Date: Nov 2010
Posts: 4 (0.00/day)
Thanks: 9
Thanked 1 Time in 1 Post
|
download here: http://no-mercy.byl.cz/Data.hpk
Last edited by Ignasius; Nov 6, 2010 at 05:54 PM. |
|
|
|
|
|
#15 |
|
"I go fast!1!11!1!"
Join Date: Oct 2008
Location: IA, USA
Posts: 10,583 (6.28/day)
Thanks: 1,755
Thanked 2,600 Times in 1,962 Posts
|
Ah, I see the problem. Archive should not include the given directory, only everything inside. For instance, if you extracted to C:\Stuff and you archived the contents of C:\Stuff, "Stuff" shouldn't appear in the output HPK file where currently it does.
I am working on it and will get a fix up as soon as possible but it could take a week or two. Edit: It was easier to fix than I thought but I'm not 100% certain Tropico will like it. I attached the modified version to this post. Try it out and let me know if it works as expected or not (specifically, will Tropico read the outputs from it).
__________________
Golden Rule of Programming: Never assume. try { SteamDownload(); } catch (Steamception ex) { RageQuit(); } Last edited by FordGT90Concept; Nov 7, 2010 at 09:59 AM. |
|
|
|
| The Following User Says Thank You to FordGT90Concept For This Useful Post: |
|
|
#16 |
|
Join Date: Nov 2010
Posts: 4 (0.00/day)
Thanks: 9
Thanked 1 Time in 1 Post
|
Yes, this correction is already functional
Thank you so much, now you can, pack more components into a file .hpk game is fully functional, even after adjusting file I'm working on another language version in this game thanks very much Sincerely, Ignasius Czech Republic |
|
|
|
| The Following User Says Thank You to Ignasius For This Useful Post: |
|
|
#17 |
|
Join Date: Nov 2010
Posts: 1 (0.00/day)
Thanks: 1
Thanked 0 Times in 0 Posts
|
Music Pack
To make sure you know your work is appreciated I wanted to let you know that your tool is the only way to add music to Tropico 3 and that I am very grateful for your efforts.
![]() I've been playing Tropico 3 for just a few hours and already the (offensively small) music track is getting repetitive, so you just made T3 infinitely more fun by allowing me to add more music to the game. I am at work right now, but as soon as I get home I'll be installing this program and adding more songs to the game. Thank you! If you happen to have your own, custom, Tropico3 music pack I'd LOVE for you to upload it btw. Edit: I almost forgot, people on Steam Forums appreciate your work too btw. Last edited by kenji_03; Nov 29, 2010 at 09:14 AM. Reason: adding the "edit" |
|
|
|
|
|
#18 |
|
"I go fast!1!11!1!"
Join Date: Oct 2008
Location: IA, USA
Posts: 10,583 (6.28/day)
Thanks: 1,755
Thanked 2,600 Times in 1,962 Posts
|
I don't have a custom music pack but I know there are instructions on the official forum for how to add Tropico (original game) music to Tropico 3 if you want to do that.
__________________
Golden Rule of Programming: Never assume. try { SteamDownload(); } catch (Steamception ex) { RageQuit(); } |
|
|
|
|
|
#19 |
|
"I go fast!1!11!1!"
Join Date: Oct 2008
Location: IA, USA
Posts: 10,583 (6.28/day)
Thanks: 1,755
Thanked 2,600 Times in 1,962 Posts
|
Updated to support Tropico 4, theoretically.
Edit: FYI, the only difference is in the _filedates file. All the filetimes in Tropico 3 are standard Windows FileTimes. In Tropico 4, it appears they divided them by 2000 so that's what I did. The reason why it crashed was because without multiplying by 2000, it would produce an invalid filetime so when it tries to work with it when archiving, the numbers would be all wrong. It was a pretty easy fix but a very strange change they made there.
__________________
Golden Rule of Programming: Never assume. try { SteamDownload(); } catch (Steamception ex) { RageQuit(); } Last edited by FordGT90Concept; Sep 6, 2011 at 08:42 AM. |
|
|
|
|
|
#20 |
|
Join Date: Sep 2011
Posts: 1 (0.00/day)
Thanks: 1
Thanked 0 Times in 0 Posts
|
It's a nice tool you've made, but it seems it cant extract big files (1mb+), or is it only bugging on my computer? Been trying to extract some hpk extension files in AppData/Roaming/Tropico 4/Challenges.
|
|
|
|
|
|
#21 |
|
"I go fast!1!11!1!"
Join Date: Oct 2008
Location: IA, USA
Posts: 10,583 (6.28/day)
Thanks: 1,755
Thanked 2,600 Times in 1,962 Posts
|
I don't even have an Challenges folder. I'll need specifics in order to debug it (how you obtained one that fails and the name of it).
__________________
Golden Rule of Programming: Never assume. try { SteamDownload(); } catch (Steamception ex) { RageQuit(); } |
|
|
|
|
|
#22 |
|
Join Date: Apr 2012
Posts: 2 (0.00/day)
Thanks: 0
Thanked 0 Times in 0 Posts
|
Are you going to update it so it works with modern times? Trying to extract Game.hpk but the program just keep crashing all the times.
|
|
|
|
|
|
#23 |
|
"I go fast!1!11!1!"
Join Date: Oct 2008
Location: IA, USA
Posts: 10,583 (6.28/day)
Thanks: 1,755
Thanked 2,600 Times in 1,962 Posts
|
I don't have Modern Times yet (in transit). I could take a look at it when it arrives.
__________________
Golden Rule of Programming: Never assume. try { SteamDownload(); } catch (Steamception ex) { RageQuit(); } |
|
|
|
|
|
#24 |
|
"I go fast!1!11!1!"
Join Date: Oct 2008
Location: IA, USA
Posts: 10,583 (6.28/day)
Thanks: 1,755
Thanked 2,600 Times in 1,962 Posts
|
I think I see the problem. There is a file (Game\CommonEntities.txt) that is...messed up. The file is supposedly compressed but compressed files require at least 16 bytes just for the header and more for the data. This has 12 bytes total (header + data) making my algorithm run into the next file entry causing it to eventually crash when. The data literally is: 0000000000800000
That 8 in there is suspicious (value of 128) but I don't know if that belongs in the file or if it is part of the broken header. I think what I'm going to do is simply create an empty file and hopefully all will be good. Will edit this post soon... Edit: The 8 is the chunksize which is more or less always set to 32768. In other words, it is, in fact, a blank file. There's a problem with another file...a batch file (HGO\SRP\srp-init.bat) which has the ZLIB header for compression but is, in fact, not compressed. I'm trying to find a solution that problem now. Other than those two hiccups, it appears to be working fine on Game.hpk. Edit: To address the batch problem, it looks for that file specifically, checks if it is 70 bytes in length, compares it with what it stores internally, if a match, it cuts off the ZLIB header and outputs the remaining 54 bytes. If not a match, it outputs it normally. In both cases, I would think that Tropico would crash if it tried to access them. Fortunately, the batch file looks like a dev tool and the text file is useless so it doesn't access them. I'll update the op with the updated executable shortly.
__________________
Golden Rule of Programming: Never assume. try { SteamDownload(); } catch (Steamception ex) { RageQuit(); } Last edited by FordGT90Concept; Apr 11, 2012 at 01:39 AM. |
|
|
|
|
|
#25 |
|
Join Date: Apr 2012
Posts: 2 (0.00/day)
Thanks: 0
Thanked 0 Times in 0 Posts
|
Thanks for the update, and for the great tool.
|
|
|
|
![]() |
| Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
| Thread Tools | |
|
|
Similar Threads
|
||||
| Thread | Thread Starter | Forum | Replies | Last Post |
| Tropico 3 Decompress Config | FordGT90Concept | Games | 6 | May 2, 2012 03:49 PM |
| Tropico 4 Confirmed! | TheMailMan78 | Games | 31 | Aug 27, 2011 07:16 AM |
| EVERCOOL HPK-10025EA Low-Profile | btarunr | Reviews | 5 | Apr 4, 2011 07:12 AM |
| Tropico 3 | MRCL | Games | 56 | Jan 11, 2010 04:30 AM |
| Tropico 3 PC Demo with screens! | TheMailMan78 | Games | 7 | Sep 15, 2009 06:43 PM |