From 267b92865e704e875b75f1e6d8d546d235f528c5 Mon Sep 17 00:00:00 2001 From: elioat Date: Fri, 21 Jul 2023 11:47:48 -0400 Subject: * --- js/gg/game.js | 20 ++++++++++++++++++++ js/gg/index.html | 38 ++++++++++++++++++++++++++++++++++++++ js/gg/styles.css | 21 +++++++++++++++++++++ 3 files changed, 79 insertions(+) create mode 100644 js/gg/game.js create mode 100644 js/gg/index.html create mode 100644 js/gg/styles.css (limited to 'js/gg') diff --git a/js/gg/game.js b/js/gg/game.js new file mode 100644 index 0000000..0ba3d89 --- /dev/null +++ b/js/gg/game.js @@ -0,0 +1,20 @@ +const buttons = { + d: { + up: () => document.getElementById("dUp"), + down: () => document.getElementById("dDown"), + right: () => document.getElementById("dRight"), + left: () => document.getElementById("dLeft"), + }, + ab: { + a: () => document.getElementById("a"), + b: () => document.getElementById("b"), + }, + aux: { + start: () => document.getElementById("start"), + select: () => document.getElementById("select"), + }, +}; + +console.log(buttons.ab.a); + +buttons.ab.a.style.backgroundColor = "pink"; diff --git a/js/gg/index.html b/js/gg/index.html new file mode 100644 index 0000000..04b2a52 --- /dev/null +++ b/js/gg/index.html @@ -0,0 +1,38 @@ + + + + + Hello, world! + + + + + + + + +
+
+ +
+ + +
+ +
+
+ + +
+
+
+ + +
+ + diff --git a/js/gg/styles.css b/js/gg/styles.css new file mode 100644 index 0000000..3059105 --- /dev/null +++ b/js/gg/styles.css @@ -0,0 +1,21 @@ +body { + font-family: sans-serif; +} + +canvas { + margin: 0 auto; + display: block; +} + +.flex-container { + display: flex; + flex-flow: row wrap; + justify-content: space-around; + padding: 1em; + margin: 0; +} + +.flex-item { + width: 33vw; + text-align: center; +} -- cgit 1.4.1-2-gfad0