The posts in a day record will take place from August 23, 11 PM to August 24, 11 PM (UTC+2).
During this day, you will earn thrice as many Tings as usual by posting, plus extra rewards up to 6000 Tings. We count on you to be here and post as much as you can in order to beat the previous 32252 posts record!
Time left before the record: 4 hours 0 minutes 23 seconds.

Tonic Trouble Tools (Retail)

Discuss tools to aid in the modification and running of Rayman games.

Moderators: English moderators, Modding and utilities team

Post Reply
Hipnosis183
Électoon
Posts: 2
Joined: Wed Jul 24, 2019 3:23 am
Tings: 10

Tonic Trouble Tools (Retail)

Post by Hipnosis183 » Wed Jul 24, 2019 8:58 am

Note: While not a Rayman game, I think it's related enough for the thread to be here. If not, move it to off-topic.

Well, making this game to work on newer systems is for sure a complete pain, even more taking in mind all the different versions for both Retail and Special Editions. The objective of this thread is to list the tools already available to make the game perfectly playable on modern systems.

First of all, this will cover just the Retail version, more specific the english release (TONIC TROUBLE REVIEW ENGLISH : TT221099-PC), although some tools could work with other versions if specified. You can check your version by pressing F4 in-game and typing "version".

Fixed Executable

The english version (this don't seem to affect other releases, i'm not sure) isn't compatible with modern Windows (above XP), due to the game executable's compression method. Thankfully, the user RibShark made a fix for it, which can be downloaded here:

Fixed Executable (RibShark): Download

I also took the oportunity to modify this executable and the setup file to add the following features:

- Patched the "ubi.ini" location to "C:\Windows" instead of "C:\Windows\Ubisoft" (the executable can't create folders), so by running the "SetUpTT.exe" you can recreate the file without needing to install the game (which would make it portable). (I couldn't find a way to redirect the file to the root game folder instead).
- Patched the "\Videos" folder location to the game folder, making the presence of the CD drive now useless.
- The executables won't create "*.log" files anymore.

Fixed Executables (Hipnosis): Download

Note: if you use this version, be sure to have the file "ubi.ini" in "C:\Windows", or run the setup first to create one; if not, the game would be looping searching for it without starting.

dgVoodoo

Not only dgVoodoo is great for all D3D, DDraw and Glide games, but it also works great with Tonic Trouble (D3D6), and is the preffered wrapper to use. I didn't test if it's a must for this game to work, but for sure will make it look more beutiful (or at least as much as this game could be). This utility will work with all the editions and versions of the game. Here is the download for dgVoodoo 2.6 files already configured to work at maximum display resolution available, proper aspect ratio, and some of MSAA (4x):

dgVoodoo (Hipnosis): Download

