Jump to content

PCK Files and 1.2a


BladeFireLight

Recommended Posts

I have UFO 1.2a. it's a CDrom release I picked up back in 94. There are a number of the BIGOB_XX files in UFOGraph are different than any other release i have seen. I cant get XCView to display the files and PCKView crashes on my system. Does any one have a working copy that can open those files?

 

-Blade FireLight.

Link to comment
Share on other sites

Have you tried BB's Toolkit to open up the images? Beyond this, what specific copy of the game do you have? Is it listed on the EU Game Versions page? If all you have is the disc, can you provide us with a scan/photo of it? From that I could check my collection and try to open up the files myself. :D

 

- Zombie

 

I will try to tool kit and see if it works.

 

It looks like the UK CDrom version. Codes from the hub are {CDR 00078 PC Wise LTD. 0685 350505 MP 190177} if you want to compare to what you have.

 

XcomUtil will detect it as 1.2a but the offset's dont match what Scott hard coded, so the results of mixing the two can be a mess. I always played with 1.4 when using XcomUtil in the past so I never would have noticed.

 

I attached a copy of the comparison of the two folder structures. Blue is exact match.

1.2_vs_1.2a.pdf

Link to comment
Share on other sites

OK. somthing strange is going on with my computer. I just setup that 1.2a folder on my hard drive for comparison from the CD. but now that I compare it with the CD I get the same file differences issue.

 

Now that that is resolved. I wonder what is up with the offsets being different. I checked the files directly on the CD and the position of much of the data in geoscape and tactical does not match up to scott's offset.

 

-Blade FireLight

Link to comment
Share on other sites

Neither PCKView nor my own tools will handle those BIGOB_XX files unless you manually create TAB files to go with them (containing two bytes: 00 00).

 

PCKView shouldn't "crash" if the TAB isn't present, but it'll give you an error message simply saying it can't load the file. Fairly sure my tools'll crash, can't be bothered testing. Should really tweak 'em to infer the missing TAB files if it can't find 'em, but I never figured anyone would have cause to try to view their contents (because of the primary "bigobs.pck" archive).

 

XCView doesn't handle PCK at all. Any PCK files it "does" load are really in a different format (usually SPK). The game devs were rather lax when it came to matching file extensions to file types.

Link to comment
Share on other sites

Sorry, what are you "mixing" with what? Do you mean "confusing"?

 

PCKEdit times out with File > Open on Win7 x64.

 

Using XcomUtil with my copy of 1.2a will modify the wrong parts of the EXE.

I dont know if there is another version out there with the same 1.2a detection signature that would have different offsets that are modified by XcomUtil.

 

It turns out it's SmartSVN is messing up the file on commit. I just did a server side copy of the 1.2 ufograph folder and now the images are matching the CD.

 

-Blade FireLight

Link to comment
Share on other sites

It looks like the UK CDrom version. Codes from the hub are {CDR 00078 PC Wise LTD. 0685 350505 MP 190177} if you want to compare to what you have.

That's the code I have on my disc so we are on the same page at least. Thanks! :D

 

Neither PCKView nor my own tools will handle those BIGOB_XX files unless you manually create TAB files to go with them (containing two bytes: 00 00).

Is that hex? I created a tab file with two 0's in it in MS-Edit and then ran your converter on just BIGOB_00 (the Laser Rifle). When I opened the gif up with all the photo editing programs I have it comes up with a greenish hue to it. Here's a screenie of it in Paint.Net (blown up by 1200% to see the details):

 

Laser_Rifle.png

 

Any ideas? Is it using a different palette maybe?

 

- Zombie

Link to comment
Share on other sites

Yeah, that's hex. Note that two 0's in ASCII would be x30 30. But I guess you accounted for that, or it wouldn't've worked at all. :D

 

