# Note: if you want to override even DLLs loaded with an absolute
# path, you need to add an asterisk:
echo "\"*${module}\"=\"${_W_mode}\"" >> "${W_TMP}"/override-dll.reg
What this means is, if Bottles installs dxgi.dll, and registers dxgi in Wine, the following happens:
If a .exe asks for dxgi.dll, all is fine.
If a .exe asks for C:\Windows\system32\dxgi.dll or .\dxgi.dll (local game folder version), nothing is fine. The custom Bottles dxgi.dll will not be loaded then.
If we register it as *dxgi instead, then it will always be loaded. In other words, the * asterisk is necessary to do a "full override".
If we don't override completely, then certain games and apps will break in Bottles since they won't load the overridden DLLs at all unless we add a * to the name.
This may explain a bunch of games that crash in Bottles (with null-pointer errors) but work in Lutris even with the exact same Wine-runner in both apps.
Great news for Bottles compatibility with games!
I discovered why Winetricks adds
*
asterisk before every DLL name, such as*d3dcompiler_43
etc.It was explained in their source code here:
https://github.com/Winetricks/winetricks/blob/d431b15fa55667217571a791074dc3eb69155dfc/src/winetricks#L2115-L2122
Relevant part:
What this means is, if Bottles installs
dxgi.dll
, and registersdxgi
in Wine, the following happens:dxgi.dll
, all is fine.C:\Windows\system32\dxgi.dll
or.\dxgi.dll
(local game folder version), nothing is fine. The custom Bottles dxgi.dll will not be loaded then.If we register it as
*dxgi
instead, then it will always be loaded. In other words, the*
asterisk is necessary to do a "full override".If we don't override completely, then certain games and apps will break in Bottles since they won't load the overridden DLLs at all unless we add a
*
to the name.This may explain a bunch of games that crash in Bottles (with null-pointer errors) but work in Lutris even with the exact same Wine-runner in both apps.
This post is a followup from comments here: https://github.com/bottlesdevs/Bottles/issues/1020#issuecomment-1061928764