Page 1 of 1

How to use custom input device to play RF game

Posted: Wed Oct 12, 2005 3:29 pm
by harRF
Group members,
I am a newbie to RF and just started using it for a project which is more of a 3D walkthrough than a game. I have a custom designed input device (similar to a joystick) connected to the serial port and I wish to control left, right, forward and backward movements with it.
The orientation of the device can be read from the serial port. I wish to know what modifications do I need to make for using this input device.

Thanks,
H

How to use custom input device to play RF game

Posted: Wed Oct 12, 2005 7:28 pm
by harRF
Anybody... Please reply. I am stuck at interfacing.

Posted: Thu Oct 13, 2005 2:54 am
by Spyrewolf
check the scripting part of the documentation, there are commands which allow joysticks to be enabled,

i believe you can get a read out of values from a device, but i have not tried this i.e joystickleft =450 or something

im not entirely sure but i think its something along those lines.....

could be way off though,

......jus read up on the scripting section and that should put you right :wink:

Posted: Thu Oct 13, 2005 3:40 am
by harRF
I know joystick may be enabled. But the status of the input device that I have can only be read from the COM port say using inport function as in c++ . I think it would not follow standard directx protocols.
Basically I will have raw data for the left, right, front, & back status of the device and I have to cause motion with those.

Hope I am clear.

Posted: Thu Oct 13, 2005 10:04 am
by QuestOfDreams
The CInput class reads the input from keyboard and mouse, I suggest you add your routines there. The input gets processed in CCommonData:HandleGameInput()

Posted: Thu Oct 13, 2005 4:49 pm
by harRF
Thanks for your reply QuestOfDreams and syrewolf. I will try.