Jarcho / d2dx

D2DX is a complete solution to make Diablo II run well on modern PCs, with high fps and better resolutions.
GNU General Public License v3.0
51 stars 3 forks source link

Cursor jumping on weapon switch #26

Closed nelsonmenon closed 9 months ago

nelsonmenon commented 9 months ago

diablo 2 1.14d plugy 14.03 latest d2dx W is the hotkey for weapon switch

Jarcho commented 9 months ago

I'm unable to replicate this. Is it happening all the time when weapon switching?

nelsonmenon commented 9 months ago

Hi Jarcho.

I discovered the source of the jumping. It's related to the window scale, I play in windowed mode with the scale at 1.3. I put the scale at 1 and the jumping stops. This is my d2dx.cfg:

#

This is an example config file for D2DX.

#

If you don't like the default settings, you can edit this file, rename it to "d2dx.cfg"

and place it in the game folder.

#

[window] scale=1.3 # range 1.0-3.0, a scale factor for the window position=[-1,-1] # if [-1,-1] the window will be centered, otherwise placed at the explicit position given here frameless=false # if true, the window frame (caption bar etc) will be removed

[game] size=[1068,600] # if [-1,-1] d2dx will decide a suitable game size, otherwise will use the size given here filtering=3 # if 0, will use high quality filtering (sharp, more pixelated)

1, will use bilinear filtering (blurry)

                    #    2, will use catmull-rom filtering (higher quality than bilinear)
                    #    3, will use nearest neighbour filtering (sharp, pixelated)
                    #    4, will rasterize the game at the target resolution

bilinear-sharpness=2.0 # Sharpness of the bilinear filter when rendering textures. Can be set to any value higher than 1.

1.0, same as a regular bilinear filter

                    #    2.0, same as a 2x bilinear-sharp filter

#

Opt-outs from default D2DX behavior

# [optouts] noclipcursor=false # if true, will not lock the mouse cursor to the game window nofpsmod=false # if true, will not load d2fps noresmod=false # if true, will not apply the built-in D2HD resolution mod (precludes widescreen support) nowide=false # if true, will not choose a widescreen resolution (if noresmod is true, this does nothing) nologo=true # if true, will not display the D2DX logo on the title screen novsync=true # if true, will not use vertical sync noframetearing=true # if true, will not allow frame tearing; must be false for variable refresh to work noaa=false # if true, will not apply anti-aliasing to jagged edges nocompatmodefix=false # if true, will not block the use of "Windows XP compatibility mode" notitlechange=true # if true, will not change the window title text nokeepaspectratio=false # if true, will not keep the aspect ratio when drawing to the screen

Jarcho commented 9 months ago

Fixed on master along with another cursor bug. It required a non-integer window like you suggested.

Hopefully this is all the window handling bugs fixed.