diff --git a/Cargo.lock b/Cargo.lock index 126b32c..a214a75 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1313,7 +1313,6 @@ dependencies = [ "parking_lot 0.12.1", "stdweb", "thiserror", - "wasm-bindgen", "web-sys", "windows", ] @@ -3760,7 +3759,7 @@ dependencies = [ "js-sys", "log", "naga", - "parking_lot 0.11.2", + "parking_lot 0.12.1", "raw-window-handle 0.4.3", "smallvec", "wasm-bindgen", @@ -3785,7 +3784,7 @@ dependencies = [ "fxhash", "log", "naga", - "parking_lot 0.11.2", + "parking_lot 0.12.1", "profiling", "raw-window-handle 0.4.3", "smallvec", @@ -3821,7 +3820,7 @@ dependencies = [ "metal", "naga", "objc", - "parking_lot 0.11.2", + "parking_lot 0.12.1", "profiling", "range-alloc", "raw-window-handle 0.4.3", diff --git a/Cargo.toml b/Cargo.toml index fd3c589..1158949 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -24,7 +24,7 @@ serde_json = "1.0.85" ticktock = "0.8.0" [target."cfg(target_arch = \"wasm32\")".dependencies] -cpal = { version = "0.14.0", features = ["wasm-bindgen"] } +#cpal = { version = "0.14.0", features = ["wasm-bindgen"] } [profile.dev.package."*"] opt-level = 3 diff --git a/README.md b/README.md index d46aca3..3aaeb14 100644 --- a/README.md +++ b/README.md @@ -1,11 +1,15 @@ # Lux synthesĕ +[Play in browser](https://txmn.tk/projects/lux-synthese/) + ## Controls * **Move**: arrows * **Switch character**: Tab * **Level up**: Enter (when character is white) * **Reset**: R +* **Fullscreen**: F11 +* **Exit**: Escape ## TODO diff --git a/assets/UacariLegacy-Bold.ttf b/assets/UacariLegacy-Bold.ttf new file mode 100644 index 0000000..7309e66 Binary files /dev/null and b/assets/UacariLegacy-Bold.ttf differ diff --git a/assets/UacariLegacy-Regular.ttf b/assets/UacariLegacy-Regular.ttf new file mode 100644 index 0000000..7eb6474 Binary files /dev/null and b/assets/UacariLegacy-Regular.ttf differ diff --git a/assets/game.levels.json b/assets/game.levels.json index bd87468..632dd99 100644 --- a/assets/game.levels.json +++ b/assets/game.levels.json @@ -59,10 +59,10 @@ { "pos": [ 0.0, - 0.0 + 64.0 ], "font_size": 32.0, - "text": "Combine the colors to synthetize a white light.\nUse arrows to move." + "text": "Combine the colors\nto synthetize a white light.\nUse arrows to move." } ] }, @@ -374,11 +374,11 @@ "texts": [ { "pos": [ - 0.0, + -304.0, -64.0 ], "font_size": 32.0, - "text": "Too much light\ncause some platforms to melt." + "text": "Too much light\ncauses some platforms to melt." } ] }, diff --git a/build-itchio.sh b/build-itchio.sh index 62759b7..2657220 100644 --- a/build-itchio.sh +++ b/build-itchio.sh @@ -7,6 +7,7 @@ cp assets/* target/itchio/wasm/assets/ cp index.html target/itchio/wasm/ cp target/lux-synthese.js target/itchio/wasm/target/ cp target/lux-synthese_bg.wasm target/itchio/wasm/target/ +jq -c < assets/game.levels.json > target/itchio/wasm/assets/game.levels.json cd target/itchio/wasm zip -r ../wasm.zip . diff --git a/index.html b/index.html index f36746d..159b08a 100644 --- a/index.html +++ b/index.html @@ -3,13 +3,61 @@
Note: audio does not work in the WASM build. @@ -27,9 +75,9 @@ init()
GNU AGPL v3: CopyLeft 2022 Pascal Engélibert, Nixon Cheng
- Lux synthesĕ is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, version 3 of the License.
- Lux synthesĕ is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.
- You should have received a copy of the GNU Affero General Public License along with Lux synthesĕ. If not, see https://www.gnu.org/licenses/.
+ Lux synthesĕ is free software: you can redistribute it and/or modify it under the terms of the GNU Affero General Public License as published by the Free Software Foundation, version 3 of the License.
+ Lux synthesĕ is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Affero General Public License for more details.
+ You should have received a copy of the GNU Affero General Public License along with Lux synthesĕ. If not, see https://www.gnu.org/licenses/.