Jron Posted August 23, 2018 Share Posted August 23, 2018 Hello all! I am checking to see if I'm doing something wrong in my code, or if I found a compiler or Stella bug. I am having an issue with the joystick direction getting stuck frequently in Stella when the fire button is pressed. I have confirmed through the debug tools that the joystick direction switch is stuck on when this happens even though I am not holding down any cursor keys. The cursor keys on my computer are not having problems in any other software. It can be duplicated by pressing a direction and tapping the fire key and releasing the direction key. I think the timing needs to be right, but it will do it eventually. I am using DPC+ I've attached my debug basic code that is stripped of everything except for the movement, playfield collision, and animation code. I kept removing pieces of code hoping to find the culprit but no luck. The code that is left is based off from code I found in the "batari Basic Command Reference" which I modified to fit how I wanted the player to move on the screen. I am running the latest Batari Basic dev software found here in the forums and my Stella version is 5.1.3 I do not have a Harmony cart to be able to test this on a real 2600 (but I am curious if it also happens on a console). I appreciate everyone's time. debug-movement.bas.bin debug-movement.bas Quote Link to comment Share on other sites More sharing options...
ZackAttack Posted August 23, 2018 Share Posted August 23, 2018 Isn't that exactly what your code is designed to do? ;------------------------------------- ; Skip player movement if attacking (preserving player attacking animation) ; if joy0fire || _Bit0_P0_Attacking{0} then goto __Skip_Player_Movement Quote Link to comment Share on other sites More sharing options...
+Gemintronic Posted August 23, 2018 Share Posted August 23, 2018 I always use a USB joystick when testing builds. The keyboard can cause problems. Bluetooth keyboards are worse as with bad signals or low batteries they can repeat keystrokes. 1 Quote Link to comment Share on other sites More sharing options...
Jron Posted August 23, 2018 Author Share Posted August 23, 2018 I added that to try to fix the problem. I removed that and the next if statement and the problem still persists. Isn't that exactly what your code is designed to do? ;------------------------------------- ; Skip player movement if attacking (preserving player attacking animation) ; if joy0fire || _Bit0_P0_Attacking{0} then goto __Skip_Player_Movement I was thinking about that on my way to work. Maybe windows or my keyboard driver is doing a "sticky key" type thing? I will try using a usb gamepad tonight and report back. I always use a USB joystick when testing builds. The keyboard can cause problems. Bluetooth keyboards are worse as with bad signals or low batteries they can repeat keystrokes. Quote Link to comment Share on other sites More sharing options...
+stephena Posted August 23, 2018 Share Posted August 23, 2018 I cannot duplicate this in either Linux or Windows. Haven't tested in OSX, nor with any joysticks (keyboard only). Quote Link to comment Share on other sites More sharing options...
+SpiceWare Posted August 23, 2018 Share Posted August 23, 2018 Bluetooth keyboards are worse as with bad signals or low batteries they can repeat keystrokes. I've had issues with MAME and bluetooth keyboards. 2 Quote Link to comment Share on other sites More sharing options...
+Random Terrain Posted August 23, 2018 Share Posted August 23, 2018 Have you tried firing with the CTRL key instead of the space bar? 1 Quote Link to comment Share on other sites More sharing options...
Jron Posted August 23, 2018 Author Share Posted August 23, 2018 (edited) The problem does not happen when using the ctrl key. Thanks for that tip! Have you tried firing with the CTRL key instead of the space bar? It also doesn't do it when using a usb game pad. it must be something specific to my notebook's keyboard. Thanks everyone! Edit: I tested with my usb keyboard and could not duplicate it. I guess it must be a feature of Thinkpad keyboards. Edited August 23, 2018 by Jron 1 Quote Link to comment Share on other sites More sharing options...
+stephena Posted August 24, 2018 Share Posted August 24, 2018 Looks like our old friend is back: https://www.sjbaker.org/wiki/index.php?title=Keyboards_Are_Evil 2 Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.