XeNTaX Forum Index
Forum MultiEx Commander Tools Tools Home
It is currently Fri May 25, 2018 6:40 am

All times are UTC + 1 hour


Forum rules


Please click here to view the forum rules



Post new topic Reply to topic  [ 442 posts ]  Go to page Previous  1 ... 25, 26, 27, 28, 29, 30  Next
Author Message
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Wed Jan 27, 2016 5:09 am 
Offline
n00b

Joined: Tue Nov 04, 2014 4:31 pm
Posts: 13
Has thanked: 0 time
Have thanks: 1 time

michalss wrote:
rajasrijan wrote:
Hi all
I'm trying to create packer for TR, this is what i'm doing.

Unpacking:
1) Read the SFAT header, get entries pointing to DRM.
2) Read the DRM header, get pointers to CDRM.
3) Extract CDRM

Packing:
1) Create new bigfile.004.tiger, increment file count in SFAT header .
2) Read content from disk, zip it if needed.
3) Store it in new bigfile at the end.
3) Modify the offset in DRM header.

This is working for textures (didn't test on meshes). I tried replacing textures in game start menu and its working.

I'm stuck at finding all the CDRM entries, as there are a lot of CDRM entries which cannot be reached from headers.
Anyone figure out this problem?

I'll put code in github when i have a working not crashing code :) or by sat



Nice, i was working on same thing, i have completed working repacker... problem is that it will repack only files not contains any CDRM... :D

Can you please share your code ? Privately ?


Sure. :)
I'm little busy now :( . Ill send you ASAP.

You can make the ads go away by registering



Top
 Profile  
 
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Sun Feb 14, 2016 7:41 am 
Offline
n00b

Joined: Tue Nov 04, 2014 4:31 pm
Posts: 13
Has thanked: 0 time
Have thanks: 1 time
Repacker code uploaded on github https://github.com/rajasrijan/TRExplorer.

Unpacker is working correctly but there a lot of bugs in packer. Feel free to have a look. Ill put binary when its stable enough.

Please backup game before using tool.


Top
 Profile  
 
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Sun Feb 14, 2016 9:54 am 
Offline
Moderator

Joined: Sun Mar 27, 2011 8:42 pm
Posts: 941
Has thanked: 10 times
Have thanks: 126 times
rajasrijan wrote:
Repacker code uploaded on github https://github.com/rajasrijan/TRExplorer.

Unpacker is working correctly but there a lot of bugs in packer. Feel free to have a look. Ill put binary when its stable enough.

Please backup game before using tool.


Thx, but is this for 2016 or 2013 ?

_________________
Quick BMS Editor GUI - simple easy to use
Goto : viewtopic.php?uid=34229&f=29&t=6797&start=0

Downloads from DropBox : https://dl.dropboxusercontent.com/u/


Top
 Profile  
 
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Sun Feb 14, 2016 10:49 am 
Offline
n00b

Joined: Tue Nov 04, 2014 4:31 pm
Posts: 13
Has thanked: 0 time
Have thanks: 1 time
michalss wrote:
rajasrijan wrote:
Repacker code uploaded on github https://github.com/rajasrijan/TRExplorer.

Unpacker is working correctly but there a lot of bugs in packer. Feel free to have a look. Ill put binary when its stable enough.

Please backup game before using tool.


Thx, but is this for 2016 or 2013 ?


It's 2013. I don't have 2016 yet. :(
But format should be similar. I dought they will completely reinvent format.


Top
 Profile  
 
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Sun Feb 14, 2016 2:05 pm 
Offline
Moderator

Joined: Mon Jul 05, 2010 8:55 pm
Posts: 602
Has thanked: 19 times
Have thanks: 228 times
Repacking Tiger files should be easy if you can unpack them. What exactly is the issue?

_________________
Click the thanks button if I helped!


Top
 Profile  
 
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Sun Feb 14, 2016 2:25 pm 
Offline
n00b

Joined: Tue Nov 04, 2014 4:31 pm
Posts: 13
Has thanked: 0 time
Have thanks: 1 time
Gh0stBlade wrote:
Repacking Tiger files should be easy if you can unpack them. What exactly is the issue?


Complete format is not known.


Top
 Profile  
 
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Sun Feb 14, 2016 3:02 pm 
Offline
Moderator

Joined: Mon Jul 05, 2010 8:55 pm
Posts: 602
Has thanked: 19 times
Have thanks: 228 times
rajasrijan wrote:
Gh0stBlade wrote:
Repacking Tiger files should be easy if you can unpack them. What exactly is the issue?


Complete format is not known.

Which parts are unknown? To my knowledge the entire tiger format is known. Entire CDRM format is known. DRM should be fully known except parts of the duplicated section data at the EOF (I should check that actually).

_________________
Click the thanks button if I helped!


Top
 Profile  
 
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Sun Feb 14, 2016 3:27 pm 
Offline
n00b

Joined: Tue Nov 04, 2014 4:31 pm
Posts: 13
Has thanked: 0 time
Have thanks: 1 time
Gh0stBlade wrote:
rajasrijan wrote:
Gh0stBlade wrote:
Repacking Tiger files should be easy if you can unpack them. What exactly is the issue?


Complete format is not known.

Which parts are unknown? To my knowledge the entire tiger format is known. Entire CDRM format is known. DRM should be fully known except parts of the duplicated section data at the EOF (I should check that actually).


Can you point me to the format :) . I dont have the complete DRM format and there are some some CDRMs not reachable from the table at the begenning, those CDRMs are hard to replace.


