Game Development Community

Problems with updates from joysticks

by K. Anderson · in Torque Game Builder · 09/04/2008 (3:23 pm) · 7 replies

I've brought over the joystick setup I've been using for TGE into TGB 1.7.4. The inputs and values all remain the same and everything works great, the problem is in the frequency of the updates or inputs from the joystick.

There's 2 joysticks, a slider and 2 buttons right now, with both joysticks providing input the calls through the action map go up to around 1200-1500 calls a second. Which cranks the CPU usage up nearly, if not to, the max.

I don't have any other joysticks available to compare the input rates, has anybody else noticed this? I'm looking for a way to slow it down.

#1
09/11/2008 (12:34 am)
I've never noticed this myself. Are they normal USB joysticks?
#2
09/11/2008 (12:39 am)
No, they're custom hardware set up as input devices by using ppjoy (http://www.geocities.com/deonvdw/Docs/PPJoyMain.htm) software for a virtual joystick so that Torque recognizes them as input devices.

TGE side its been working perfectly, only now going over to TGB is it coming up. I'm thinking of trying out a 360 controller for joystick inputs and see if the problem repeats itself.
#3
09/11/2008 (12:58 am)
Don't use the XBCD drivers for Xbox joysticks - they crash TGB when you click outside the window. Stick with the official microsoft xbox 360 drivers.
#4
09/11/2008 (1:00 am)
For the 360 controller?
#5
09/11/2008 (1:01 am)
Yes - stick with the regular microsoft drivers that auto install when you plug it in. A lot of people switch to XBCD drivers (they have better support for the analog triggers) - but they won't work with TGB. I use an old xbox controller S with XBCD and it works ok until you click outside the window, or alt-tab or minimize, then TGB crashes.
#6
09/11/2008 (1:03 am)
Gotcha, thanks.
#7
09/16/2008 (10:19 am)
Gave the 360 controller a shot and the updates through those joysticks aren't happening on a constant basis, only when the input changes. The other in comparison constantly updates whether or not there's new input. So it looks like the problem lies with the virtual joystick rather than anything controlled through TGB. I think I'll start searching for alternatives or ways to modify how this is acting.