diff --git a/package.json b/package.json
index 7aaa5dc..b6a642b 100644
--- a/package.json
+++ b/package.json
@@ -12,6 +12,7 @@
"vite": "^5.3.1"
},
"dependencies": {
+ "nipplejs": "^0.10.2",
"sanitize.css": "^13.0.0"
}
}
diff --git a/pnpm-lock.yaml b/pnpm-lock.yaml
index daeb4bc..28d7297 100644
--- a/pnpm-lock.yaml
+++ b/pnpm-lock.yaml
@@ -8,6 +8,9 @@ importers:
.:
dependencies:
+ nipplejs:
+ specifier: ^0.10.2
+ version: 0.10.2
sanitize.css:
specifier: ^13.0.0
version: 13.0.0
@@ -254,6 +257,9 @@ packages:
engines: {node: ^10 || ^12 || ^13.7 || ^14 || >=15.0.1}
hasBin: true
+ nipplejs@0.10.2:
+ resolution: {integrity: sha512-XGxFY8C2DOtobf1fK+MXINTzkkXJLjZDDpfQhOUZf4TSytbc9s4bmA0lB9eKKM8iDivdr9NQkO7DpIQfsST+9g==}
+
picocolors@1.0.1:
resolution: {integrity: sha512-anP1Z8qwhkbmu7MFP5iTt+wQKXgwzf7zTyGlcdzabySa9vd0Xt392U0rVmz9poOaBj0uHJKyyo9/upk0HrEQew==}
@@ -453,6 +459,8 @@ snapshots:
nanoid@3.3.7: {}
+ nipplejs@0.10.2: {}
+
picocolors@1.0.1: {}
postcss@8.4.39:
diff --git a/src/index.html b/src/index.html
index f0c3c7e..01d073e 100644
--- a/src/index.html
+++ b/src/index.html
@@ -7,7 +7,68 @@
Virtual Gamepad
-
+
+
+
+
+
+
+
+
+ Virtual Gamepad
+
+
+ References
+
+ Joystick: send POST to /joystick?p=aaff
(aa
:
+ 00~FF angle, ff
: 00~FF force) at intervals.
+
+ Buttons: send POST to /a
, /b
.
+
+ More details:
+ TwoSquirrels/virtual-gamepad - GitHub
+
+
+