Page 1 of 2

[.01] Some Problems with the Mousdriver (4.xx)

Posted: Thu Aug 01, 2013 8:32 am
by JayJayX

I used a long time Sandboxie V3.76. after the upgrade to V4. I have Problems with the Mouse at many Games:
L4D2, Team Fortress and also Beat Hazard. The Mouse works here like an analog stick.
In Valves Games I can switch in the Options to direct Mode without any Mousedriver but in Beat Hazard there is no option for this.
Roll back to V3.76 let me use the Mouse normal.

Any Ideas?

Posted: Thu Aug 01, 2013 8:49 am
You need to put OpenWinClass=* setting into each of your games Sandboxes' configuration section in "Sandboxie.ini".
Or you can add an asterisk * to Window Access in the respective Sandbox Settings from Sandboxie Control.

There are downsides to this setting:
(1) Maybe can't run multiple instances of the same game.
(2) No tray icons for these sandboxed processes.

Decreased security? Not that I've found. This setting is purported to allow "full communication with all windows outside the sandbox" but Sandboxie v4 processes can't so much as (directly) show/hide an existing window outside... I don't know if that's a bug.

Posted: Fri Aug 02, 2013 5:01 am
by JayJayX

thx for the hint.
No Multiple Instances is no Problem for me, but the Tray Icons are needed. So I will stay on the 3.76 'til it is fixed.

My Question: Why don't work only for some games?

Posted: Fri Aug 02, 2013 5:14 am
by tzuk
Good point BUCKAROO. I am posting my answer in the topic about OpenWinClass=*, here:

Posted: Fri Aug 09, 2013 5:15 am
by JayJayX

but it makes Steam or many of it's games unuseable. I have to choose between not working Games or an not useable Steam.
In Steam I have no TrayIcon anymore and so I can't open it's windows. In steamchat the Returnkey doesn't work anymore.

Is there no way to get back the behaviour of V3.76?

Posted: Fri Aug 09, 2013 7:45 am
by tzuk
Ideally the reason for the mouse going crazy would eventually become clear and once I fix that, you wouldn't need to use the OpenWinClass=* workaround anymore. Perhaps you can produce a Resource Access Monitor log and if we see that you have any third party mouse DLLs, I could try to install those and see what happens. ... essMonitor

Posted: Fri Aug 09, 2013 8:11 am
by JayJayX
I attached the whole output made with 3.76 for one of the not working games. Do you need another output with the latest 4.x?
very long please delete if you read it :)

snipped. --tzuk

Posted: Fri Aug 09, 2013 8:42 am
by tzuk
Thank you for the log. Please try the following after upgrading to version 4.05.04 and getting rid of OpenWinClass=*.

Can you try to get rid of some of your third party DLLs to see if it makes any difference?

c:\program files (x86)\autosizer\autosizer.dll
c:\program files (x86)\fraps\fraps32.dll
c:\program files\filebx\filebxh32.dll

You should be able to do that easily by going into Sandbox Settings > Resource Access > File Access > Blocked Access
and adding with Edit/Add, one by one:

Also try adding in > Resource Access > IPC Access > Direct Access:
for the DirectInput stuff

I won't be able to respond immediately but thank you in advance for doing this :)

Posted: Fri Aug 09, 2013 1:56 pm
by JayJayX
ok I installed the latest beta and tested this things but it doesn't change anything :(
I also tried OpenWinClass=* only for the beathazard.exe but it doesn't work, too.
I have to enter OpenWinClass=* for the whole sandbox.

Posted: Sat Aug 10, 2013 3:07 pm
by tzuk
If I understand the problem correctly (as described by other posts) then the mouse overreacts to movement and even a small movement is treated like you made a very large movement. If this is correct then I have the following questions:

First, do you know if you use a high definition mouse?

Second, what do you see in Mouse Properties in Control Panel in the Pointer Options tab?

I have a speed setting roughly in the center of the range.
Enhance pointer precision is checked.
The other settings there do not seem relevant.

