moved examples
This commit is contained in:
parent
11dd73c45a
commit
52dfaea7ed
Before Width: | Height: | Size: 27 KiB After Width: | Height: | Size: 27 KiB |
Binary file not shown.
After Width: | Height: | Size: 27 KiB |
|
@ -0,0 +1,16 @@
|
||||||
|
use gsa::{run, Gsa};
|
||||||
|
|
||||||
|
struct Game {}
|
||||||
|
|
||||||
|
fn init(gsa: &mut Gsa) -> Game {
|
||||||
|
//game initialisation code
|
||||||
|
gsa.sprites[0].tile = 0;
|
||||||
|
Game {}
|
||||||
|
}
|
||||||
|
|
||||||
|
fn update(game: &mut Game, gsa: &mut Gsa) {
|
||||||
|
gsa.sprites[0].pos += gsa.input_dir();
|
||||||
|
//once per frame code
|
||||||
|
}
|
||||||
|
|
||||||
|
run!(init, update);
|
Loading…
Reference in New Issue