1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
//! Welcome!  
//!   
//! The goal of this crate is to help you to make great 2d games running in web browsers.
//! This crate is inspired by SFML.
//! 
//! # How to use
//! 
//! Getting started with Wasm may be painful.
//! That's why I created a simple template you can use to quickly start wasm development.  
//!   
//! First, you need to install `wasm-pack` and `cargo-generate`.
//! 
//! ```sh
//! cargo install wasm-pack
//! cargo install cargo-generate
//! ```
//! 
//! Then, use cargo-generate to generate a new crate (modify the name at the end of the command):
//! 
//! ```sh
//! cargo generate --git https://github.com/Mubelotix/wasm-game-lib-template --name amazing-game
//! ```
//! 
//! Your game is now generated and is ready to be compiled with the command:
//! 
//! ```sh
//! wasm-pack build --target=web
//! ```
//! 
//! To test you game, you need a web server.
//! Open a terminal and go to your project directory.
//! Then, launch the webserver.
//! 
//! ```sh
//! cd pkg/
//! python3 -m http.server 8001
//! ```
//! 
//! Your game is now testable on [http://localhost:8001](http://localhost:8001)!  
//!  
//! In case this does not work, make sure you followed every instruction and [contact me](mailto:mubelotix@gmail.com).

#![warn(missing_docs)]

pub mod graphics;
pub mod inputs;
/// You will need this module for various things.
#[macro_use]
pub mod system;