gamepadzilla
Version:
A plug-and-play gamepad frontend framework for HTML5 mobile games, supporting both virtual and physical joysticks. No scripting required.
18 lines (16 loc) • 654 B
text/typescript
import { construtors } from "./construtors";
import { InstallEngine } from "./engine";
import { InstallEventFeedback } from "./event_feedback";
import { installEventGamepad } from "./event_gamepad"
import { InstallEventMouse } from "./event_mouse";
import { InstallEventTouch } from "./event_touch";
import { InstallEventHtml } from "./event_html";
document.addEventListener('DOMContentLoaded', () => {
const pads = construtors()
InstallEngine(window, pads)
InstallEventHtml(window, pads)
InstallEventTouch(window, pads)
InstallEventMouse(window, pads)
installEventGamepad(window, pads)
InstallEventFeedback(window, pads)
})