Top
 Profile  
 
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Mon Feb 15, 2016 1:07 pm 
Offline
advanced

Joined: Sun Nov 30, 2014 1:49 am
Posts: 71
Has thanked: 43 times
Have thanks: 3 times
rajasrijan wrote:
Repacker code uploaded on github https://github.com/rajasrijan/TRExplorer.

Unpacker is working correctly but there a lot of bugs in packer. Feel free to have a look. Ill put binary when its stable enough.

Please backup game before using tool.


Thanks for your tool! How to use this tool?

I use this command:

Quote:
TRExplorer bigfile_ENGLISH.000.tiger UNPACK patch_ENGLISH.000.tiger


Not working!

Quote:
F:\Program Files (x86)\Eidos Interactive\Tomb Raider GOTY Edition>TRExplorer big
file_ENGLISH.000.tiger UNPACK patch_ENGLISH.000.tiger
rajasrijan's tiger decoder.

Tiger Header
Magic :53464154
Version :3
Parts :1
DRMs :8618
Base Path :pc-w
Loading data entries...success

Invalid operation.

F:\Program Files (x86)\Eidos Interactive\Tomb Raider GOTY Edition>pause
Press any key to continue . . .
Terminate batch job (Y/N)?


Thanks!


Top
 Profile  
 
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Mon Feb 15, 2016 1:56 pm 
Offline
n00b

Joined: Tue Nov 04, 2014 4:31 pm
Posts: 13
Has thanked: 0 time
Have thanks: 1 time
shadowlonely1989 wrote:
rajasrijan wrote:
Repacker code uploaded on github https://github.com/rajasrijan/TRExplorer.

Unpacker is working correctly but there a lot of bugs in packer. Feel free to have a look. Ill put binary when its stable enough.

Please backup game before using tool.


Thanks for your tool! How to use this tool?

I use this command:

Quote:
TRExplorer bigfile_ENGLISH.000.tiger UNPACK patch_ENGLISH.000.tiger


Not working!

Quote:
F:\Program Files (x86)\Eidos Interactive\Tomb Raider GOTY Edition>TRExplorer big
file_ENGLISH.000.tiger UNPACK patch_ENGLISH.000.tiger
rajasrijan's tiger decoder.

Tiger Header
Magic :53464154
Version :3
Parts :1
DRMs :8618
Base Path :pc-w
Loading data entries...success

Invalid operation.

F:\Program Files (x86)\Eidos Interactive\Tomb Raider GOTY Edition>pause
Press any key to continue . . .
Terminate batch job (Y/N)?


Thanks!


Try with small letters "unpack". Ill put a fix when I get home :)

P.S. Updated readme


Last edited by rajasrijan on Mon Feb 15, 2016 2:06 pm, edited 1 time in total.

Top
 Profile  
 
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Mon Feb 15, 2016 2:04 pm 
Offline
Moderator

Joined: Mon Jul 05, 2010 8:55 pm
Posts: 602
Has thanked: 19 times
Have thanks: 228 times
rajasrijan wrote:
Can you point me to the format :) . I dont have the complete DRM format and there are some some CDRMs not reachable from the table at the begenning, those CDRMs are hard to replace.


The DRM format is very close to Tomb Raider Underworld's contains the exact same components except the duplicated DRM Section info at the end of the DRM which is new. The only unknown field is the last 32-bit unsigned integer of the second DRM Section info, everything else is known. The value itself could be related to struct relocation or memory mapping.

I checked the code for your tool. I think the offset calculation is wrong. Also the game needs all hashes to be ordered in ascending order or it will crash.

Regards.

_________________
Click the thanks button if I helped!


Top
 Profile  
 
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Mon Feb 15, 2016 2:09 pm 
Offline
advanced

Joined: Sun Nov 30, 2014 1:49 am
Posts: 71
Has thanked: 43 times
Have thanks: 3 times
rajasrijan wrote:
shadowlonely1989 wrote:
rajasrijan wrote:
Repacker code uploaded on github https://github.com/rajasrijan/TRExplorer.

Unpacker is working correctly but there a lot of bugs in packer. Feel free to have a look. Ill put binary when its stable enough.

Please backup game before using tool.


Thanks for your tool! How to use this tool?

I use this command:

Quote:
TRExplorer bigfile_ENGLISH.000.tiger UNPACK patch_ENGLISH.000.tiger


Not working!

