Skip to content

Commit

Permalink
initial 'tips and tricks' page
Browse files Browse the repository at this point in the history
  • Loading branch information
apprehensions committed Aug 19, 2023
1 parent 352e813 commit 838f405
Show file tree
Hide file tree
Showing 3 changed files with 71 additions and 33 deletions.
75 changes: 42 additions & 33 deletions src/Configuration/index.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,50 +2,59 @@

To change Vinegar's behavior, edit the `config.toml` file at `~/.config/vinegar/config.toml` (or `$XDG_CONFIG_HOME/vinegar/config.toml` if applicable).

Anything added to the configuration file is an override over the default values, which are designed to be the best for the average user. However, by editing the configuration file you can tune your performance or apply other customizations.
Anything added to the configuration file is an override over the default values (the default configuration file can be seen [here](https://github.com/vinegarhq/vinegar/blob/master/internal/config/config.toml)), which are designed to be the best for the average user. However, by editing the configuration file you can tune your performance or apply other customizations.

## Configuration fields
This section will explain what each field in the configuration file represents.
## Configuration Values
This section will explain what each value in the global configuration file represents.

| Option | Description | Default |
| ------------- | ---------------------------------------------------------------------------------------------------------- | --------- |
| `applyrco` | applies [RCO](https://github.com/L8X/Roblox-Client-Optimizer)'s FFlags to the Roblox Player. | `true` |
| `autokillpfx` | automatically kills the Wineprefix after Roblox is no longer running. | `true` |
| `dxvk` | automatically (un)installs DXVK to the wineprefix before Roblox launches. | `true` |
| `log` | enables logging for Vinegar itself, does not disable logging for Roblox. | `true` |
| `prime` | sets the environmental variables required for using NVIDIA's dedicated graphics. | `false` |
| `launcher` | the program that is used to launch Wine when launching Roblox; can be set to `gamemoderun`. | `""` |
| `renderer` | selects the rendering engine to be used by Roblox via FFlags. | `"D3D11"` |
| `version` | the value of the Wineprefix version. | `"win10"` |
| `wineroot` | the path to a valid Wine 'root' installation directory. | `""` |
| `[env]` | the section used to set environmental variables. | |
| `[fflags]` | the section used to set FFlags for the Roblox Player. | |

#### Notes
* `applyrco` will always fetch the RCO FFlags when launching Roblox.
* `autokillpfx` requires Linux 2.6.33 and up, since `/proc/*/comm` is scanned.
* `prime` sets the following variables:
* `DRI_PRIME=1`
* `__NV_PRIME_RENDER_OFFLOAD=1`
* `__VK_LAYER_NV_optimus=NVIDIA_only`
* `__GLX_VENDOR_LIBRARY_NAME=nvidia`
* `renderer` must be one of the following: `"OpenGL"`, `"D3D11FL10"`, `"D3D11"`, `"Vulkan"`

Some miscellaneous environmental variables that can be set under the `[env]` section:
| `launcher` | the program that is used to launch Wine when launching Roblox; can be set to `gamemoderun`. | none |
| `wineroot` | the path to a valid Wine 'root' installation directory. | none |

For Studio or Player configurations, you will need to specify it as a table, an example can be seen below.

| Option | Description | Default |
| ------------------ | ------------------------------------------------------------------------------------------------| ------------------------------- |
| `channel` | the Roblox release channel | `"live"` |
| `renderer` | selects the rendering engine to be used by Roblox via FFlags. | `"D3D11"` |
| `forced_version` | forces Vinegar to use a specific version, the release channel must be adjusted for the version. | none |
| `auto_kill_prefix` | tells Vinegar to automatically kill the wineprefix after the application closes. | `false` |
| `dxvk` | automatically uses DXVK for the application, installs if neccessary. | Player: `true`, Studio: `false` |
| `[app.fflags]` | the table used to set FFlags for the given application type. | See below. |
| `[app.env]` | the table used to set environment variables for the given application type. | Player: `DXVK_HUD=fps` |

### Notes
* `renderer` must be one of the following: `"OpenGL"`, `"D3D11FL10"`, `"D3D11"`, `"Vulkan"`.
* Ensure that when setting a string, the value must be in quotes: `channel = "zintegration"`
* When using DXVK, ensure that the renderer is `"D3D11"`, otherwise Roblox will not utilize DXVK.
* `app` in `[app.fflags]` or `[app.env]`, should be renamed to `player` or `studio`, eg. `[player.fflags]`.
* `DFIntTaskSchedulerTargetFps` is set to `640` by default for Player; if you also want to change the FPS limit you may set the FFlag's value to your requested limit (eg. `30`)

#### Miscellaneous environmental variables
+ `WINEESYNC`: allows Wine Staging to use Esync, please see [HowToEsync](https://github.com/lutris/docs/blob/master/HowToEsync.md) for more information.
+ `WINEDEBUG`: for performance reasons, this has been set to `-all`, which disables most of the logging, when wanting to debug crashes of Wine, it is recommended to set this to an empty string (`""`).
+ `DXVK_HUD`: is a variable used by DXVK for a hud, for more information about it you can see the [DXVK README](https://github.com/doitsujin/dxvk#hud), which includes various other variables that can be set.

RCO unlocks FPS by setting the FFlag `DFIntTaskSchedulerTargetFps` to a arbitrary big value (`10000`). However, if you also want to limit the FPS you may set the FFlag's value to your requested limit (eg. `30`)
+ `DXVK_HUD`: is a variable used by DXVK for a hud, for more information about it you can see the [DXVK README](https://github.com/doitsujin/dxvk#hud), which includes various other variables that can be set. This is set to `fps` by default, allowing you to see the FPS when using DXVK.

### Example configuration
```toml
applyrco = false
wineroot = "/home/meow/wine-ge"
launcher = "gamemoderun"

[env]
WINEESYNC = "1"
WINEFSYNC = "1"

[player]
dxvk = false
renderer = "Vulkan"
channel = "zcanary"

[player.env]
DXVK_HUD = "0"

[player.fflags]
DFIntTaskSchedulerTargetFps = 144

[fflags]
DFIntTaskSchedulerTargetFps = 30
[studio]
renderer = "OpenGL"
```
28 changes: 28 additions & 0 deletions src/Configuration/tips-and-tricks/index.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Tips and tricks

## Overlay
In Vinegar, a directory under the configuration directory called `overlay` will be copied directly to the Roblox Player and Studio upon launching; this can be used to override files of Roblox, allowing modifications!

## FFlags
This section is undocumented, below is a list of fflags that can be set; credits to [Bloxstrap](https://github.com/pizzaboxer/bloxstrap/blob/main/Bloxstrap/FastFlagManager.cs).

```toml
# See https://github.com/pizzaboxer/bloxstrap/wiki/A-guide-to-FastFlags#gui-hiding
DFIntCanHideGuiGroupId = true

# See IGMenuVersions in Bloxstrap for more details
FFlagDisableNewIGMinDUA = true
FFlagEnableInGameMenuControls = true

FFlagFixGraphicsQuality = 20 # Allows for 20 bars in the graphics quality

DFFlagDebugRenderForceTechnologyVoxel = false # Voxel
FFlagDebugForceFutureIsBrightPhase2 = false # ShadowMap
FFlagDebugForceFutureIsBrightPhase = true # Future
```

## Environmental variables
+ `WINEESYNC`: allows Wine Staging to use Esync, please see [HowToEsync](https://github.com/lutris/docs/blob/master/HowToEsync.md) for more information.
+ `WINEDEBUG`: for performance reasons, this has been set to `-all`, which disables most of the logging, when wanting to debug crashes of Wine, it is recommended to set this to an empty string (`""`).
+ `DXVK_HUD`: is a variable used by DXVK for a hud, for more information about it you can see the [DXVK README](https://github.com/doitsujin/dxvk#hud), which includes various other variables that can be set. This is set to `fps` by default, allowing you to see the FPS when using DXVK.

1 change: 1 addition & 0 deletions src/SUMMARY.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,6 @@
- [Installing from source](./Installation/guides/source.md)
- [Installing from Flatpak](./Installation/guides/flatpak.md)
- [Configuration](./Configuration/index.md)
- [Tips and tricks](./Configuration/tips-and-tricks/index.md)
- [Contributing](./Contributing/index.md)
- [Troubleshooting](./Troubleshooting/index.md)

0 comments on commit 838f405

Please sign in to comment.