Răsfoiți Sursa

Tileset: Bind autotile_set_size()/get_size().

Since this class is editor-oriented, this set_get is necessary to full implement tool, importer, etc... for tiles. (No other way to know a real tile size in autotile mode)
Ranoller 7 ani în urmă
părinte
comite
0d33f4e9a2
1 a modificat fișierele cu 2 adăugiri și 0 ștergeri
  1. 2 0
      scene/resources/tile_set.cpp

+ 2 - 0
scene/resources/tile_set.cpp

@@ -940,6 +940,8 @@ void TileSet::_bind_methods() {
 	ClassDB::bind_method(D_METHOD("create_tile", "id"), &TileSet::create_tile);
 	ClassDB::bind_method(D_METHOD("autotile_set_bitmask_mode", "id", "mode"), &TileSet::autotile_set_bitmask_mode);
 	ClassDB::bind_method(D_METHOD("autotile_get_bitmask_mode", "id"), &TileSet::autotile_get_bitmask_mode);
+	ClassDB::bind_method(D_METHOD("autotile_set_size", "id", "size"), &TileSet::autotile_set_size);
+	ClassDB::bind_method(D_METHOD("autotile_get_size", "id"), &TileSet::autotile_get_size);
 	ClassDB::bind_method(D_METHOD("tile_set_name", "id", "name"), &TileSet::tile_set_name);
 	ClassDB::bind_method(D_METHOD("tile_get_name", "id"), &TileSet::tile_get_name);
 	ClassDB::bind_method(D_METHOD("tile_set_texture", "id", "texture"), &TileSet::tile_set_texture);