====== Disclaimer ======

This software could have adverse effects and cause crashes on your system.
USE AT YOUR OWN RISK
Note also that at present the mod is only destributed through the official
discord channel. Permanent link: https://discord.gg/gcrdyFmYZJ

===== Requirements =====

Windows 10 or 11
DirectX 11.1 capable graphics card

===== What It Does =====

- Takes control over the framerate of the game to improve the frame stability
  and input latency.
- Adds the options to remove parts of the default ui and replace them with some
  simple ui elements.
- Adds some extra ui options like a checkpoint counter.
- Pluss some other minor functionality

====== Update Mod ======

Overwrite the old xinput1_3.dll with the new one.

- If you want to reset mod settings delete noxmod.ini in datapack/noxmod folder
- If you want to reset window positions delete imgui.ini in datapack/noxmod folder
- If upgrading from v0.8 or lower and you want to preserve the settings that
  are unchanged you will have to create a noxmod folder and put the mod files
  in there (except for xinput1_3.dll wich must remain under the datapack
  folder)

===== Installation =====

1. Start Trials Fusion in windowed mode by loading the game and going into
   settings (Windowed Mode -> [ON] - OFF).

2. Set the resolution of the game to the same as your desktop.

3. Now exit the game and paste the xinput1_3.dll into the folder with
   "trials_fusion.exe" inside. Typical locations are:
   - Uplay Version
	- ".../Ubisoft/Ubisoft Game Launcher/games/Trials Fusion/datapack" folder.
   - Steam Version
	- ".../SteamLibrary/steamapps/common/Trials Fusion/datapack" folder.

4. Load up the game and you should see some text that the mod was loaded, press
   F1 to bring up the mod menu.

Note that if you do not have a variable refreshrate monitor (gsync/freesync)
you will have to disable VRRSupport and enable VSync to remove screen tearing.
This might require a restart of the game to take effect. Keep in mind turning
on VSync will remove some or all of the input latency benefit you get with the
mod installed.

====== Uninstall =======

Delete or rename the 'xinput1_3.dll' file that you added in the datapack folder.
To reset settings delete noxmod.ini and imgui.ini in the noxmod folder.

===== Custom Font ======

If you want to use a custom ttf font drop it into the "noxmod" folder and
rename it to noxmod.ttf.
- Note: You will have to restart the game for it to work.

==== Known Issues =====

- Running a ps4 gamepad through the steam input api is not supported. In
  this case, any gamepad functionality of the mod will not work. You can solve
  this by using programs like ds4windows that do xinput emulation.

- Occasionally the game has a big lag spike. This is something that is
  probably an issue with the core game and that the mod may exacerbate.
  Debugging this issue does not seem feasible to me.

- The UI is broken in skillgames/fmx.

=== Troubleshooting ====

- Reset any driver settings to the default. For example with nvidia gpus open
  nvidia control panel and navigate to:
        Manage 3D Settings > Porgram Settings > trials_fusion.exe
  then click restore.

- Disable all overlays in game. Discord overlay seem to be the only one I've
  heard causing issues but you could try to disable others. For example
  steam/uplay overlays and anything that draws on top of the game.

- Make sure you don't have any framerate limiter installed and active.

- If you have a gsync/freesync monitor make sure the feature is enabled in
  your driver settings and also that it is enabled for windowed mode.

- If you get some stuttering/freezing make sure you are playing with the game
  focused. You can tell you have the game focused if you hear the game sound.
  You could also try closing other programs that are running in the background
  to free up more resources for the game.


