Original Post
Hi guys,
I have setup a message handler for detecting movement of the scroll wheel, which is all good.
case WM_MOUSEWHEEL:
{
g_mouseZ=GET_WHEEL_DELTA_WPARAM(wParam);
}
break;
But, the problem I am having is that wParam seems to be holding the value until a different Window message is recieved, whether it be a keypress, mouse movement, or whatever.
I want to have it so g_mouseZ resets back to zero when the scroll wheel is not used.
In my main message loop I am setting g_mouseZ to zero manually but this doesn't work. I am still either getting 120 or -120 (depending on the initial scrollwheel direction of movement).
Any ideas on what might be going on?
[Edited by - lonewolff on September 9, 2010 9:34:31 PM]
I have setup a message handler for detecting movement of the scroll wheel, which is all good.
case WM_MOUSEWHEEL:
{
g_mouseZ=GET_WHEEL_DELTA_WPARAM(wParam);
}
break;
But, the problem I am having is that wParam seems to be holding the value until a different Window message is recieved, whether it be a keypress, mouse movement, or whatever.
I want to have it so g_mouseZ resets back to zero when the scroll wheel is not used.
In my main message loop I am setting g_mouseZ to zero manually but this doesn't work. I am still either getting 120 or -120 (depending on the initial scrollwheel direction of movement).
Any ideas on what might be going on?
[Edited by - lonewolff on September 9, 2010 9:34:31 PM]