Gamestudio Links
Zorro Links
Newest Posts
Change chart colours
by 7th_zorro. 05/11/24 09:25
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
2 registered members (vicknick, AndrewAMD), 1,292 guests, and 3 spiders.
Key: Admin, Global Mod, Mod
Newest Members
Hanky27, firatv, wandaluciaia, Mega_Rod, EternallyCurious
19051 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
[A6.60] All digital Gamepad #285528
08/18/09 22:00
08/18/09 22:00
Joined: Feb 2006
Posts: 2,185
mpdeveloper_B Offline OP
Expert
mpdeveloper_B  Offline OP
Expert

Joined: Feb 2006
Posts: 2,185
I was wondering if anyone had problems with all digital gamepads when using the joystick commands: joy_raw, joy_hat, and joy_rot. The gamepads are always showing as the up button being pressed even though it isn't. Multiple joysticks do this, and they have been tested and calibrated to make sure if that was the problem, so it's not a calibration issue, and the buttons are not messed up.

This happens ONLY with all digital as far as I've seen. Controllers that have analog and digital seem to work perfectly fine. Is there a workaround for this (other than using joy_force)? I can't use joy_force because I have to be able to use 2 joysticks.


- aka Manslayer101
Re: [A6.60] All digital Gamepad [Re: mpdeveloper_B] #285563
08/19/09 02:57
08/19/09 02:57
Joined: Jan 2006
Posts: 2,157
Connecticut, USA
Blink Offline

Expert
Blink  Offline

Expert

Joined: Jan 2006
Posts: 2,157
Connecticut, USA
i dont know mp, i have been using a xbox 360 controller, and i havent had any problems. i had a logitech joypad that worked the way you described, so i gave up, but the 360 controller has been flawless.


My Famous Quotes: "Hip hop is like a virus, infecting everyone and everything around it. Every form of media has some way,shape or form, assimilated hip hop into it." It has also mutated into other strains like, trip hop, house, rap, gangster, and conscious forms. Once you are infected with it, its with you for life."
Re: [A6.60] All digital Gamepad [Re: Blink] #285579
08/19/09 06:55
08/19/09 06:55
Joined: Jul 2000
Posts: 27,986
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,986
Frankfurt
Digital gamepads are supported and work well, at least with the current version. We also have in our records no known A6 problem with gamepads. Maybe, the problem is related to the pad you're using, like a defect microswitch on the up button?

Otherwise, is the problem A6.60 specific? You can check this easily by testing the gamepad with the free Atari lite-C.

Re: [A6.60] All digital Gamepad [Re: jcl] #285674
08/19/09 16:08
08/19/09 16:08
Joined: Feb 2006
Posts: 2,185
mpdeveloper_B Offline OP
Expert
mpdeveloper_B  Offline OP
Expert

Joined: Feb 2006
Posts: 2,185
@Blink: that's because a 360 controller has analog and digital, this happens only with gamepads that do not have analog as far as i've noticed.

@jcl: I'm not so sure it's related to the pad because it happens with more than one. The code I'm using is this:

Don't worry about the variables such as p1_deadzone, etc. These are just to check which joystick is being pressed. THIS IS NOT THE ISSUE, SO PLEASE DON'T ASK.

