Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

In-Game: Add support for desktop platforms to block the use of an IME during gameplay #5524

Closed
2 tasks
offalynne opened this issue Apr 17, 2024 · 10 comments
Closed
2 tasks
Assignees
Labels
documentation Improvements or additions to documentation are required by this issue feature request New feature (or a request for one)
Milestone

Comments

@offalynne
Copy link

offalynne commented Apr 17, 2024

Description

Windows IME bugs out Runner

Expected Change

Windows IME should be selectively disabled for the Runner application

Steps To Reproduce

  1. Install support for any language that using Input Method Editor eg. CJK
  2. Enable IME from taskbar or hotkey eg. Ctrl+CapsLock
  3. Run GM, observe that keyboard input is broken and any key press pops the IME open in the corner of the screen

How reliably can you recreate this issue using your steps above?

Always

Which version of GameMaker are you reporting this issue for?

2024.2.0 (Monthly)

Which platform(s) are you seeing the problem on?

Windows

Contact Us Package Attached?

  • I have attached my Contact Us Package

Sample Project Added?

  • I have included a small sample project
@offalynne offalynne added the runner-bug In-game bugs with the "GameMaker Studio 2" runtimes label Apr 17, 2024
@adam-coster
Copy link

@shichen85 if you want to share anything about your solution this would be the place!

@adam-coster
Copy link

Note that GameMaker receives VK Code 229 when the user tries to input with an IME (at least for Chinese), so in the absence of disabling the IME automatically you can at least detect that it is being used and tell the player to disable it.

@rwkay
Copy link

rwkay commented Apr 17, 2024

Do you have any documentation links on how to disable the IME?

@stuckie stuckie moved this from Triage to Todo in Team Workload Apr 17, 2024
@stuckie stuckie added this to the 2024.6 milestone Apr 17, 2024
@YYDan YYDan changed the title Windows IME bugs out Runner In-Game: Desktop platforms should block the use of an IME during gameplay Apr 17, 2024
@shichen85
Copy link

@adam-coster
Copy link

adam-coster commented Apr 17, 2024

Note that the ideal GameMaker behavior for this would be to have functions to enable/disable IME, and check to see if it is active. It should probably default to disabled.

That way we can disable it for regular game inputs but re-enable it when we want the user to actually be able to input text.

@yoyo-danielc
Copy link

This is fixed on the 2024.06 branch.

The key code 229 (VK_PROCESSKEY) doesn't get translated into GM now, and it is possible to disable IMEs by calling keyboard_virtual_hide() (and keyboard_virtual_show() to re-enable them).

@github-project-automation github-project-automation bot moved this from Todo to Done in Team Workload May 22, 2024
@YYDan YYDan added documentation Improvements or additions to documentation are required by this issue feature request New feature (or a request for one) and removed runner-bug In-game bugs with the "GameMaker Studio 2" runtimes labels May 22, 2024
@adam-coster
Copy link

@yoyo-danielc Some follow-ups to the new feature:

  • Is there a function or readonly variable for checking if IME is currently active?
  • What happens if I call keyboard_virtual_show() if it's already active? And the same for hide? (I'm hoping it just doesn't do anything, rather than, say, throwing.)

@yoyo-danielc
Copy link

@adam-coster

  • keyboard_virtual_status()
  • Yep, no-op

Also FYI, the status reported by keyboard_virtual_status() is whether or not IMEs are allowed, not whether the user specifically has one activated at this moment.

@YYDan YYDan changed the title In-Game: Desktop platforms should block the use of an IME during gameplay In-Game: Add support for desktop platforms to block the use of an IME during gameplay May 24, 2024
@gurpreetsinghmatharoo gurpreetsinghmatharoo moved this from Done to Ready for QA in Team Workload Jun 6, 2024
offalynne added a commit to offalynne/Input that referenced this issue Jun 11, 2024
offalynne added a commit to offalynne/Input that referenced this issue Jun 11, 2024
offalynne added a commit to offalynne/Input that referenced this issue Jun 11, 2024
@alicemoretti
Copy link
Contributor

Can we get a sample project to verify this please?

@alicemoretti
Copy link
Contributor

alicemoretti commented Jul 9, 2024

Verified fixed on IDE v2024.6.1.160 Runtime v2024.6.1.208.
Thank you.

@alicemoretti alicemoretti moved this from Ready for QA to Verified in Team Workload Jul 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation are required by this issue feature request New feature (or a request for one)
Projects
Status: Verified
Development

No branches or pull requests

9 participants