keyboard_string string comparison issue

Reporter: time-killer-games  |  Status: open  |  Last Modified: July 18, 2020, 04:06:00 PM

if you type in "poop" for example, just like any other given string, and draw that keyboard string with draw_text it will show the correct string, however try comparing that value with what it actually equals, and oddly enough, keyboard_string will always != "poop" or whatever string you typed, even though draw text shows the strings should be equal.

l tested this and cannot reproduce it. Can you upload an example?

Added to the ticket. The issue was reproduced on Windows (although I'm not sure if that makes a difference here).

If you move the if (keyboard_string == "poop") show_message("fuck joo bitch !!!"); to step it will work. The issue is with you pressing the "enter" key, Does this work as you expect in GM?


Look at #2062 I think I had started to discover why SDL's text input is done the way that it is. The enter key is probably part of the text related window messages, and Win32 should be changed to do it like SDL as part of the keyboard_string cleanup. Feel free to finish my pull request, I'm working on other stuff.
Please sign in to post comments, or you can view this issue on GitHub.