I would also reccomend to visit the official page to keep up to date with newer versions (pretty exciting since Dege's been working a lot in D3D9 support lately), or if you preffer to configure it for yourself:

dgVoodoo (Dege): Download

Widescreen Patcher

So here's the new exciting thing. This is an unnecessary program I wrote to patch the game executable to run in proper widescreen. First, is important to say that this works ONLY with the fixed executables, since the program hard-patches specific data addresses, which positions differ from other versions. It will detect automatically the desktop resolution and calculate the aspect ratio, for then patch the executable. It will overwrite the code for the 800x600 resolution, since doing so with 640x480, while would be preferred, displays incorrectly. Because of that, you must set 800x600 as the resolution in the game's option menu for it to work.

To patch, open the program, select the game executable and press the "Patch" button. There's also a "Restore" button, to (you guessed it) revert the changes. If the executable is in the same folder as the patcher, it will be detected automatically, so just press that patch button. It also supports drag and drop, and won't allow any different executable to be selected, so fear no undesire file corruptions.

Widescreen Patcher: Download

Note: If requested, it could support other versions as well, or even select fixed resolutions manually.

Launcher

It just runs the game with the "-cdrom:" parameter, so you don't need any shortcuts, extra files or the CD presence itself. Again, reusing the code from the utility above, it auto-detects the game executable, so rename it to whatever you want and it will run anyways. Remember to put it into the game folder.

Launcher: Download

And I think that would cover pretty much everything. If an utility is missing or you want to contribute with something, let me know and will update the post.

RayCarrot
Murray
Posts: 1624
Joined: Sat Jan 11, 2014 5:46 pm
Tings: 21949

Re: Tonic Trouble Tools (Retail)

Post by RayCarrot » Fri Jul 26, 2019 7:23 pm

Great job! It's nice to have the available TT mods put together like this :) I might consider adding some of these to my Rayman Control Panel if you don't mind.
One thing I'd like to point out though is that redirecting the ubi.ini file to the Windows directory is not something I'd recommend. That directory is for the Windows system and thus has heavy protection and might get removed. Then again I guess it's Ubisoft's fault to begin with by putting it in a sub-directory there.... I don't know how you patched the location, but would it be possible changing it completely? You mentioned the game folder didn't work (which would be ideal), but other locations like AppData or ProgramFiles would work too imo.

PluMGMK
Sandra Misu
Posts: 29549
Joined: Fri Jul 31, 2009 9:00 pm
Location: Tír an "Tuisil Ghinidigh" agus an "Mhodha Choinníollaigh"
Contact:
Tings: 4248

Re: Tonic Trouble Tools (Retail)

Post by PluMGMK » Fri Jul 26, 2019 8:15 pm

RayCarrot wrote:
Fri Jul 26, 2019 7:23 pm
Then again I guess it's Ubisoft's fault to begin with by putting it in a sub-directory there....
Ah, the 90s, when nobody cared about silly things like security or access controls. :hap:

Hipnosis183
Électoon
Posts: 2
Joined: Wed Jul 24, 2019 3:23 am
Tings: 10

Re: Tonic Trouble Tools (Retail)

Post by Hipnosis183 » Sat Jul 27, 2019 2:10 am

RayCarrot wrote:
Fri Jul 26, 2019 7:23 pm
Great job! It's nice to have the available TT mods put together like this :) I might consider adding some of these to my Rayman Control Panel if you don't mind.
Yeah sure, go ahead. I might release the source once the patcher gets more complete (if you want to integrate the functionality into your UI natively); this means adding more that just widescreen support (or at least that would be the idea).
RayCarrot wrote:
Fri Jul 26, 2019 7:23 pm
One thing I'd like to point out though is that redirecting the ubi.ini file to the Windows directory is not something I'd recommend. That directory is for the Windows system and thus has heavy protection and might get removed. Then again I guess it's Ubisoft's fault to begin with by putting it in a sub-directory there.... I don't know how you patched the location, but would it be possible changing it completely? You mentioned the game folder didn't work (which would be ideal), but other locations like AppData or ProgramFiles would work too imo.
The game stores the "\ubi.ini" ("\Ubisoft\ubi.ini") location as a string in the executable, and takes the "C:\Windows" direction from the system function GetWindowsDiretoryA, so isn't possible to change the file direction to anything over that location. I tried to change the function to GetCurrentDirectoryA, which should return the game directory, but there's an error at execution time, so didin't tried further. It might be possible to do though, maybe if someone knows how could give a hand on it, but may need something more than just hex edit.
About the protection of the windows folder, it should be fine, i wouldn't fear any problems with permissions. We could discuss other options for this, but i would preffer to wait until we found a way to work just with the game folder, the cleaner way.
PluMGMK wrote:
Fri Jul 26, 2019 8:15 pm
Ah, the 90s, when nobody cared about silly things like security or access controls. :hap:
90's software loved to put stuff in "C:" and "Windows" folder.

RayCarrot
Murray
Posts: 1624
Joined: Sat Jan 11, 2014 5:46 pm
Tings: 21949

Re: Tonic Trouble Tools (Retail)

Post by RayCarrot » Sat Jul 27, 2019 8:46 am

Hipnosis183 wrote:
Sat Jul 27, 2019 2:10 am
RayCarrot wrote:
Fri Jul 26, 2019 7:23 pm
Great job! It's nice to have the available TT mods put together like this :) I might consider adding some of these to my Rayman Control Panel if you don't mind.
Yeah sure, go ahead. I might release the source once the patcher gets more complete (if you want to integrate the functionality into your UI natively); this means adding more that just widescreen support (or at least that would be the idea).
That'd be great! I made a similar widescreen patch for Rayman 2 based on existing ones where I allow the value to be changed to any aspect ratio rather than limit it to 16/9. Assuming that should be possible here too since you're just editing a value in the executable.
Hipnosis183 wrote:
Sat Jul 27, 2019 2:10 am
RayCarrot wrote:
Fri Jul 26, 2019 7:23 pm
One thing I'd like to point out though is that redirecting the ubi.ini file to the Windows directory is not something I'd recommend. That directory is for the Windows system and thus has heavy protection and might get removed. Then again I guess it's Ubisoft's fault to begin with by putting it in a sub-directory there.... I don't know how you patched the location, but would it be possible changing it completely? You mentioned the game folder didn't work (which would be ideal), but other locations like AppData or ProgramFiles would work too imo.
The game stores the "\ubi.ini" ("\Ubisoft\ubi.ini") location as a string in the executable, and takes the "C:\Windows" direction from the system function GetWindowsDiretoryA, so isn't possible to change the file direction to anything over that location. I tried to change the function to GetCurrentDirectoryA, which should return the game directory, but there's an error at execution time, so didin't tried further. It might be possible to do though, maybe if someone knows how could give a hand on it, but may need something more than just hex edit.
About the protection of the windows folder, it should be fine, i wouldn't fear any problems with permissions. We could discuss other options for this, but i would preffer to wait until we found a way to work just with the game folder, the cleaner way.
Oh, that's more troublesome. I thought the location was hardcoded. Ideally you should be able to remove the native function call completely and make the path relative, which will always make it relative to the current directory. I think something similar was done with the GOG version of Rayman 2.
Regarding permissions there are some minor issues in some old Ubisoft games. Rayman 3 specifically has the tendency on Windows Vista and above to redirect the ubi.ini file to the VirtualStore location depending on the user privileges (running as admin or not). Though for TT I suppose it's fine. As long as the game has read permissions it doesn't really matter since the config program needs to run as admin anyways.

Post Reply