suchipi-game-controller:Web Gamepad API的包装器

时间:2024-04-07 11:49:28
【文件属性】:

文件名称:suchipi-game-controller:Web Gamepad API的包装器

文件大小:107KB

文件格式:ZIP

更新时间:2024-04-07 11:49:28

JavaScript

@suchipi/game-controller Web 周围的包装程序,减少了在应用程序中支持Gamepads所需的样板数量。 用法 import GameController from "@suchipi/game-controller" ; const player1 = new GameController ( ) ; // Or, to get a different controller index: const player2 = new GameController ( { id : 1 /* (defaults to 0) */ } ) ; // To listen to buttons going from unpressed to pressed: player1 . addEventListener ( "buttondown" , ( name ) => {


【文件预览】:
suchipi-game-controller-main
----.gitignore(35B)
----README.md(2KB)
----test()
--------index.ts(596B)
--------index.html(333B)
----LICENSE(1KB)
----.eslintrc(203B)
----package.json(618B)
----src()
--------index.js(5KB)
--------index.d.ts(4KB)
----.npmignore(65B)
----babel.config.js(56B)
----yarn.lock(262KB)

网友评论