Posted: Sat Aug 10, 2013 4:03 pm
by JayJayX
I'am not sure I understand you right, my pointer overreacts too,
but it's more an behavior like an analog stick.
There is an centerpoint (not at start, i have to search for this point) and I can move the pointer with very small movements of my mouse.
For examble:
If I found the centerpoint, the pointer stand still. When I move the mouse a little bit to the right, the pointer moves to the right until I move the mouse back, it did not stand still like an mouse pointer. I move the mouse more to the right, the pointer moves faster to the right until I move the mouse back.

I hope you can understand what I mean.

Yes I think I have an high definition mouse 5700 DPI set to 2000DPI (Logitech G500 with the Logitech Gaming Software 8.45.88 )

I have also the speedsetting in the center.
the checkbox for Enhance Pointer Precision is unchecked here.

The Problem in not generally, most of the Software/Games are working.

Posted: Sun Aug 11, 2013 3:32 am
by tzuk
I saw some discussion by Microsoft about how programs that want high resolution mouse tracking must use a special approach to talking to the mouse. Maybe it's just these handful of games that are aware of your high res mouse, and all the others do the regular thing.

As for the enhance pointer precision feature, it should have something to do with how quickly the mouse accelerates.

I suggest first to turn on enhance pointer precision and see if it makes a difference.

If not, I suggest next to check your mouse if there is any way to make it normal/low resolution. This doesn't have to be the long term solution, but I would like to know if has anything to do with the problem in the first place.

Posted: Sat Oct 19, 2013 12:46 pm
Nothing so complicated, tzuk. :)

It's like mouse deltas are not discrete anymore. It has a delta but the bug made it seem cumulative (whether in the negative or positive direction).

Anyway, here's the problem:


Code: Select all

"MouseLock" adapted from Torque3D source
x86 & x64 compatible AutoHotkey_L script

AutoHotkey_L =>

Save as "MouseLock.ahk" & drop onto exe.

Gui,1:-AlwaysOnTop +Caption +OwnDialogs +Resize 
Global Gui1:=WinExist()
Global Gui1_Edit1_hWnd
Gui,1:Add,Edit,R35 W240 HwndGui1_Edit1_hWnd VGui1_Edit1
Gui,1:Show,W640 H480





	; AutoHotkey drops messages without this line.
	; Unfortunately it makes other messages dodgy.
	; Actually, it'll deteriorate after some time.
	; subsequent coordinates unaffected by sibling windows
	;// Convert the incoming client pos into a screen pos, so we can
	;// accurately convert to relative coordinates.
	;// Hide the cursor before it's moved
;	DllCall("ShowCursor","Int",FALSE,"Int")
	;// Recenter the mouse if necessary (don't flood the message pump)
		Edit.="SetCursorPos() returned " BOOL "`r`n" "GetLastError() returned " A_LastError "`r`n" """" FormatMessage(A_LastError) """" "`r`n"
	;// Now we can calculate the position relative to the center we set.
	Text=mouseX=%mouseX% mouseY=%mouseY%`r`ncenterX=%centerX% centerY=%centerY%`r`ndeltaX=%deltaX% deltaY=%deltaY%
	Edit.=Text "`r`n`r`n"
	return 0

PrependEdit(ByRef Text)
	DllCall("SendMessage","UPtr",Gui1_Edit1_hWnd,"UInt",0x00B1,"UPtr",0,"Ptr",0,"Ptr") ; EM_SETSEL
	DllCall("SendMessage","UPtr",Gui1_Edit1_hWnd,"UInt",0x00C2,"UPtr",FALSE,"Ptr",&Text,"Ptr") ; EM_REPLACESEL

	static Buffer
	return RegExReplace(Buffer,"(.*)[`r`n]*$","$1")

Posted: Sun Oct 20, 2013 2:29 am
by tzuk
BUCKAROO wrote:Anyway, here's the problem: SetCursorPos ERROR_ACCESS_DENIED
Interesting! Great job picking up on that.
Let me add support for SetCursorPos API and let's see if it works!

Posted: Sun Oct 20, 2013 3:49 pm
by tzuk
I added support for this API today, and the script now says SetCursorPos() returned 1, both in the sandbox and outside the sandbox.
Hopefully this will have the desired effect on those games where the mouse behaves strange.
I want to get to a few more fixes before I release another beta version, so I will ask for your patience for a few more days.