bevy_entitiles 0.3.0

A 2d tilemap library for bevy. With many useful algorithms/tools built in.
1
2
3
4
5
6
7
8
#define_import_path bevy_entitiles::square

#import bevy_entitiles::common::{VertexInput, tilemap}

fn get_mesh_origin(input: VertexInput) -> vec2<f32> {
    let index = vec2<f32>(input.index.xy);
    return index.xy * tilemap.slot_size;
}