amanuelg3 / padtie

Automatically exported from code.google.com/p/padtie
0 stars 0 forks source link

Uncaught exception: InputLostException when unplugging gamepad with Pad Tie running #7

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Currently Pad Tie does not have proper support for removing gamepads on the 
fly. 

Workaround: just restart Pad Tie.

Original issue reported on code.google.com by wila...@gmail.com on 13 Aug 2010 at 10:34

GoogleCodeExporter commented 9 years ago
Fixed in SVN for 0.1a4

The library has been updated with a "bool Removed" property which can be 
queried to tell when the device is removed. Once removed, you must use 
InputCore.Controllers.Remove() to remove the controller. A removed 
InputController will not send any data until the Removed flag is set to false, 
and before that happens you should relocate the device by it's instance GUID 
and reacquire it. We recommend you instead do like the Pad Tie application and 
throw the instance away, then just call ScanForControllers() and handle the new 
InputController instance.

In the Pad Tie application, it just works for you. The tab will disappear with 
no qualms.

Original comment by wila...@gmail.com on 14 Aug 2010 at 12:22

GoogleCodeExporter commented 9 years ago

Original comment by wila...@gmail.com on 14 Aug 2010 at 12:22