node xinput ffi:通过ffi napi的XInput包装器 源码
通过XInput包装器 快速范例 const XInput = require ( "xinput-ffi" ) ; //CommonJS //OR import * as XInput from "xinput-ffi" ; //ES Module //Check connected status for all controller console . log ( XInput . sync . listConnected ( ) ) // [true,false,false,false] Only 1st gamepad is connected XInput . sync . rumble ( ) ; //Rumble 1st XInput gamepad XInput . sync . rumble ( { force : 100 } ) ; //Now with 100% fo
用户评论