Jelajahi Sumber

Bind method is_cell_transposed

Rémi Verschelde 9 tahun lalu
induk
melakukan
5439937899
2 mengubah file dengan 12 tambahan dan 0 penghapusan
  1. 11 0
      doc/base/classes.xml
  2. 1 0
      scene/2d/tile_map.cpp

+ 11 - 0
doc/base/classes.xml

@@ -36394,6 +36394,17 @@ This method controls whether the position between two cached points is interpola
 			Return whether the referenced cell is flipped over the Y axis.
 			Return whether the referenced cell is flipped over the Y axis.
 			</description>
 			</description>
 		</method>
 		</method>
+		<method name="is_cell_transposed" qualifiers="const">
+			<return type="bool">
+			</return>
+			<argument index="0" name="x" type="int">
+			</argument>
+			<argument index="1" name="y" type="int">
+			</argument>
+			<description>
+                        Return whether the referenced cell is transposed, i.e. the X and Y axes are swapped (mirroring with regard to the (1,1) vector).
+			</description>
+		</method>
 		<method name="clear">
 		<method name="clear">
 			<description>
 			<description>
 			Clear all cells.
 			Clear all cells.

+ 1 - 0
scene/2d/tile_map.cpp

@@ -1205,6 +1205,7 @@ void TileMap::_bind_methods() {
 	ObjectTypeDB::bind_method(_MD("get_cellv","pos"),&TileMap::get_cellv);
 	ObjectTypeDB::bind_method(_MD("get_cellv","pos"),&TileMap::get_cellv);
 	ObjectTypeDB::bind_method(_MD("is_cell_x_flipped","x","y"),&TileMap::is_cell_x_flipped);
 	ObjectTypeDB::bind_method(_MD("is_cell_x_flipped","x","y"),&TileMap::is_cell_x_flipped);
 	ObjectTypeDB::bind_method(_MD("is_cell_y_flipped","x","y"),&TileMap::is_cell_y_flipped);
 	ObjectTypeDB::bind_method(_MD("is_cell_y_flipped","x","y"),&TileMap::is_cell_y_flipped);
+	ObjectTypeDB::bind_method(_MD("is_cell_transposed","x","y"),&TileMap::is_cell_transposed);
 
 
 	ObjectTypeDB::bind_method(_MD("clear"),&TileMap::clear);
 	ObjectTypeDB::bind_method(_MD("clear"),&TileMap::clear);