README.md (3182B)
1 # A Bevy game template 2 3 Template for a Game using the awesome [Bevy engine][bevy] featuring out of the box builds for Windows, Linux, macOS, and Web (Wasm). 4 5 _Since Bevy is in heavy development, there regularly are unpublished new features or bug fixes. If you like living on the edge, you can use the branch `bevy_main` of this template to be close to the current state of Bevy's main branch_ 6 7 # What does this template give you? 8 * basic setup with a slim main function and your game as a Bevy plugin in a library 9 * small example game (*warning: biased; e.g., split into a lot of plugins and using `bevy_kira_audio` for sound*) 10 * easy setup for running the web (`cargo run --target wasm32-unknown-unknown`) and the native version (`cargo run`) 11 * workflow for GitHub actions creating releases for Windows, Linux, macOS, and Web (Wasm) ready for distribution 12 * push a tag in the form of `v[0-9]+.[0-9]+.[0-9]+*` (e.g. `v1.1.42`) to trigger the flow 13 14 # How to use this template? 15 1. Click "Use this template" on the repository's page 16 2. Look for `ToDo` to use your own game name everywhere 17 3. [Update the icons as described below](#updating-the-icons) 18 4. Start coding :tada: 19 * Start the native app: `cargo run` 20 * Start the web build: `cargo run --target wasm32-unknown-unknown` 21 * requires [`wasm-server-runner`]: `cargo install wasm-server-runner` 22 * requires `wasm32-unknown-unknown` target: `rustup target add wasm32-unknown-unknown` 23 * this will serve your app on a free port 24 25 You should keep the `credits` directory up to date. The release workflow automatically includes the directory in every build. 26 27 ### Updating the icons 28 1. Replace `build/windows/icon.ico` (used for windows executable and as favicon for the web-builds) 29 2. Replace `build/macos/icon_1024x1024.png` with a `1024` times `1024` pixel png icon and run `create_icns.sh` (make sure to run the script inside the `macos` directory) - _Warning: sadly this seems to require a mac..._ 30 31 # Getting started with Bevy 32 33 You should check out the Bevy website for [links to resources][bevy-learn] and the [Bevy Cheat Book] for a bunch of helpful documentation and examples. I can also recommend the [official Bevy Discord server][bevy-discord] to keep up to date with the development and get feedback + help from other Bevy users. 34 35 # Known issues 36 37 Audio in web-builds can have issues in some browsers. This seems to be a general performance issue and not due ot the audio itself (see [bevy_kira_audio/#9][firefox-sound-issue]). 38 39 # License 40 41 This project is licensed under [CC0 1.0 Universal](LICENSE) except some content of `assets` and the Bevy icons in the `build` directory (see [Credits](credits/CREDITS.md)). Go crazy and feel free to show me whatever you build with this ([@nikl_me][nikl-twitter]). 42 43 [bevy]: https://bevyengine.org/ 44 [bevy-learn]: https://bevyengine.org/learn/ 45 [bevy-discord]: https://discord.gg/bevy 46 [nikl-twitter]: https://twitter.com/nikl_me 47 [firefox-sound-issue]: https://github.com/NiklasEi/bevy_kira_audio/issues/9 48 [Bevy Cheat Book]: https://bevy-cheatbook.github.io/introduction.html 49 [`wasm-server-runner`]: https://github.com/jakobhellermann/wasm-server-runner