03-03-2004, 08:46 PM
Quote:Yay! It works! I'll try it in my program sometime today. This should still work when I compile my program, right?
Oh yeah, is there someway to access a game pad with QBASIC? I figure it uses INP statements, but don't know which port.
You have to know the Port number of your ports.
If you have plugged your gamepad into COM1, for example, do this:
-Right click on "My Computer"
-Goto Device Manager, (in XP it is under the Hardware tab)
-Scroll down to the Ports(COM and LPT) bit
-Open that bit out and doubleclick COM1.
-Click on the "Resources" Tab
-look at the I/O range. Take the first value. It maybe be something like 03F8.
-Take the 0 off the front and add &H. to get something like &H3F8.
There!! that would be the port for your gamepad. You can do the same for other ports as well.