Game Development Community

No joystick support in 1.5?

by Jacco Jansen · in Hardware Issues · 08/23/2007 (6:15 am) · 3 replies

I have enabled the $pref for joystick use,
I have called enableDirectInput()
I have called enableJoystick()
I have created functions for the buttons to call
i have bound the functions to joystick buttons using all manner of combinations including
movemap.bind(joystick, button1, functionA);
movemap.bind(joystick0, button1, functionA);
movemap.bind("joystick", button1, functionA);
movemap.bind("joystick", "button1", functionA);
movemap.bind("joystick", "button1", "functionA");
movemap.bind(joystick0, "button1", functionA);
etc etc etc...

When binding the same function to keyboard keys it works perfectly but when changing it to joystick it simple refuses to work. I am using an XBOX controller on my Mac and in system settings all the joystick buttons respond when pressed.

Inside torque, inspecting the output in the console it seems that it cannot find my joystick. First of all.
Secondly, it reports the functions enableJoystick() and disableJoystick() as functions that are not found
See 6.5 and 6.8 in this link....
tdn.garagegames.com/wiki/TorqueScript_Console_Functions

isJoystickDetected() does work and reports no joysticks found, although my system does trecognise it as a generic controller...

Why in the world is my joystick not recognised and how do I enable it??????

#1
10/11/2007 (5:28 am)
I don't have your particular configuration, I have Win XP 64 and a Logitech attack 3 USB joy stick, running Torque 1.5.2 and it works for me. So as far as Torque 1.5.2 supporting joysticks, it does. Sorry I can't be of any help to you other than confirming that 1.5.2 does support joysticks.
#2
10/11/2007 (6:23 am)
I use the same stick...works fine. Haven't tried my wheel and pedals yet, however. Do you use the Logictech Profiler software to 'use/activate' it, Sgb? Without it running, engine doesn't accept input from it[stick]. I'm merely an 'Artist' though, looking for easiest way to get something working....WinOS based system XP dual cores.

...I am definitely interested in learning more about the input setups, since my steering wheel will come in handy testing my vehicles, stick works, but there's so much more immersion with a wheel and pedals!
#3
10/11/2007 (7:05 am)
I am running OSX and trying to use an XBOX controller. The controller has drivers installed and is configured properly. Does Torque have particular joypad demands or does it work with any installed joypad?

What is interresting is that both enableJoystick() and disableJoystick() both report:
"could not find function"

I wonder ifthat may have anything to do with the price of eggs?

Where are these two functions defined? Is it located in script or in the engine? In the case of the latter, could someone please point me towards the part where the function is made available to the scripting engine? Perhaps this is where the problems lay....?

It is all I can think of...