How to use custom input device to play RF game

Programming Reality Factory and Genesis3D.
Post Reply
harRF
Posts: 6
Joined: Wed Oct 12, 2005 2:37 pm

How to use custom input device to play RF game

Post 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
harRF
Posts: 6
Joined: Wed Oct 12, 2005 2:37 pm

How to use custom input device to play RF game

Post by harRF »

Anybody... Please reply. I am stuck at interfacing.
User avatar
Spyrewolf
Posts: 450
Joined: Tue Jul 05, 2005 4:53 am
Location: Wellington::New Zealand

Post 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:
harRF
Posts: 6
Joined: Wed Oct 12, 2005 2:37 pm

Post 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.
User avatar
QuestOfDreams
Site Admin
Posts: 1520
Joined: Sun Jul 03, 2005 11:12 pm
Location: Austria
Contact:

Post 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()
harRF
Posts: 6
Joined: Wed Oct 12, 2005 2:37 pm

Post by harRF »

Thanks for your reply QuestOfDreams and syrewolf. I will try.
Post Reply