I want GuiService to move the selector with arrow keys but not with WASD keys what can I do?

Hey I’ll have to change things a bit.

I have some game mechanic where the player utilizes the arrow keys and the WASD keys for two different things. Let’s say for a second that I want the player to move a car being seen from above with the wasd keys, while on the other side, the arrow keys allow you to use the phone in a similar way to gta 5.

Or, in another way, let’s say I wanted to make a scrabble game, and I wanted the selector to go left or right to insert a letter in the middle, like A, W, S or D.

When I use the menu selector, it does most of the job, but it overlaps the WASD keys which don’t let much happen and, instead, just work as more movement keys.

What should I do?

Forgive me if I’m mistaken as I’m not familiar with GuiService, but wouldn’t it be possible to make use of UserInputService in this particular case to distinguish the two?

I’m sure there’s a function present in GuiService that would permit you to move the selector correctly based off of those inputs.

1 Like

Well the thing is.

https://developer.roblox.com/en-us/api-reference/class/GuiService

there are so many functions in the page and so many of them don’t give any explanation to what they do, not even when you click on one of them, to the point you don’t know which one is the one you would be looking for.

They are either core functions that can’t be used without roblox permissions, functions that don’t write anything, or anything else.

It looks to me like you could modify the SelectedObject property on that page manually.

2 Likes

Also, if this turns out to help you, make sure to mark something as a solution so other users can refer to this later if they need to!

Yes yes, apologies, but if it wasn’t the bad wifi I have, it was the series I was watching with my family.

You can just use ContextActionService on the arrow keys to “steal” then from their original use for movement, and then just control the selected item with a custom script or with some kind of function of GUIService

If my meaning is correct, you want make something like
control car → press switch button → control phone → press switch button → control car…
If yes, try use ContextActionService:BindActionPriority()

Well, the thing here is that I don’t know what the ContextActionService function of the arrow keys are. These seem to be in the coregui.