Quote:
F:\Program Files (x86)\Eidos Interactive\Tomb Raider GOTY Edition>TRExplorer big
file_ENGLISH.000.tiger UNPACK patch_ENGLISH.000.tiger
rajasrijan's tiger decoder.

Tiger Header
Magic :53464154
Version :3
Parts :1
DRMs :8618
Base Path :pc-w
Loading data entries...success

Invalid operation.

F:\Program Files (x86)\Eidos Interactive\Tomb Raider GOTY Edition>pause
Press any key to continue . . .
Terminate batch job (Y/N)?


Thanks!


Try with small letters "unpack". Ill put a fix when I get home :)


Thanks! How to unpack text from bigfile_ENGLISH.000.tiger pc-w\local\locals.bin?


Top
 Profile  
 
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Mon Feb 15, 2016 2:25 pm 
Offline
n00b

Joined: Tue Nov 04, 2014 4:31 pm
Posts: 13
Has thanked: 0 time
Have thanks: 1 time
Gh0stBlade wrote:
rajasrijan wrote:
Can you point me to the format :) . I dont have the complete DRM format and there are some some CDRMs not reachable from the table at the begenning, those CDRMs are hard to replace.


The DRM format is very close to Tomb Raider Underworld's contains the exact same components except the duplicated DRM Section info at the end of the DRM which is new. The only unknown field is the last 32-bit unsigned integer of the second DRM Section info, everything else is known. The value itself could be related to struct relocation or memory mapping.

I checked the code for your tool. I think the offset calculation is wrong. Also the game needs all hashes to be ordered in ascending order or it will crash.

Regards.


This was working with the vanilla game, without any updates, now its not. I thought there was more CDRM sections needed in new file to stop the crash(they seem to be loading 0x8000 bytes at ones and doing some switch case logic. So I thought more sections, still learning :) ).I fixed one offset calculation in NEXT section, I hope that's the one you're talking about.

You mean the hashes in the tiger header right?
If ascending order is needed then complete file repack will be required or a binary patch if its a simple security check. What do you think?


Top
 Profile  
 
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Mon Feb 15, 2016 2:41 pm 
Offline
Moderator

Joined: Mon Jul 05, 2010 8:55 pm
Posts: 602
Has thanked: 19 times
Have thanks: 228 times
rajasrijan wrote:
So I thought more sections, still learning :) ).I fixed one offset calculation in NEXT section, I hope that's the one you're talking about.


I mean the direct offset for both tiger->drm and drm->cdrm is wrong. (Try it on patch.000.tiger it's very likely your tool will crash)

rajasrijan wrote:
This was working with the vanilla game, without any updates, now its not.


Save yourself the trouble and work with the patched version of the game. By doing so, you can simply modify the patch.*.tiger file which is much smaller. Adding new DRM files to those means they are loaded instead of the ones in the original Bigfile.

rajasrijan wrote:
I thought there was more CDRM sections needed in new file to stop the crash(they seem to be loading 0x8000 bytes at ones and doing some switch case logic.


I'm not sure what you mean by this, could you explain it further please? If i recall correctly, CDRM files are not always compressed. That is very important, take a look at my tools here: https://github.com/Gh0stblade/cdcEngineTools those are for TR8 though.

rajasrijan wrote:
You mean the hashes in the tiger header right?
If ascending order is needed then complete file repack will be required or a binary patch if its a simple security check. What do you think?


Yep, hashes in the tiger header must be sorted by ascending order or the engine will crash. I wrote an injector years ago and couldn't figure out why I kept getting crashes, turns out that was the problem. If you just work with the patch files then repacking will be much easier. From a technical perspective you shouldn't be altering the Bigfile.000.tiger since effectively, if you alter a file in there which has been patched in patch.000.tiger it will have no effect.

Regards.

_________________
Click the thanks button if I helped!


Top
 Profile  
 
 Post subject: Re: Tomb Raider (2013) (PC) (PS3) (XBOX) (*.tiger)
PostPosted: Sun Feb 21, 2016 6:25 am 
Offline
n00b

Joined: Tue Nov 04, 2014 4:31 pm
Posts: 13
Has thanked: 0 time
Have thanks: 1 time
Hi,

Quote:
Save yourself the trouble and work with the patched version of the game. By doing so, you can simply modify the patch.*.tiger file which is much smaller. Adding new DRM files to those means they are loaded instead of the ones in the original Bigfile.


Patch files seem to contain a lot of RDEF files. Any idea what those are?

Quote:
I mean the direct offset for both tiger->drm and drm->cdrm is wrong. (Try it on patch.000.tiger it's very likely your tool will crash)


fixed. now it should work with all files

regards



Top
 Profile  
 
Display posts from previous:  Sort by  
Post new topic Reply to topic  [ 442 posts ]  Go to page Previous  1 ... 25, 26, 27, 28, 29, 30  Next

All times are UTC + 1 hour


Who is online

Users browsing this forum: Majestic-12 [Bot] and 3 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group