flat assembler
Message board for the users of flat assembler.

Index > Windows > Problems with PeekMessage & GetMessage.

Author
Thread Post new topic Reply to topic
Roman



Joined: 21 Apr 2012
Posts: 1792
Roman 21 Aug 2024, 07:06
Windows 10.
When open Firefox browsers and some window,task manager.
My game sometimes ignored WM_KEYDOWN from WndProc.
I pressed three times Esc(two seconds passed) then my program see Esc key and closed my program.

I try PeekMessage & GetMessage result the same.
Code:
MSG msg ;
invoke GetMessage,msg, 0, 0, 0
test eax,eax
jz @f
    invoke TranslateMessage,msg
    invoke DispatchMessage,msg
@@:    
Post 21 Aug 2024, 07:06
View user's profile Send private message Reply with quote
revolution
When all else fails, read the source


Joined: 24 Aug 2004
Posts: 20339
Location: In your JS exploiting you and your system
revolution 21 Aug 2024, 08:09
Please show a minimal working example where the code fails.
Post 21 Aug 2024, 08:09
View user's profile Send private message Visit poster's website Reply with quote
Furs



Joined: 04 Mar 2016
Posts: 2503
Furs 21 Aug 2024, 13:36
You need to call GetMessage in a loop. Maybe some unrelated message got received.
Post 21 Aug 2024, 13:36
View user's profile Send private message Reply with quote
Roman



Joined: 21 Apr 2012
Posts: 1792
Roman 21 Aug 2024, 14:27
I want looking DirectInput mad Matt ?
Post 21 Aug 2024, 14:27
View user's profile Send private message Reply with quote
Display posts from previous:
Post new topic Reply to topic

Jump to:  


< Last Thread | Next Thread >
Forum Rules:
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Copyright © 1999-2024, Tomasz Grysztar. Also on GitHub, YouTube.

Website powered by rwasa.