diff --git a/godot/.import/default.png-13971fa1f37d4ea367b7aa5973d2bb0a.md5 b/godot/.import/default.png-13971fa1f37d4ea367b7aa5973d2bb0a.md5 index 9b2d15f..2741d11 100644 --- a/godot/.import/default.png-13971fa1f37d4ea367b7aa5973d2bb0a.md5 +++ b/godot/.import/default.png-13971fa1f37d4ea367b7aa5973d2bb0a.md5 @@ -1,3 +1,3 @@ -source_md5="72b25c45d4743c578ac08e56b209be81" -dest_md5="73042650bec74eec84c50b98d4bafc70" +source_md5="d864960022980c4270042a1ed80b9ac4" +dest_md5="5f766eea69301dc969f05fac899cb4cb" diff --git a/godot/.import/default.png-13971fa1f37d4ea367b7aa5973d2bb0a.stex b/godot/.import/default.png-13971fa1f37d4ea367b7aa5973d2bb0a.stex index 3eca1ec..f5db78d 100644 Binary files a/godot/.import/default.png-13971fa1f37d4ea367b7aa5973d2bb0a.stex and b/godot/.import/default.png-13971fa1f37d4ea367b7aa5973d2bb0a.stex differ diff --git a/godot/native/libroutes_native.so b/godot/native/libroutes_native.so index 1c0105a..7a4cdea 100755 Binary files a/godot/native/libroutes_native.so and b/godot/native/libroutes_native.so differ diff --git a/godot/sprite/tiles/terrain/default.png b/godot/sprite/tiles/terrain/default.png index 0c3cfb6..20ea306 100644 Binary files a/godot/sprite/tiles/terrain/default.png and b/godot/sprite/tiles/terrain/default.png differ diff --git a/godot/world/Tilemap.gd b/godot/world/Tilemap.gd index 5d078f2..9bd981a 100644 --- a/godot/world/Tilemap.gd +++ b/godot/world/Tilemap.gd @@ -1,4 +1,8 @@ extends TileMap func set_tile_graphics(pos: Vector2, id: int): - set_cell(pos.x,pos.y,0,false,false,false,Vector2(1,2)) + var flip = true + set_cell(pos.x,pos.y,0,false,false,false,get_atlas_vec_for_id(id)) + +func get_atlas_vec_for_id(id: int) -> Vector2: + return Vector2(randi() % 4, id) diff --git a/godot/world/Tilemap.tscn b/godot/world/Tilemap.tscn index f8b161c..d835d56 100644 --- a/godot/world/Tilemap.tscn +++ b/godot/world/Tilemap.tscn @@ -9,7 +9,6 @@ position = Vector2( -2, 0 ) mode = 1 tile_set = ExtResource( 1 ) cell_size = Vector2( 32, 16 ) -cell_tile_origin = 1 collision_layer = 0 collision_mask = 0 format = 1 diff --git a/godot/world/Tilemaps.gd b/godot/world/Tilemaps.gd index 82e217a..dec0d77 100644 --- a/godot/world/Tilemaps.gd +++ b/godot/world/Tilemaps.gd @@ -11,6 +11,3 @@ func respawn_tilemaps(amount: int): map.z_index = i add_child(map) tilemaps.push_back(map) - -func is_tile_in_view(pos: Vector2): - pass diff --git a/libresprite/tiles/default.ase b/libresprite/tiles/default.ase index 3834f0a..1266ca9 100644 Binary files a/libresprite/tiles/default.ase and b/libresprite/tiles/default.ase differ diff --git a/routes-native/src/stateserver/world.rs b/routes-native/src/stateserver/world.rs index 1b689e2..953a164 100644 --- a/routes-native/src/stateserver/world.rs +++ b/routes-native/src/stateserver/world.rs @@ -21,7 +21,7 @@ impl World { for y in 0..self.ysize { for z in 0..self.zsize { ret.push(Vector3::new(x as f32, y as f32, z as f32)); - self.tiles[x][y][z] = tiles::Tiletypes::Dirt; + self.tiles[x][y][z] = tiles::Tiletypes::Grass; } } }