[Bf-funboard] (attempt for a patch) GameEngine and more than 4 Axes joysticks

Carsten Wartmann carsten.wartmann at imago-viva.de
Wed Jun 21 16:05:23 CEST 2006



owning devices with more than 4 axis (in fact RC gear connected via USB) 
I looked into the joystick code of the gameengine.

It was an easy hack to make the GE use 2 more axes, but on my way I 
noticed some things:

- my C++ skills are not even enough to add really new things
- the code for the joystick is very... well.... static, hardcoded, 

So what I would do if I had time and brain to learn C++:

- make it more flexible, i.e. using an array of axes[NumAxes], NumAxes 
is already correctly reported
- report via python only used axes
- I guess we can't have "dynamic" LogicBricks, so I have no clue how to 
restrict the user from choosing axe 10 and wondering why there is no 
response. Maybe we should just trust that a user can count the axes on 
his controller (well, some developer already mixed axes with sticks ;-)

The attached patch shows where I hacked around pointing to the places 
which needs a change. Maybe some experienced developer can pick it up.


More information about the Bf-funboard mailing list