Skip to content

NumLock makes buttons false reporting as pressed #507

@MiranDMC

Description

@MiranDMC

Clicking NumLock button while any numpad key is hold down causes all key related commands to report it as down, even after release.
Test script:

{$CLEO}
nop

while true
    wait 0
    
    int a = false
    if
        is_key_pressed {keyCode} KeyCode.NumPad8
    then
        a = true
    end
    
    int b = false
    if
        is_key_pressed {keyCode} KeyCode.Up
    then
        b = true
    end
    
    print_formatted_now {format} "Num8: %d~n~Up: %d" {time} 50 {args} a b
end

This seems to be known problem of GetKeyState API, without good solution.

Metadata

Metadata

Assignees

No one assigned

    Labels

    discussionFurther discussion is requested

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions