How do I unfocus a textbox when an arrow key is pressed

Get help using Construct 2

Post » Fri May 01, 2015 3:24 pm

Hi!

Construct doesn't seem to be capable of regognizing specific key presses when the textbox-window is active. I'm trying to unfocus the textbox when the player wants to move forward by pressing the arrow keys, but it's not working -the textbox still has the focus. I also tried to use the browser object (because it has a blur command) but I was unsuccesfull with that approachh as well. To be clear, I would like the game to get the focus when the player presses one of the arrow keys (instead of the textbox), because when the textbox has the focus the player is stuck and can't move.

There must be some way to defocus/blur the textbox without having to use the mouse! Any ideas are welcome!
B
9
S
1
Posts: 97
Reputation: 715

Post » Sat May 02, 2015 2:14 pm

If this is not possible, I welcome that information as well!
B
9
S
1
Posts: 97
Reputation: 715

Post » Sat May 02, 2015 6:47 pm

I don't think it's possible without modifying the TextBox plugin. The TextBox plugin blocks all keys except escape and enter.
B
55
S
29
G
19
Posts: 1,520
Reputation: 25,650

Post » Sat May 02, 2015 7:47 pm

Okay thank you, it's very helpful to know that at least esc and enter work. I guess I will just have to educate the player with a sign that tells them to hit esc when the texbox opens.
B
9
S
1
Posts: 97
Reputation: 715

Post » Sat Jan 02, 2016 3:36 pm

Is there a way of having the textbox not steal input?
B
41
S
12
G
14
Posts: 1,117
Reputation: 11,253


Return to How do I....?

Who is online

Users browsing this forum: plinkie, zenox98 and 14 guests