One more thing, though.
What got me a little distracted was the bOnOff parameter.
Why use it at all if you always have to pass in TRUE ?


invoke GetKeyboardState, addr keyState
lea eax,keyState
mov ecx, wVkey
mov al,byte ptr [eax+ecx]
and eax,0FFh
xor eax,1
[B]cmp eax,bOnOff[/B]
jnz @F

Passing bOnOff as 0 or 1 makes it possible to compare 'your setting' to current keyb. state.

I didn't realized you needed it to be 'FLASHED', I thought that all you wanted to do is once ;-)
Posted on 2002-08-03 20:02:29 by Andycar
But then again GetKeyboardState will always return 0 for VK_NUMLOCK if it is initially off.
So passing in FALSE will skip the LED-switching part although numlock is on.

I need to go to bed it's 4 in the morning and I'm tired.
I'll see you tomorrow.
Posted on 2002-08-03 20:57:39 by goofee
I think there is a DirectX way to do it.

using IDirectInputDevice8::SendDeviceData method but I don't know how to do it or the initial steps before we use it. :(
Posted on 2002-08-04 15:43:52 by stryker