Page 1 of 1

Control direction with arrow keys instead of mouse

PostPosted: Tue Feb 11, 2014 13:16
by Megaf
Hi, is there a way to control movement with arrow keys? Like good old FPS shooters or race games?

I would suggest the following configuration
ASWD leave as it is now.

UP = Look Up
Left and Right = rotation on y axis
Down = Look Down

PostPosted: Tue Feb 11, 2014 14:13
by AMMOnym
I want it. Hmmm i need it becouse i dont have mouse

PostPosted: Tue Feb 11, 2014 15:32
by CitroPotter
Nice suggestion but i am Ok with the mouse.

PostPosted: Tue Feb 11, 2014 19:24
by Megaf
I think many people would like that, for some is just more natural, for others is a matter of not having a mouse (having a touchpad).

In my case, well, I'm playing minetest remotely, using VNC, this way I can play minetest at my workplace :P
Problem is, playing with mouse over VNC does not work very well.

I'm creating a poll, so let´s vote for arrows direction support!

PostPosted: Tue Feb 11, 2014 21:27
by Evergreen
I think having both as an option would be nice.

PostPosted: Tue Feb 11, 2014 21:37
by Calinou
+1, this is probably not too hard, speed of camera movement and "look spring" (make camera pitch go back to 0 when pitch keys are not pressed) should be available and configurable too, as well as a "center view" key.

PostPosted: Tue Feb 11, 2014 21:44
by MustLoveCats
I am perfectly fine with this only if we also are able to keep the old system of looking around with the mouse. Not everyone has a mouse, I know that, but remember not everyone doesn't!

PostPosted: Tue Feb 11, 2014 22:06
by Calinou
MustLoveCats wrote:I am perfectly fine with this only if we also are able to keep the old system of looking around with the mouse. Not everyone has a mouse, I know that, but remember not everyone doesn't!


It's quite obvious it'll be kept, if this ever gets included. :)

PostPosted: Wed Feb 12, 2014 00:48
by philipbenr
Evergreen wrote:I think having both as an option would be nice.

As an option in the settings menu.

PostPosted: Wed Feb 12, 2014 01:02
by onpon4
This would be a good start for making Minetest playable in situations where a mouse doesn't make sense (on the TV, with a laptop off of a table, etc). It would be even better if Minetest could support gamepads directly rather than having to use software like Qjoypad, but I guess that's harder, so starting with full-keyboard support makes sense.

PostPosted: Wed Feb 12, 2014 03:52
by Novacain
another thing that would be nice is dig buttons. say, ctrl = left click, alt = right click

PostPosted: Wed Feb 12, 2014 09:56
by Megaf
Novacain wrote:another thing that would be nice is dig buttons. say, ctrl = left click, alt = right click


Sure! That must be implemented with the arrows keys support!

PostPosted: Wed Feb 12, 2014 13:03
by MrElmux
In general i would suppose configurable inputs

PostPosted: Wed Feb 12, 2014 15:37
by Novacain
MrElmux wrote:In general i would suppose configurable inputs


this makes me wonder, would it really be that hard to add a few lines to the engine to add alternate input for arrow keys? this seems like it would take, at most, a couple hours to implement. We already have the turn function for the mouse, keyboard shouldn't be too hard to add.

PostPosted: Wed Feb 12, 2014 21:28
by Excalibur Zero
Hybrid Dog wrote:It's already possible to control the mouse with the keyboard, in German, it's called "Tastaturmaus", I think.

In English it is called Mouse Keys. (https://en.wikipedia.org/wiki/Mouse_keys)

PostPosted: Wed Feb 12, 2014 21:50
by Novacain
so, can we get it in the engine?

PostPosted: Wed Feb 12, 2014 21:59
by onpon4
Excalibur Zero wrote:
Hybrid Dog wrote:It's already possible to control the mouse with the keyboard, in German, it's called "Tastaturmaus", I think.

In English it is called Mouse Keys. (https://en.wikipedia.org/wiki/Mouse_keys)


Mouse keys is designed for accessibility, not gaming... mouse keys on my system, for example, is a little choppy and very slow. Not to mention it's on the numpad, which laptops don't tend to have directly as normal keys; and diagonals are separate keys. I hope the suggestion of using mouse keys for playing Minetest is a joke! :)

PostPosted: Thu Feb 13, 2014 16:42
by Novacain
here's an idea: WASD for movement, IJKL for looking, U for item scroll left, O for item scroll right, R for dig node, Y for place node. FGH become noclip, fly and fast, C becomes inventory. when inside inventory, you could use arrow keys to navigate the boxes, and R for left click function, Y for right click function. T for stacks of ten.

And I personally would change drop from Q to P. it is too easy to drop something when you are going for the 1 key.

and the thing is, that is actually a fairly intuitive layout.

PostPosted: Thu Feb 13, 2014 18:01
by Megaf
I just talked on IRC to CiaranG and it seems like we are halfway of getting arrow keys!

CiaranG and Megaf at #Minetest-Dev wrote:14:09:32 Megaf | Folks, I'm looking at the code trying to find an existing way to implement control via arrow keys instead of mouse, but I can't find anything very clear, can anyone help?
15:11:34 CiaranG | Megaf: Try this: https://github.com/CiaranG/minetest/commit/dbb97e12a9a6b92bccdb661cdab772868d01af7c
...
15:14:03 Megaf | CiaranG: did you request a pull?
15:14:27 CiaranG | No. There is a problem that I would want to resolve before I thought about that.
15:15:00 CiaranG | If you map the left/right mouse click to something else (i.e. a key) you can't then map it back to the mouse button (because the gui captures the mouse clicks)
15:15:19 CiaranG | (of course, you could just change the config file to map it back)
15:15:45 CiaranG | But it's good enough for what I needed it for, so I haven't tried to fix that yet. It's probably very easy.
...

15:58:56 Megaf | Ok, thank you CiaranG


So, now it's up to someone else to continue this.

PostPosted: Thu Feb 13, 2014 18:26
by Sokomine
For the android port, control via movement/orientation sensors would be great.

PostPosted: Thu Feb 13, 2014 20:40
by CiaranG
Megaf wrote:I just talked on IRC to CiaranG and it seems like we are halfway of getting arrow keys!


I'm pretty sure just temporarily disabling the GUI capture of the mouse while the 'Press a new key' bit is active will solve the only problem that I'm aware of. Everything else about it works fine for me.

If I get time at the weekend I'll take a look at doing that.

Re: Control direction with arrow keys instead of mouse

PostPosted: Thu Dec 29, 2016 09:58
by Murkle
Has anything happened with this so far? {BUMP} lol Are bumps allowed here? -Sorry if not :) I just want to know :)

Re: Control direction with arrow keys instead of mouse

PostPosted: Mon Jan 02, 2017 09:07
by Wuzzy
No.
But I agree with the feature. Minetest's controls need a lot of work.

See here:
- https://github.com/minetest/minetest/issues/4536
- https://github.com/minetest/minetest/issues/2361