Code:
function press_axis(dir, joynum)
{
	var d;
	if (joynum == 1 && num_joysticks >= 1)
	{
		d = ((p1_deadzone/100) * 127.5);
		
		if (dir == joy_up) { if (joy_raw.y < -d) { dir = -(joy_raw.y/255); return(dir); } }
		if (dir == joy_down) { if (joy_raw.y > d) { dir = (joy_raw.y/255); return(dir); } }
		if (dir == joy_left) { if (joy_raw.x < -d) { dir = -(joy_raw.x/255); return(dir); } }
		if (dir == joy_right) { if (joy_raw.x > d) { dir = (joy_raw.x/255); return(dir); } }
		
		if (dir == joy_up) { if (joy_hat >= 0 && joy_hat <= 45 || joy_hat >= 315) { return(1); } }
		if (dir == joy_left) { if (joy_hat >= 270 && joy_hat <= 315 || joy_hat <= 270 && joy_hat >= 225) { return(1); } }
		if (dir == joy_down) { if (joy_hat >= 180 && joy_hat <= 225 || joy_hat <= 180 && joy_hat >= 135) { return(1); } }
		if (dir == joy_right) { if (joy_hat >= 90 && joy_hat <= 135 || joy_hat <= 90 && joy_hat >= 45) { return(1); } }
	}
	if (joynum == 2 && num_joysticks >= 2)
	{
		d = ((p2_deadzone/100) * 127.5);
		
		if (dir == joy_up) { if (joy2_raw.y < -d) { dir = -(joy2_raw.y/255); return(dir); } }
		if (dir == joy_down) { if (joy2_raw.y > d) { dir = (joy2_raw.y/255); return(dir); } }
		if (dir == joy_left) { if (joy2_raw.x < -d) { dir = -(joy2_raw.x/255); return(dir); } }
		if (dir == joy_right) { if (joy2_raw.x > d) { dir = (joy2_raw.x/255); return(dir); } }
		
		if (dir == joy_up) { if (joy2_hat >= 0 && joy2_hat <= 45 || joy2_hat >= 315) { return(1); } }
		if (dir == joy_left) { if (joy2_hat >= 270 && joy2_hat <= 315 || joy2_hat <= 270 && joy2_hat >= 225) { return(1); } }
		if (dir == joy_down) { if (joy2_hat >= 180 && joy2_hat <= 225 || joy2_hat <= 180 && joy2_hat >= 135) { return(1); } }
		if (dir == joy_right) { if (joy2_hat >= 90 && joy2_hat <= 135 || joy2_hat <= 90 && joy2_hat >= 45) { return(1); } }
	}
	return(0);
}



I'm not sure if it is A6 specific, this is the first I've heard of the problem. The gamepads show up fine in windows and registers perfectly in windows, so I'm not sure the controllers are at fault. I'll try testing with lite-c I suppose.


- aka Manslayer101
Re: [A6.60] All digital Gamepad [Re: mpdeveloper_B] #285676
08/19/09 16:27
08/19/09 16:27
Joined: Feb 2006
Posts: 2,185
mpdeveloper_B Offline OP
Expert
mpdeveloper_B  Offline OP
Expert

Joined: Feb 2006
Posts: 2,185
Just tested with Lite-C, it happens there too. As before mentioned I don't think it's the controller, this doesn't happen with just one.

Last edited by mpdeveloper_B; 08/19/09 16:29.

- aka Manslayer101
Re: [A6.60] All digital Gamepad [Re: mpdeveloper_B] #285921
08/21/09 15:30
08/21/09 15:30
Joined: Jul 2000
Posts: 27,986
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,986
Frankfurt
Which brand is that gamepad, and which joy_raw.y value do you get without, and with the up button pressed?


Re: [A6.60] All digital Gamepad [Re: jcl] #285934
08/21/09 16:16
08/21/09 16:16
Joined: Feb 2006
Posts: 2,185
mpdeveloper_B Offline OP
Expert
mpdeveloper_B  Offline OP
Expert

Joined: Feb 2006
Posts: 2,185
the first gamepad is a Saitek P150, the second is a Gameon gamepad (model# FT2E92) both do not include analog.

The value is always 255 (or in the case of the code above, it always returns 1). I believe that it is only the up button that is counted as being pressed, and it's not only on the joy_raw.y value either, it's also on the joy_hat value.


- aka Manslayer101
Re: [A6.60] All digital Gamepad [Re: mpdeveloper_B] #286983
08/28/09 17:02
08/28/09 17:02
Joined: Feb 2006
Posts: 2,185
mpdeveloper_B Offline OP
Expert
mpdeveloper_B  Offline OP
Expert

Joined: Feb 2006
Posts: 2,185
So has there been any progress on finding the cause of this bug?


- aka Manslayer101
Re: [A6.60] All digital Gamepad [Re: mpdeveloper_B] #287278
08/31/09 07:19
08/31/09 07:19
Joined: Jul 2000
Posts: 27,986
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,986
Frankfurt
I could not get a Saitek P150, thus I ordered a P220 in the hope that it has the same bug, but it isn't arrived yet.

Re: [A6.60] All digital Gamepad [Re: jcl] #287496
09/01/09 03:40
09/01/09 03:40
Joined: Feb 2006
Posts: 2,185
mpdeveloper_B Offline OP
Expert
mpdeveloper_B  Offline OP
Expert

Joined: Feb 2006
Posts: 2,185
ok, thanks. It would also be nice if other people who have some digital exclusive gamepads could try too. I look forward to your results, and a possible solution.


- aka Manslayer101
Page 1 of 2 1 2

Moderated by  old_bill, Tobias 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1