Joy?(port) problem?

Blitz3D Forums/Blitz3D Programming/Joy?(port) problem?

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

When using joystick commands, I can use the optional port number to have a program act on one joystick instead of other joystick. I think there is a problem - connecting and disconnecting joysticks causes the joystick commands not to work properly. For example, I have MS Force Feedback joystick on joy?(0) and Logitech Driving Force Pro wheel/pedal set on joy?(1). If I disconnect the joystick from USB port, the joystick commands don't work because they expect two joysticks to be connected. How do I have a program check how many joysticks are connected to the USB ports and act on them?

If one joystick then use joy?() commands
If two joysticks then use joy?(0) and joy?(1) commands

Joy?() = any joystick commands like joyx() and joyy().