Jump to content

Beyond DefaultGameCore.ini - Analyzing the Game Scripts


Beknatok

Recommended Posts

Use Gildor's Decompress tool to unpack the UPK.

Fullstop.

 

I can get the decompress tool.

I'm very familiar with batch files. Have been since DOS 3 or so.

However, decompress.exe does not come with any readme file nor does it display it's commandline parameters when asked to.

 

I have seen a post claiming that you need an -Izo (izo) parameter and another post claiming that it needs an -lzo (LZO) parameter.

 

Whether I use none or either, whether I state an output file / directory or not, I get no output whatsoever.

 

And I'm sorry but I don't speak russian so the author's forum isn't very useful to me.

 

 

Could someone please post the complete commandline to decompress the .upk file?

 

 

I'm a scripter but I'm no programmer and I haven't touched any Unreal thing before...

Link to comment
Share on other sites

  • Replies 102
  • Created
  • Last Reply

Top Posters In This Topic

For decompressing with that tool, what worked for me was

 

decompress -export -all -lzo xcomgame.upk

 

That's lzo with lowercase L. But I haven't been able to get UE Explorer to show me anything. I'm well familiar with programming, but also haven't touched the unreal engine before.

Link to comment
Share on other sites

But I haven't been able to get UE Explorer to show me anything. I'm well familiar with programming, but also haven't touched the unreal engine before.

 

If you're using Unreal Explorer, you should be able to see an objects tab on the left upper side of the window once you open the decompressed XComGame.upk. It's just under the File option.

Link to comment
Share on other sites

Ok, I've figured out how to edit the uncompressed UPK itself with hex editting, comparing the extracted .CLASS files, matching their hex values with the ones in the UPK and then making the changes there using UltraEdit. The problem is that the game requires the compressed UPK to run, and won't work with the uncompressed one. Is there anyway to re-compress the UPK?

 

The UDK has something called Unreal Frontend in it, which can apparently cook UPK files. I don't have the UDK installed (and don't want to download and install the whole damn thing), so I can't check if it works with XCOM packages. If you have the UDK installed, you could give it a try. This article talks about it.

 

If it works for you, I'd love to have a bit more detail on how you edited the UPKs. I want to fix the gender ratios so they're 50/50 (the constant appears in XGCharacterGenerator). Hopefully you aren't just relying on the constants being unique so you can search for them, because this one is "3" and that's not quite unique ;)

Link to comment
Share on other sites

If it works for you, I'd love to have a bit more detail on how you edited the UPKs. I want to fix the gender ratios so they're 50/50 (the constant appears in XGCharacterGenerator). Hopefully you aren't just relying on the constants being unique so you can search for them, because this one is "3" and that's not quite unique ;)

 

Don't have UDK at the moment, but I'll see if I can pick it up. What I did was I opened the Class files (example: Base_Num_Rockets) with a hex editor and copied the entire string. Searching for that in the decompressed UPK proved that the strings are unique.

Link to comment
Share on other sites

. Is there anyway to re-compress the UPK?

 

That is the big problem right here.

Capable people like dreadylein or beknatok could tell you more about it, but the bottom line is, no we can't. And it seems unlikely we will be able to anytime soon.

 

We're in luck. I figured out a way to get the game to load the files uncompressed. :D

 

Just delete/rename the corresponding <filename>.upk.uncompressed_size file in the CookedPCConsole folder.

 

After modifying it, you'll also have to hack the exe to change the SHA-1 hash value for the file.

Edited by Daemonjax
Link to comment
Share on other sites

We're in luck. I figured out a way to get the game to load the files uncompressed. :D

 

Just delete/rename the corresponding <filename>.upk.uncompressed_size file in the CookedPCConsole folder.

 

After modifying it, you'll also have to hack the exe to change the SHA-1 hash value for the file.

 

Awesome. Need to clarify a few things though.

 

When you say rename the corresponding file, you mean modify the modded file to that format?

 

And when you say change the SHA-1 hash value, can you walk us through that?

Edited by Mashadar
Link to comment
Share on other sites

Awesome. Need to clarify a few things though.

 

When you say rename the corresponding file, you mean modify the modded file to that format?

 

And when you say change the SHA-1 hash value, can you walk us through that?

 

For example, if you uncompressed core.upk to modify it, then you'll have to rename/delete core.upk.uncompressed_size

 

As for the SHA-1 thang, it'll be easier for me just to write a program to do it for you guys. Working on it...

Link to comment
Share on other sites

Sweet, so it sounds like we will be able to mod all the script files as long as we leave them unpacked.

 

Don't have any crazy ideas yet, but at the very least I want to get rid of the little action scene from when you see a squad of aliens and maybe shut up some of the dialogue. Then need to think on what to do about the wonderfully terrible strategic layer of the game.

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.

×
×
  • Create New...