gypsum 0.1.0

A Rust library for drawing ASCII-style roguelike graphics targetting both native (OpenGL) and wasm (WebGL) platforms
Documentation
1
2
3
4
5
6
7
8
9
10
11
use uni_app;

pub fn new(path: &str) -> uni_app::fs::File {
    let path = if cfg!(target_arch = "wasm32") {
        path.to_owned()
    } else {
        "static/".to_owned() + path
    };

    uni_app::fs::FileSystem::open(&path).unwrap()
}