Suggestions for Joypad and Android

Got a cool idea that should be in R'n'D? Let's hear it!

Moderators: Flumminator, Zomis

User avatar
ango
Posts: 20
Joined: Sat Jun 10, 2017 9:38 am
Location: Germany

Re: Suggestions for Joypad and Android

Post by ango »

Just tested RnD on my Fire TV Stick.

The exit game error (using MENU and BACK button) no longer occurs.
Especially the last one is strange: After leaving the screen keyboard, the Fire TV remote control does not produce joystick and game controller events anymore, but sends keyboard events!
If you set the ingame control to keyboard, the keyboard is working. But only if you try to change the name and leave the screen keyboard. Also the dpad is working ingame, Very curious.
But there's another (clumsy, but easier) way to change the player name: Use the screen keyboard, then blindly erase the existing name using the backspace ("<=") key, then blindly type the new name and leave the screen keyboard.
Just tried ist but did not work for me. It only apends the new name on the existing name.

Apart from these errors the game runs quite well with the gamepad.
For the future, ingame control with dpad and a "Disable" option in: "Setup-Touch Ctrls-Toch Control Type" would be nice. Because you don´t need a touch control on the fire tv stick.
User avatar
ango
Posts: 20
Joined: Sat Jun 10, 2017 9:38 am
Location: Germany

Re: Suggestions for Joypad and Android

Post by ango »

Do you know how to connect to an Android device using "adb", the "Android Debug Bridge" command line tool? If so, you could watch/monitor the keyboard events using "adb logcat", and see which events are send when pressing the cursor keys.
I did it with adblink. In the menu of adblink you can open the console. With "adb logcat" I see the following events if I press the cursor keys up,down,left,right:

Code: Select all

D/Rocks'n'Diamonds(28250): SDL_JOYBUTTONDOWN: device 2, button 11
D/Rocks'n'Diamonds(28250): SDL_JOYBUTTONUP: device 2, button 11
D/Rocks'n'Diamonds(28250): SDL_JOYBUTTONDOWN: device 2, button 12
D/Rocks'n'Diamonds(28250): SDL_JOYBUTTONUP: device 2, button 12
D/Rocks'n'Diamonds(28250): SDL_JOYBUTTONDOWN: device 2, button 13
D/Rocks'n'Diamonds(28250): SDL_JOYBUTTONUP: device 2, button 13
D/Rocks'n'Diamonds(28250): SDL_JOYBUTTONDOWN: device 2, button 14
D/Rocks'n'Diamonds(28250): SDL_JOYBUTTONUP: device 2, button 14
filbo
Posts: 647
Joined: Fri Jun 20, 2014 10:06 am

Re: Suggestions for Joypad and Android

Post by filbo »

ango wrote: Sat Jul 15, 2017 12:44 pm If you want exit the game and you use the HOME button, but then decide against it and use the BACK button, the controller is going crazy :)
The steering is very fast and the controller mapping is gone. You have to restart the game. The problem occurs only if you use the button combination HOME and BACK.
I wonder if this relates to a problem I've seen on Linux desktop.

I have the keys '0'..'5' configured to do various 'tape' things.

Meanwhile, modifier-digit (like 'Ctrl-3') sequences are configured to change the gameplay speed (frame rate).

Occasionally RnD will get into a state where the digits cause frame rate changes even with no modifiers held down; as if some internal accounting of modifiers (in SDL and/or RnD, or maybe even X11) has gone wrong. So e.g. I hit '1', no modifier, and the game goes to ultra-slow frame rate.

I do the usual thing, tap all the modifier keys (left/right shift/ctrl/alt/'win'), click each mouse button, try to get all the state trackers back to normal -- but it doesn't work. I end up having to restart RnD.

If at some level those keys are mapped to digits, and the same sort of 'modifier stuck on' thing is happening, that might explain the 'very fast'. (e.g.: 'Home' is '7' on full-sized PC keyboard's numeric pad; 'modifier-7' is a moderately fast frame rate in RnD...) And a stuck modifier might explain 'controller mapping is gone'.

Holger: a possibly helpful thing would be an on-screen heads-up display of all the modifier states. Turned on in some obscure debug menu, of course :)
Post Reply