Re: Exclamation Point in DirectInput Key List

new topic     » topic index » view thread      » older message » newer message

But exclamation point isn't always shift+1. On my keyboard (Czech layout)
it's on a different place. There must be another way to find out this...

    Martin


> Yes, you are right. My example isn't exactly correct. You must poll each 
> key in a seperate cycle of exotica. That's why you need the shift 
> variable.
> here's a better example:
> 
> -- SNIPPET --
> while 1 do
> if aActive()=1 then
>  dinput_update()
>  if keyboard_keystate(DIK_LSHIFT) or keyboard_keystate(DIK_RSHIFT) then
>    shift = 1
>  elsif shift and keyboard_keystate(DIK_1) then
>     -- EXCLAMATION PRESSED
>  end if
> end if
>  if exotica_error() then exotica_abort(1) end if
> end while
> -- END --
> 
> Chris
> 
> C. K. Lester wrote:
> > bensler at mail.com wrote:
> > > shift = keyboard_keystate(DIK_LSHIFT) or
> > > keyboard_keystate(DIK_RSHIFT)
> > > if shift and keyboard_keystate(DIK_1) then
> > >    -- EXCLAMATION PRESSED
> > > end if
> > 
> > I thought it only returned one key unless you used the multi-key 
> > processing code... which I'm not using.
> > 
> > 
> 
> 
>

new topic     » topic index » view thread      » older message » newer message

Search



Quick Links

User menu

Not signed in.

Misc Menu