Do you perhaps also know what kind of resource causes the problem? Specifically the D3DUSAGE flags and the D3DPOOL used to create it and the D3DLOCK flags passed when locking it?
This is D3DPOOL_MANAGED, usage is 0.
When I set that PIN_SYSMEM flag on wined3d it does two things: first, it keeps constant map address which app gets; then, it makes wined3d always consider the data in system memory valid (unless it is set as render target which I believe is not the case and not possible for these textures) and when the app locks it again it doesn't pull it back from vidmem.
The game seems to modify the texture outside of lock /unlock rect at the previously acquired memory location and then calling _AddDirtyRect to make it work. I verified that by turning wined3d sysmem allocation to VirtualAlloc and doing MEM_DECOMMIT instead of free (so the freed memory is not accessible and cannot be reused)
Looks like this hack to dxvk makes it work: https://gist.github.com/gofman/ce3d4267e01cf067bfecd607f7412991 (I know it is not a correct fix but hopefully it explains what the game wants).
Fixed by the PR.
d3d9.dllx1 2022-01
After starting the actual game from launcher some buttons have text partially missing. E. g, buttons at the bottom right to "Start game": " erver" instead of "Server" and " it ame" instead of "Exit game". There is similarly missing text elsewhere. After doing something (like connecting to another server) the pattern of missing letters changes.
The game's launcher currently does not start in released Wine or Proton (needs some WIP patches) but the issue is reproducible on Windows with dxvk's d3d9.dll dropped in.
Incidentally the same issue happens with both dxvk and wined3d under Wine.
I have partially debugged the issue and suppose that has something to do with the game expecting persistent texture locking memory addresses. The attached hack to wined3d (for illustration) fixes the issue.
The apitrace seems to break as well with the game probably around the same issue. The apitrace recorded on Windows replays without any text on the buttons at all on the same Windows machine (all that with native Windows d3d9) and similarly on Linux.
test.txt