totenhose
17-12-2007 14:42:31
Hi,
I'm trying to get joystick work in MOgre application with MOIS. I created inputsystem and the joystick is listed with ListFreeDevices() command. But if i run the code with part where the joystick object is created, the application gives runtime error:
System.Runtime.InteropServices.SEHException: External component has thrown an exception.
at OIS.InputManager.createInputObject(InputManager* , Type , Boolean , basic_string<char\,std::char_traits<char>\,std::allocator<char> >* )
The code:
I tried to create keyboard instead, but same error. Does anyone have a clue what can be wrong?
Thx
I'm trying to get joystick work in MOgre application with MOIS. I created inputsystem and the joystick is listed with ListFreeDevices() command. But if i run the code with part where the joystick object is created, the application gives runtime error:
System.Runtime.InteropServices.SEHException: External component has thrown an exception.
at OIS.InputManager.createInputObject(InputManager* , Type , Boolean , basic_string<char\,std::char_traits<char>\,std::allocator<char> >* )
The code:
int windowHnd = 0;
mogreWin.window.GetCustomAttribute("WINDOW", out windowHnd);
inputManager = MOIS.InputManager.CreateInputSystem((uint)windowHnd);
joystick = (MOIS.JoyStick)inputManager.CreateInputObject(MOIS.Type.OISJoyStick, true);
I tried to create keyboard instead, but same error. Does anyone have a clue what can be wrong?
Thx