That palette is from TFTD's battlescape, at surface depth (the one PCKView defaults to!). The tools of the pack check the size of the game's palette file in order to work out if what game it's installed over. If the filesize doesn't match a certain value (or heck, if it can't find the palette file at all), it assumes it's installed over TFTD (as opposed to EU) and uses the later game's palette data instead.

 

(TFTD's battlescape palettes are hardcoded into it's executable, so I likewise hardcoded it into my tools rather then have them attempt to dynamically extract them from whatever game executable the user has).

 

You'll notice it also gets the image size wrong, that's because it only uses the correct "bigobs" dimensions when dealing with the primary "bigobs" archive. Probably another thing I should tweak.

 

Edit:

 

The actual approach I took was to have the user convert their main "bigobs.pck" file to GIFs, then when they reconvert that back to PCK format, all the "bigobs_xx" files are generated as well. Because the images are supposed to be identical, I never put any effort into providing a simple way to convert the "bigobs_xx" files to GIF.

 

The only real difference between the two images is that one set are used in the UFOpedia, and one are used in the Battlescape. They use the same palette and everything... Kinda.

 

The last 16 entries of the tactical palette, taken from PALETTES.DAT, do not appear in the actual battlescape. Instead, they're replaced by some shades of grey. I don't know where these colours are loaded from, I assume they're hardcoded into the executable.

 

When viewing weapons in the UFOpedia, the tactical palette is used verbatim, without the altered 16 colours at the end. So any BigObs image that uses one of those last 16 colours of the palette will appear different depending on whether you view it in the battlescape or the UFOpedia (the UFOpedia actually loads a few different palettes depending on what section you're reading).

 

My tools get around this by dis-cluding the use of those 16 colours when creating BigObs PCK files. I don't know how the developers dealt with it, but I'd imagine they did the same thing. On the other hand, that leaves no explanation as to why there are two "identical" sets of BigObs images; it could well be that the devs did actually make use of some of those variable colours in one set, then created another set for use with the other (edited) palette. Which would be silly, but the fact remains that two sets exist and both are used by the game itself.

Link to comment
Share on other sites

Yeah, that's hex. Note that two 0's in ASCII would be x30 30. But I guess you accounted for that, or it wouldn't've worked at all. :)

I just assumed that since you included 2 zeros in a row that you meant two hex bytes with a value of 0. If I assumed ascii, I could have entered two zeros in notepad and saved it as a tab file, hence why I used MS-Edit instead. :D

 

That palette is from TFTD's battlescape, at surface depth (the one PCKView defaults to!). The tools of the pack check the size of the game's palette file in order to work out if what game it's installed over. If the filesize doesn't match a certain value (or heck, if it can't find the palette file at all), it assumes it's installed over TFTD (as opposed to EU) and uses the later game's palette data instead.

 

(TFTD's battlescape palettes are hardcoded into it's executable, so I likewise hardcoded it into my tools rather then have them attempt to dynamically extract them from whatever game executable the user has).

Ah, well that explains the greenish hue. :D Any future possibility of allowing a user to select the game they are using instead of assuming? (You know what they say about "assume": it makes an "ass" out of "u" and "me"). Of course, the best option would be to directly read the palette from the exe instead of a stock file to remove any assumptions. If the palette is identical between game versions, then of course it is fine to use a stock file to make coding easier. :D

 

You'll notice it also gets the image size wrong, that's because it only uses the correct "bigobs" dimensions when dealing with the primary "bigobs" archive. Probably another thing I should tweak.

Yeah, I was going to bring that up but the wrong palette seemed to be more important. :)

 

The actual approach I took was to have the user convert their main "bigobs.pck" file to GIFs, then when they reconvert that back to PCK format, all the "bigobs_xx" files are generated as well. Because the images are supposed to be identical, I never put any effort into providing a simple way to convert the "bigobs_xx" files to GIF.

 

My tools get around this by dis-cluding the use of those 16 colours when creating BigObs PCK files. I don't know how the developers dealt with it, but I'd imagine they did the same thing. On the other hand, that leaves no explanation as to why there are two "identical" sets of BigObs images; it could well be that the devs did actually make use of some of those variable colours in one set, then created another set for use with the other (edited) palette. Which would be silly, but the fact remains that two sets exist and both are used by the game itself.

Seeing as the Bigobs.pck file in the UNITS folder is identical between 1.2 and CE, we (Blade and I) can't extract the images out of there to get the proper associated bigob_xx.pck file. So we have to extract the images directly from the UFOGRAPH folder instead. Are you going to provide support for this option? Would be nice to actually see what the differences are between the bigob_xx files Blade mentioned. :)

 

- Zombie

Link to comment
Share on other sites

Ah, well that explains the greenish hue. :D Any future possibility of allowing a user to select the game they are using instead of assuming?

The EU palettes are not hardcoded (with the exception of those 16 indexes I mentioned), so if the tools can't find them, they can't use them.

 

As it stands, the tools expect to be working with whatever game you install them over (or at least, they'll try to do things the TFTD way if they can't find EU, and simply crash if that's not present - except in certain cases like this image converter, which only needs TFTD's palette, which does happen to be hard coded). Simple - much the same as XcomUtil in that aspect, really. :)

 

I mean, sure, I could add prompts for game folders and user preferences and so forth so the tools can work with either game from any location (like Daishiva's stuff). But it all seems like too much work for something so trivial (programming an interface is boring, and I don't even want to count how many lines of code would need modifying!).

 

The "benefits" would boil down to the saving of 3mb drive space, in that you wouldn't need to have an additional copy installed in order to use it with both games... Fifteen years ago I mighta cared, but the amount of storage I own now makes that a laughable figure. :)

 

Long story short, whether you agree with me or not, I'm too lazy to do it. :D

 

Seeing as the Bigobs.pck file in the UNITS folder is identical between 1.2 and CE, we (Blade and I) can't extract the images out of there to get the proper associated bigob_xx.pck file. So we have to extract the images directly from the UFOGRAPH folder instead. Are you going to provide support for this option? Would be nice to actually see what the differences are between the bigob_xx files Blade mentioned. :D

Extract the attached file into your "bb_tact" folder and run "BigOb_XX.bat". You don't need to copy any PCK files into the "bb_tact" folder, supply any command line arguments, or create the individual TAB files. All of the singular BigOb files will be extracted into "bb_tact\BigOb_XX\".

 

BigOb_XX.zip

Link to comment
Share on other sites

I have UFO 1.2a. it's a CDrom release I picked up back in 94. There are a number of the BIGOB_XX files in UFOGraph are different than any other release i have seen. I cant get XCView to display the files and PCKView crashes on my system. Does any one have a working copy that can open those files?

 

-Blade FireLight.

 

hi

 

did you ever get to view the content of the pick file?

Link to comment
Share on other sites

hi

 

did you ever get to view the content of the pick file?

 

The file differences were due to the files being treated as text by SmartSVN. The ones on the CD were an exact match to the previous version. I had the same issue with even more files on TFTD. Cost me a day of development time to re-setup all my clean game installs. :D

 

-Blade FireLight

Link to comment
Share on other sites

PCKEdit times out with File > Open on Win7 x64.

Ah, didn't realise you'd "upgraded" to that POS OS. Does the same thing under 32-bit, incidentally. Wouldn't be so bad if it didn't use .NET... Why Microsoft would break compatibility with their own software is beyond me.

 

I dont know if there is another version out there with the same 1.2a detection signature that would have different offsets that are modified by XcomUtil.

 

It turns out it's SmartSVN is messing up the file on commit. I just did a server side copy of the 1.2 ufograph folder and now the images are matching the CD.

Ah, I guess we all missed this. :D But, are the EXEs also identical?

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
  • Create New...