Files
godot-docs-l10n/classes/fr/class_tileset.rst

1621 lines
112 KiB
ReStructuredText
Raw Permalink Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

:github_url: hide
.. _class_TileSet:
TileSet
=======
**Hérite de:** :ref:`Resource<class_Resource>` **<** :ref:`RefCounted<class_RefCounted>` **<** :ref:`Object<class_Object>`
La bibliothèque des tuiles pour les cartes.
.. rst-class:: classref-introduction-group
Description
-----------
A TileSet is a library of tiles for a :ref:`TileMapLayer<class_TileMapLayer>`. A TileSet handles a list of :ref:`TileSetSource<class_TileSetSource>`, each of them storing a set of tiles.
Tiles can either be from a :ref:`TileSetAtlasSource<class_TileSetAtlasSource>`, which renders tiles out of a texture with support for physics, navigation, etc., or from a :ref:`TileSetScenesCollectionSource<class_TileSetScenesCollectionSource>`, which exposes scene-based tiles.
Tiles are referenced by using three IDs: their source ID, their atlas coordinates ID, and their alternative tile ID.
A TileSet can be configured so that its tiles expose more or fewer properties. To do so, the TileSet resources use property layers, which you can add or remove depending on your needs.
For example, adding a physics layer allows giving collision shapes to your tiles. Each layer has dedicated properties (physics layer and mask), so you may add several TileSet physics layers for each type of collision you need.
See the functions to add new layers for more information.
.. rst-class:: classref-introduction-group
Tutoriels
------------------
- :doc:`Utiliser les tilemaps <../tutorials/2d/using_tilemaps>`
- `Démo de jeu de plateforme en 2D <https://godotengine.org/asset-library/asset/2727>`__
- `Démo 2D isométrique <https://godotengine.org/asset-library/asset/2718>`__
- `Démo Hexagonale en 2D <https://godotengine.org/asset-library/asset/2717>`__
- `Démo de navigation sur une grille 2D avec AStarGrid2D <https://godotengine.org/asset-library/asset/2723>`__
- `Démo de jeu de rôle 2D (RPG) <https://godotengine.org/asset-library/asset/2729>`__
- `Démo de personnage cinématique en 2D <https://godotengine.org/asset-library/asset/2719>`__
.. rst-class:: classref-reftable-group
Propriétés
--------------------
.. table::
:widths: auto
+----------------------------------------------------+------------------------------------------------------------------+----------------------+
| :ref:`TileLayout<enum_TileSet_TileLayout>` | :ref:`tile_layout<class_TileSet_property_tile_layout>` | ``0`` |
+----------------------------------------------------+------------------------------------------------------------------+----------------------+
| :ref:`TileOffsetAxis<enum_TileSet_TileOffsetAxis>` | :ref:`tile_offset_axis<class_TileSet_property_tile_offset_axis>` | ``0`` |
+----------------------------------------------------+------------------------------------------------------------------+----------------------+
| :ref:`TileShape<enum_TileSet_TileShape>` | :ref:`tile_shape<class_TileSet_property_tile_shape>` | ``0`` |
+----------------------------------------------------+------------------------------------------------------------------+----------------------+
| :ref:`Vector2i<class_Vector2i>` | :ref:`tile_size<class_TileSet_property_tile_size>` | ``Vector2i(16, 16)`` |
+----------------------------------------------------+------------------------------------------------------------------+----------------------+
| :ref:`bool<class_bool>` | :ref:`uv_clipping<class_TileSet_property_uv_clipping>` | ``false`` |
+----------------------------------------------------+------------------------------------------------------------------+----------------------+
.. rst-class:: classref-reftable-group
Méthodes
----------------
.. table::
:widths: auto
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`add_custom_data_layer<class_TileSet_method_add_custom_data_layer>`\ (\ to_position\: :ref:`int<class_int>` = -1\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`add_navigation_layer<class_TileSet_method_add_navigation_layer>`\ (\ to_position\: :ref:`int<class_int>` = -1\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`add_occlusion_layer<class_TileSet_method_add_occlusion_layer>`\ (\ to_position\: :ref:`int<class_int>` = -1\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`add_pattern<class_TileSet_method_add_pattern>`\ (\ pattern\: :ref:`TileMapPattern<class_TileMapPattern>`, index\: :ref:`int<class_int>` = -1\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`add_physics_layer<class_TileSet_method_add_physics_layer>`\ (\ to_position\: :ref:`int<class_int>` = -1\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`add_source<class_TileSet_method_add_source>`\ (\ source\: :ref:`TileSetSource<class_TileSetSource>`, atlas_source_id_override\: :ref:`int<class_int>` = -1\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`add_terrain<class_TileSet_method_add_terrain>`\ (\ terrain_set\: :ref:`int<class_int>`, to_position\: :ref:`int<class_int>` = -1\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`add_terrain_set<class_TileSet_method_add_terrain_set>`\ (\ to_position\: :ref:`int<class_int>` = -1\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`cleanup_invalid_tile_proxies<class_TileSet_method_cleanup_invalid_tile_proxies>`\ (\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`clear_tile_proxies<class_TileSet_method_clear_tile_proxies>`\ (\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Array<class_Array>` | :ref:`get_alternative_level_tile_proxy<class_TileSet_method_get_alternative_level_tile_proxy>`\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`, alternative_from\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Array<class_Array>` | :ref:`get_coords_level_tile_proxy<class_TileSet_method_get_coords_level_tile_proxy>`\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_custom_data_layer_by_name<class_TileSet_method_get_custom_data_layer_by_name>`\ (\ layer_name\: :ref:`String<class_String>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`get_custom_data_layer_name<class_TileSet_method_get_custom_data_layer_name>`\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Variant.Type<enum_@GlobalScope_Variant.Type>` | :ref:`get_custom_data_layer_type<class_TileSet_method_get_custom_data_layer_type>`\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_custom_data_layers_count<class_TileSet_method_get_custom_data_layers_count>`\ (\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`get_navigation_layer_layer_value<class_TileSet_method_get_navigation_layer_layer_value>`\ (\ layer_index\: :ref:`int<class_int>`, layer_number\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_navigation_layer_layers<class_TileSet_method_get_navigation_layer_layers>`\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_navigation_layers_count<class_TileSet_method_get_navigation_layers_count>`\ (\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_next_source_id<class_TileSet_method_get_next_source_id>`\ (\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_occlusion_layer_light_mask<class_TileSet_method_get_occlusion_layer_light_mask>`\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`get_occlusion_layer_sdf_collision<class_TileSet_method_get_occlusion_layer_sdf_collision>`\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_occlusion_layers_count<class_TileSet_method_get_occlusion_layers_count>`\ (\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`TileMapPattern<class_TileMapPattern>` | :ref:`get_pattern<class_TileSet_method_get_pattern>`\ (\ index\: :ref:`int<class_int>` = -1\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_patterns_count<class_TileSet_method_get_patterns_count>`\ (\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_physics_layer_collision_layer<class_TileSet_method_get_physics_layer_collision_layer>`\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_physics_layer_collision_mask<class_TileSet_method_get_physics_layer_collision_mask>`\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`float<class_float>` | :ref:`get_physics_layer_collision_priority<class_TileSet_method_get_physics_layer_collision_priority>`\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`PhysicsMaterial<class_PhysicsMaterial>` | :ref:`get_physics_layer_physics_material<class_TileSet_method_get_physics_layer_physics_material>`\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_physics_layers_count<class_TileSet_method_get_physics_layers_count>`\ (\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`TileSetSource<class_TileSetSource>` | :ref:`get_source<class_TileSet_method_get_source>`\ (\ source_id\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_source_count<class_TileSet_method_get_source_count>`\ (\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_source_id<class_TileSet_method_get_source_id>`\ (\ index\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_source_level_tile_proxy<class_TileSet_method_get_source_level_tile_proxy>`\ (\ source_from\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Color<class_Color>` | :ref:`get_terrain_color<class_TileSet_method_get_terrain_color>`\ (\ terrain_set\: :ref:`int<class_int>`, terrain_index\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`String<class_String>` | :ref:`get_terrain_name<class_TileSet_method_get_terrain_name>`\ (\ terrain_set\: :ref:`int<class_int>`, terrain_index\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`TerrainMode<enum_TileSet_TerrainMode>` | :ref:`get_terrain_set_mode<class_TileSet_method_get_terrain_set_mode>`\ (\ terrain_set\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_terrain_sets_count<class_TileSet_method_get_terrain_sets_count>`\ (\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`int<class_int>` | :ref:`get_terrains_count<class_TileSet_method_get_terrains_count>`\ (\ terrain_set\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`has_alternative_level_tile_proxy<class_TileSet_method_has_alternative_level_tile_proxy>`\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`, alternative_from\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`has_coords_level_tile_proxy<class_TileSet_method_has_coords_level_tile_proxy>`\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`has_custom_data_layer_by_name<class_TileSet_method_has_custom_data_layer_by_name>`\ (\ layer_name\: :ref:`String<class_String>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`has_source<class_TileSet_method_has_source>`\ (\ source_id\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`bool<class_bool>` | :ref:`has_source_level_tile_proxy<class_TileSet_method_has_source_level_tile_proxy>`\ (\ source_from\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| :ref:`Array<class_Array>` | :ref:`map_tile_proxy<class_TileSet_method_map_tile_proxy>`\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`, alternative_from\: :ref:`int<class_int>`\ ) |const| |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`move_custom_data_layer<class_TileSet_method_move_custom_data_layer>`\ (\ layer_index\: :ref:`int<class_int>`, to_position\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`move_navigation_layer<class_TileSet_method_move_navigation_layer>`\ (\ layer_index\: :ref:`int<class_int>`, to_position\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`move_occlusion_layer<class_TileSet_method_move_occlusion_layer>`\ (\ layer_index\: :ref:`int<class_int>`, to_position\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`move_physics_layer<class_TileSet_method_move_physics_layer>`\ (\ layer_index\: :ref:`int<class_int>`, to_position\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`move_terrain<class_TileSet_method_move_terrain>`\ (\ terrain_set\: :ref:`int<class_int>`, terrain_index\: :ref:`int<class_int>`, to_position\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`move_terrain_set<class_TileSet_method_move_terrain_set>`\ (\ terrain_set\: :ref:`int<class_int>`, to_position\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`remove_alternative_level_tile_proxy<class_TileSet_method_remove_alternative_level_tile_proxy>`\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`, alternative_from\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`remove_coords_level_tile_proxy<class_TileSet_method_remove_coords_level_tile_proxy>`\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`remove_custom_data_layer<class_TileSet_method_remove_custom_data_layer>`\ (\ layer_index\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`remove_navigation_layer<class_TileSet_method_remove_navigation_layer>`\ (\ layer_index\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`remove_occlusion_layer<class_TileSet_method_remove_occlusion_layer>`\ (\ layer_index\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`remove_pattern<class_TileSet_method_remove_pattern>`\ (\ index\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`remove_physics_layer<class_TileSet_method_remove_physics_layer>`\ (\ layer_index\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`remove_source<class_TileSet_method_remove_source>`\ (\ source_id\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`remove_source_level_tile_proxy<class_TileSet_method_remove_source_level_tile_proxy>`\ (\ source_from\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`remove_terrain<class_TileSet_method_remove_terrain>`\ (\ terrain_set\: :ref:`int<class_int>`, terrain_index\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`remove_terrain_set<class_TileSet_method_remove_terrain_set>`\ (\ terrain_set\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_alternative_level_tile_proxy<class_TileSet_method_set_alternative_level_tile_proxy>`\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`, alternative_from\: :ref:`int<class_int>`, source_to\: :ref:`int<class_int>`, coords_to\: :ref:`Vector2i<class_Vector2i>`, alternative_to\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_coords_level_tile_proxy<class_TileSet_method_set_coords_level_tile_proxy>`\ (\ p_source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`, source_to\: :ref:`int<class_int>`, coords_to\: :ref:`Vector2i<class_Vector2i>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_custom_data_layer_name<class_TileSet_method_set_custom_data_layer_name>`\ (\ layer_index\: :ref:`int<class_int>`, layer_name\: :ref:`String<class_String>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_custom_data_layer_type<class_TileSet_method_set_custom_data_layer_type>`\ (\ layer_index\: :ref:`int<class_int>`, layer_type\: :ref:`Variant.Type<enum_@GlobalScope_Variant.Type>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_navigation_layer_layer_value<class_TileSet_method_set_navigation_layer_layer_value>`\ (\ layer_index\: :ref:`int<class_int>`, layer_number\: :ref:`int<class_int>`, value\: :ref:`bool<class_bool>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_navigation_layer_layers<class_TileSet_method_set_navigation_layer_layers>`\ (\ layer_index\: :ref:`int<class_int>`, layers\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_occlusion_layer_light_mask<class_TileSet_method_set_occlusion_layer_light_mask>`\ (\ layer_index\: :ref:`int<class_int>`, light_mask\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_occlusion_layer_sdf_collision<class_TileSet_method_set_occlusion_layer_sdf_collision>`\ (\ layer_index\: :ref:`int<class_int>`, sdf_collision\: :ref:`bool<class_bool>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_physics_layer_collision_layer<class_TileSet_method_set_physics_layer_collision_layer>`\ (\ layer_index\: :ref:`int<class_int>`, layer\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_physics_layer_collision_mask<class_TileSet_method_set_physics_layer_collision_mask>`\ (\ layer_index\: :ref:`int<class_int>`, mask\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_physics_layer_collision_priority<class_TileSet_method_set_physics_layer_collision_priority>`\ (\ layer_index\: :ref:`int<class_int>`, priority\: :ref:`float<class_float>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_physics_layer_physics_material<class_TileSet_method_set_physics_layer_physics_material>`\ (\ layer_index\: :ref:`int<class_int>`, physics_material\: :ref:`PhysicsMaterial<class_PhysicsMaterial>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_source_id<class_TileSet_method_set_source_id>`\ (\ source_id\: :ref:`int<class_int>`, new_source_id\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_source_level_tile_proxy<class_TileSet_method_set_source_level_tile_proxy>`\ (\ source_from\: :ref:`int<class_int>`, source_to\: :ref:`int<class_int>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_terrain_color<class_TileSet_method_set_terrain_color>`\ (\ terrain_set\: :ref:`int<class_int>`, terrain_index\: :ref:`int<class_int>`, color\: :ref:`Color<class_Color>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_terrain_name<class_TileSet_method_set_terrain_name>`\ (\ terrain_set\: :ref:`int<class_int>`, terrain_index\: :ref:`int<class_int>`, name\: :ref:`String<class_String>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
| |void| | :ref:`set_terrain_set_mode<class_TileSet_method_set_terrain_set_mode>`\ (\ terrain_set\: :ref:`int<class_int>`, mode\: :ref:`TerrainMode<enum_TileSet_TerrainMode>`\ ) |
+-----------------------------------------------------+------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------+
.. rst-class:: classref-section-separator
----
.. rst-class:: classref-descriptions-group
Énumérations
------------------------
.. _enum_TileSet_TileShape:
.. rst-class:: classref-enumeration
enum **TileShape**: :ref:`🔗<enum_TileSet_TileShape>`
.. _class_TileSet_constant_TILE_SHAPE_SQUARE:
.. rst-class:: classref-enumeration-constant
:ref:`TileShape<enum_TileSet_TileShape>` **TILE_SHAPE_SQUARE** = ``0``
Forme de tuile rectangulaire.
.. _class_TileSet_constant_TILE_SHAPE_ISOMETRIC:
.. rst-class:: classref-enumeration-constant
:ref:`TileShape<enum_TileSet_TileShape>` **TILE_SHAPE_ISOMETRIC** = ``1``
Diamond tile shape (for isometric look).
\ **Note:** Isometric **TileSet** works best if all sibling :ref:`TileMapLayer<class_TileMapLayer>`\ s and their parent inheriting from :ref:`Node2D<class_Node2D>` have Y-sort enabled.
.. _class_TileSet_constant_TILE_SHAPE_HALF_OFFSET_SQUARE:
.. rst-class:: classref-enumeration-constant
:ref:`TileShape<enum_TileSet_TileShape>` **TILE_SHAPE_HALF_OFFSET_SQUARE** = ``2``
Rectangular tile shape with one row/column out of two offset by half a tile.
.. _class_TileSet_constant_TILE_SHAPE_HEXAGON:
.. rst-class:: classref-enumeration-constant
:ref:`TileShape<enum_TileSet_TileShape>` **TILE_SHAPE_HEXAGON** = ``3``
Forme de tuile hexagonale.
.. rst-class:: classref-item-separator
----
.. _enum_TileSet_TileLayout:
.. rst-class:: classref-enumeration
enum **TileLayout**: :ref:`🔗<enum_TileSet_TileLayout>`
.. _class_TileSet_constant_TILE_LAYOUT_STACKED:
.. rst-class:: classref-enumeration-constant
:ref:`TileLayout<enum_TileSet_TileLayout>` **TILE_LAYOUT_STACKED** = ``0``
Tile coordinates layout where both axis stay consistent with their respective local horizontal and vertical axis.
.. _class_TileSet_constant_TILE_LAYOUT_STACKED_OFFSET:
.. rst-class:: classref-enumeration-constant
:ref:`TileLayout<enum_TileSet_TileLayout>` **TILE_LAYOUT_STACKED_OFFSET** = ``1``
Same as :ref:`TILE_LAYOUT_STACKED<class_TileSet_constant_TILE_LAYOUT_STACKED>`, but the first half-offset is negative instead of positive.
.. _class_TileSet_constant_TILE_LAYOUT_STAIRS_RIGHT:
.. rst-class:: classref-enumeration-constant
:ref:`TileLayout<enum_TileSet_TileLayout>` **TILE_LAYOUT_STAIRS_RIGHT** = ``2``
Tile coordinates layout where the horizontal axis stay horizontal, and the vertical one goes down-right.
.. _class_TileSet_constant_TILE_LAYOUT_STAIRS_DOWN:
.. rst-class:: classref-enumeration-constant
:ref:`TileLayout<enum_TileSet_TileLayout>` **TILE_LAYOUT_STAIRS_DOWN** = ``3``
Tile coordinates layout where the vertical axis stay vertical, and the horizontal one goes down-right.
.. _class_TileSet_constant_TILE_LAYOUT_DIAMOND_RIGHT:
.. rst-class:: classref-enumeration-constant
:ref:`TileLayout<enum_TileSet_TileLayout>` **TILE_LAYOUT_DIAMOND_RIGHT** = ``4``
Tile coordinates layout where the horizontal axis goes up-right, and the vertical one goes down-right.
.. _class_TileSet_constant_TILE_LAYOUT_DIAMOND_DOWN:
.. rst-class:: classref-enumeration-constant
:ref:`TileLayout<enum_TileSet_TileLayout>` **TILE_LAYOUT_DIAMOND_DOWN** = ``5``
Tile coordinates layout where the horizontal axis goes down-right, and the vertical one goes down-left.
.. rst-class:: classref-item-separator
----
.. _enum_TileSet_TileOffsetAxis:
.. rst-class:: classref-enumeration
enum **TileOffsetAxis**: :ref:`🔗<enum_TileSet_TileOffsetAxis>`
.. _class_TileSet_constant_TILE_OFFSET_AXIS_HORIZONTAL:
.. rst-class:: classref-enumeration-constant
:ref:`TileOffsetAxis<enum_TileSet_TileOffsetAxis>` **TILE_OFFSET_AXIS_HORIZONTAL** = ``0``
Demi-décalage horizontal.
.. _class_TileSet_constant_TILE_OFFSET_AXIS_VERTICAL:
.. rst-class:: classref-enumeration-constant
:ref:`TileOffsetAxis<enum_TileSet_TileOffsetAxis>` **TILE_OFFSET_AXIS_VERTICAL** = ``1``
Demi décalage vertical.
.. rst-class:: classref-item-separator
----
.. _enum_TileSet_CellNeighbor:
.. rst-class:: classref-enumeration
enum **CellNeighbor**: :ref:`🔗<enum_TileSet_CellNeighbor>`
.. _class_TileSet_constant_CELL_NEIGHBOR_RIGHT_SIDE:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_RIGHT_SIDE** = ``0``
Voisin à droite.
.. _class_TileSet_constant_CELL_NEIGHBOR_RIGHT_CORNER:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_RIGHT_CORNER** = ``1``
Voisin dans le coin droit.
.. _class_TileSet_constant_CELL_NEIGHBOR_BOTTOM_RIGHT_SIDE:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_BOTTOM_RIGHT_SIDE** = ``2``
Voisin en bas à droite.
.. _class_TileSet_constant_CELL_NEIGHBOR_BOTTOM_RIGHT_CORNER:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_BOTTOM_RIGHT_CORNER** = ``3``
Voisin dans le coin en bas à droite.
.. _class_TileSet_constant_CELL_NEIGHBOR_BOTTOM_SIDE:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_BOTTOM_SIDE** = ``4``
Voisin en bas.
.. _class_TileSet_constant_CELL_NEIGHBOR_BOTTOM_CORNER:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_BOTTOM_CORNER** = ``5``
Voisin dans le coin en bas.
.. _class_TileSet_constant_CELL_NEIGHBOR_BOTTOM_LEFT_SIDE:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_BOTTOM_LEFT_SIDE** = ``6``
Voisin en bas à gauche.
.. _class_TileSet_constant_CELL_NEIGHBOR_BOTTOM_LEFT_CORNER:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_BOTTOM_LEFT_CORNER** = ``7``
Voisin dans le coin en bas à gauche.
.. _class_TileSet_constant_CELL_NEIGHBOR_LEFT_SIDE:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_LEFT_SIDE** = ``8``
Voisin à gauche.
.. _class_TileSet_constant_CELL_NEIGHBOR_LEFT_CORNER:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_LEFT_CORNER** = ``9``
Voisin dans le coin gauche.
.. _class_TileSet_constant_CELL_NEIGHBOR_TOP_LEFT_SIDE:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_TOP_LEFT_SIDE** = ``10``
Voisin en haut à gauche.
.. _class_TileSet_constant_CELL_NEIGHBOR_TOP_LEFT_CORNER:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_TOP_LEFT_CORNER** = ``11``
Voisin dans le coin en haut à gauche.
.. _class_TileSet_constant_CELL_NEIGHBOR_TOP_SIDE:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_TOP_SIDE** = ``12``
Voisin en haut.
.. _class_TileSet_constant_CELL_NEIGHBOR_TOP_CORNER:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_TOP_CORNER** = ``13``
Voisin dans le coin en haut.
.. _class_TileSet_constant_CELL_NEIGHBOR_TOP_RIGHT_SIDE:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_TOP_RIGHT_SIDE** = ``14``
Voisin en haut à droite.
.. _class_TileSet_constant_CELL_NEIGHBOR_TOP_RIGHT_CORNER:
.. rst-class:: classref-enumeration-constant
:ref:`CellNeighbor<enum_TileSet_CellNeighbor>` **CELL_NEIGHBOR_TOP_RIGHT_CORNER** = ``15``
Voisin dans le coin en haut à droite.
.. rst-class:: classref-item-separator
----
.. _enum_TileSet_TerrainMode:
.. rst-class:: classref-enumeration
enum **TerrainMode**: :ref:`🔗<enum_TileSet_TerrainMode>`
.. _class_TileSet_constant_TERRAIN_MODE_MATCH_CORNERS_AND_SIDES:
.. rst-class:: classref-enumeration-constant
:ref:`TerrainMode<enum_TileSet_TerrainMode>` **TERRAIN_MODE_MATCH_CORNERS_AND_SIDES** = ``0``
Requires both corners and side to match with neighboring tiles' terrains.
.. _class_TileSet_constant_TERRAIN_MODE_MATCH_CORNERS:
.. rst-class:: classref-enumeration-constant
:ref:`TerrainMode<enum_TileSet_TerrainMode>` **TERRAIN_MODE_MATCH_CORNERS** = ``1``
Requires corners to match with neighboring tiles' terrains.
.. _class_TileSet_constant_TERRAIN_MODE_MATCH_SIDES:
.. rst-class:: classref-enumeration-constant
:ref:`TerrainMode<enum_TileSet_TerrainMode>` **TERRAIN_MODE_MATCH_SIDES** = ``2``
Requires sides to match with neighboring tiles' terrains.
.. rst-class:: classref-section-separator
----
.. rst-class:: classref-descriptions-group
Descriptions des propriétés
------------------------------------------------------
.. _class_TileSet_property_tile_layout:
.. rst-class:: classref-property
:ref:`TileLayout<enum_TileSet_TileLayout>` **tile_layout** = ``0`` :ref:`🔗<class_TileSet_property_tile_layout>`
.. rst-class:: classref-property-setget
- |void| **set_tile_layout**\ (\ value\: :ref:`TileLayout<enum_TileSet_TileLayout>`\ )
- :ref:`TileLayout<enum_TileSet_TileLayout>` **get_tile_layout**\ (\ )
For all half-offset shapes (Isometric, Hexagonal and Half-Offset square), changes the way tiles are indexed in the :ref:`TileMapLayer<class_TileMapLayer>` grid.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_property_tile_offset_axis:
.. rst-class:: classref-property
:ref:`TileOffsetAxis<enum_TileSet_TileOffsetAxis>` **tile_offset_axis** = ``0`` :ref:`🔗<class_TileSet_property_tile_offset_axis>`
.. rst-class:: classref-property-setget
- |void| **set_tile_offset_axis**\ (\ value\: :ref:`TileOffsetAxis<enum_TileSet_TileOffsetAxis>`\ )
- :ref:`TileOffsetAxis<enum_TileSet_TileOffsetAxis>` **get_tile_offset_axis**\ (\ )
For all half-offset shapes (Isometric, Hexagonal and Half-Offset square), determines the offset axis.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_property_tile_shape:
.. rst-class:: classref-property
:ref:`TileShape<enum_TileSet_TileShape>` **tile_shape** = ``0`` :ref:`🔗<class_TileSet_property_tile_shape>`
.. rst-class:: classref-property-setget
- |void| **set_tile_shape**\ (\ value\: :ref:`TileShape<enum_TileSet_TileShape>`\ )
- :ref:`TileShape<enum_TileSet_TileShape>` **get_tile_shape**\ (\ )
La forme de la tuile.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_property_tile_size:
.. rst-class:: classref-property
:ref:`Vector2i<class_Vector2i>` **tile_size** = ``Vector2i(16, 16)`` :ref:`🔗<class_TileSet_property_tile_size>`
.. rst-class:: classref-property-setget
- |void| **set_tile_size**\ (\ value\: :ref:`Vector2i<class_Vector2i>`\ )
- :ref:`Vector2i<class_Vector2i>` **get_tile_size**\ (\ )
The tile size, in pixels. For all tile shapes, this size corresponds to the encompassing rectangle of the tile shape. This is thus the minimal cell size required in an atlas.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_property_uv_clipping:
.. rst-class:: classref-property
:ref:`bool<class_bool>` **uv_clipping** = ``false`` :ref:`🔗<class_TileSet_property_uv_clipping>`
.. rst-class:: classref-property-setget
- |void| **set_uv_clipping**\ (\ value\: :ref:`bool<class_bool>`\ )
- :ref:`bool<class_bool>` **is_uv_clipping**\ (\ )
Enables/Disable uv clipping when rendering the tiles.
.. rst-class:: classref-section-separator
----
.. rst-class:: classref-descriptions-group
Descriptions des méthodes
--------------------------------------------------
.. _class_TileSet_method_add_custom_data_layer:
.. rst-class:: classref-method
|void| **add_custom_data_layer**\ (\ to_position\: :ref:`int<class_int>` = -1\ ) :ref:`🔗<class_TileSet_method_add_custom_data_layer>`
Adds a custom data layer to the TileSet at the given position ``to_position`` in the array. If ``to_position`` is -1, adds it at the end of the array.
Custom data layers allow assigning custom properties to atlas tiles.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_add_navigation_layer:
.. rst-class:: classref-method
|void| **add_navigation_layer**\ (\ to_position\: :ref:`int<class_int>` = -1\ ) :ref:`🔗<class_TileSet_method_add_navigation_layer>`
Adds a navigation layer to the TileSet at the given position ``to_position`` in the array. If ``to_position`` is -1, adds it at the end of the array.
Navigation layers allow assigning a navigable area to atlas tiles.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_add_occlusion_layer:
.. rst-class:: classref-method
|void| **add_occlusion_layer**\ (\ to_position\: :ref:`int<class_int>` = -1\ ) :ref:`🔗<class_TileSet_method_add_occlusion_layer>`
Adds an occlusion layer to the TileSet at the given position ``to_position`` in the array. If ``to_position`` is -1, adds it at the end of the array.
Occlusion layers allow assigning occlusion polygons to atlas tiles.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_add_pattern:
.. rst-class:: classref-method
:ref:`int<class_int>` **add_pattern**\ (\ pattern\: :ref:`TileMapPattern<class_TileMapPattern>`, index\: :ref:`int<class_int>` = -1\ ) :ref:`🔗<class_TileSet_method_add_pattern>`
Adds a :ref:`TileMapPattern<class_TileMapPattern>` to be stored in the TileSet resource. If provided, insert it at the given ``index``.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_add_physics_layer:
.. rst-class:: classref-method
|void| **add_physics_layer**\ (\ to_position\: :ref:`int<class_int>` = -1\ ) :ref:`🔗<class_TileSet_method_add_physics_layer>`
Adds a physics layer to the TileSet at the given position ``to_position`` in the array. If ``to_position`` is -1, adds it at the end of the array.
Physics layers allow assigning collision polygons to atlas tiles.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_add_source:
.. rst-class:: classref-method
:ref:`int<class_int>` **add_source**\ (\ source\: :ref:`TileSetSource<class_TileSetSource>`, atlas_source_id_override\: :ref:`int<class_int>` = -1\ ) :ref:`🔗<class_TileSet_method_add_source>`
Adds a :ref:`TileSetSource<class_TileSetSource>` to the TileSet. If ``atlas_source_id_override`` is not -1, also set its source ID. Otherwise, a unique identifier is automatically generated.
The function returns the added source ID or -1 if the source could not be added.
\ **Warning:** A source cannot belong to two TileSets at the same time. If the added source was attached to another **TileSet**, it will be removed from that one.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_add_terrain:
.. rst-class:: classref-method
|void| **add_terrain**\ (\ terrain_set\: :ref:`int<class_int>`, to_position\: :ref:`int<class_int>` = -1\ ) :ref:`🔗<class_TileSet_method_add_terrain>`
Adds a new terrain to the given terrain set ``terrain_set`` at the given position ``to_position`` in the array. If ``to_position`` is -1, adds it at the end of the array.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_add_terrain_set:
.. rst-class:: classref-method
|void| **add_terrain_set**\ (\ to_position\: :ref:`int<class_int>` = -1\ ) :ref:`🔗<class_TileSet_method_add_terrain_set>`
Adds a new terrain set at the given position ``to_position`` in the array. If ``to_position`` is -1, adds it at the end of the array.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_cleanup_invalid_tile_proxies:
.. rst-class:: classref-method
|void| **cleanup_invalid_tile_proxies**\ (\ ) :ref:`🔗<class_TileSet_method_cleanup_invalid_tile_proxies>`
Clears tile proxies pointing to invalid tiles.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_clear_tile_proxies:
.. rst-class:: classref-method
|void| **clear_tile_proxies**\ (\ ) :ref:`🔗<class_TileSet_method_clear_tile_proxies>`
Efface toutes les substituts de tuiles.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_alternative_level_tile_proxy:
.. rst-class:: classref-method
:ref:`Array<class_Array>` **get_alternative_level_tile_proxy**\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`, alternative_from\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_get_alternative_level_tile_proxy>`
Returns the alternative-level proxy for the given identifiers. The returned array contains the three proxie's target identifiers (source ID, atlas coords ID and alternative tile ID).
If the TileSet has no proxy for the given identifiers, returns an empty Array.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_coords_level_tile_proxy:
.. rst-class:: classref-method
:ref:`Array<class_Array>` **get_coords_level_tile_proxy**\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`\ ) :ref:`🔗<class_TileSet_method_get_coords_level_tile_proxy>`
Returns the coordinate-level proxy for the given identifiers. The returned array contains the two target identifiers of the proxy (source ID and atlas coordinates ID).
If the TileSet has no proxy for the given identifiers, returns an empty Array.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_custom_data_layer_by_name:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_custom_data_layer_by_name**\ (\ layer_name\: :ref:`String<class_String>`\ ) |const| :ref:`🔗<class_TileSet_method_get_custom_data_layer_by_name>`
Returns the index of the custom data layer identified by the given name.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_custom_data_layer_name:
.. rst-class:: classref-method
:ref:`String<class_String>` **get_custom_data_layer_name**\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_custom_data_layer_name>`
Returns the name of the custom data layer identified by the given index.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_custom_data_layer_type:
.. rst-class:: classref-method
:ref:`Variant.Type<enum_@GlobalScope_Variant.Type>` **get_custom_data_layer_type**\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_custom_data_layer_type>`
Returns the type of the custom data layer identified by the given index.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_custom_data_layers_count:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_custom_data_layers_count**\ (\ ) |const| :ref:`🔗<class_TileSet_method_get_custom_data_layers_count>`
Returns the custom data layers count.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_navigation_layer_layer_value:
.. rst-class:: classref-method
:ref:`bool<class_bool>` **get_navigation_layer_layer_value**\ (\ layer_index\: :ref:`int<class_int>`, layer_number\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_navigation_layer_layer_value>`
Returns whether or not the specified navigation layer of the TileSet navigation data layer identified by the given ``layer_index`` is enabled, given a navigation_layers ``layer_number`` between 1 and 32.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_navigation_layer_layers:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_navigation_layer_layers**\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_navigation_layer_layers>`
Returns the navigation layers (as in the Navigation server) of the given TileSet navigation layer.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_navigation_layers_count:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_navigation_layers_count**\ (\ ) |const| :ref:`🔗<class_TileSet_method_get_navigation_layers_count>`
Returns the navigation layers count.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_next_source_id:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_next_source_id**\ (\ ) |const| :ref:`🔗<class_TileSet_method_get_next_source_id>`
Returns a new unused source ID. This generated ID is the same that a call to :ref:`add_source()<class_TileSet_method_add_source>` would return.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_occlusion_layer_light_mask:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_occlusion_layer_light_mask**\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_occlusion_layer_light_mask>`
Returns the light mask of the occlusion layer.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_occlusion_layer_sdf_collision:
.. rst-class:: classref-method
:ref:`bool<class_bool>` **get_occlusion_layer_sdf_collision**\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_occlusion_layer_sdf_collision>`
Returns if the occluders from this layer use ``sdf_collision``.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_occlusion_layers_count:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_occlusion_layers_count**\ (\ ) |const| :ref:`🔗<class_TileSet_method_get_occlusion_layers_count>`
Returns the occlusion layers count.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_pattern:
.. rst-class:: classref-method
:ref:`TileMapPattern<class_TileMapPattern>` **get_pattern**\ (\ index\: :ref:`int<class_int>` = -1\ ) :ref:`🔗<class_TileSet_method_get_pattern>`
Returns the :ref:`TileMapPattern<class_TileMapPattern>` at the given ``index``.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_patterns_count:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_patterns_count**\ (\ ) :ref:`🔗<class_TileSet_method_get_patterns_count>`
Returns the number of :ref:`TileMapPattern<class_TileMapPattern>` this tile set handles.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_physics_layer_collision_layer:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_physics_layer_collision_layer**\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_physics_layer_collision_layer>`
Returns the collision layer (as in the physics server) bodies on the given TileSet's physics layer are in.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_physics_layer_collision_mask:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_physics_layer_collision_mask**\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_physics_layer_collision_mask>`
Returns the collision mask of bodies on the given TileSet's physics layer.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_physics_layer_collision_priority:
.. rst-class:: classref-method
:ref:`float<class_float>` **get_physics_layer_collision_priority**\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_physics_layer_collision_priority>`
Returns the collision priority of bodies on the given TileSet's physics layer.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_physics_layer_physics_material:
.. rst-class:: classref-method
:ref:`PhysicsMaterial<class_PhysicsMaterial>` **get_physics_layer_physics_material**\ (\ layer_index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_physics_layer_physics_material>`
Returns the physics material of bodies on the given TileSet's physics layer.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_physics_layers_count:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_physics_layers_count**\ (\ ) |const| :ref:`🔗<class_TileSet_method_get_physics_layers_count>`
Returns the physics layers count.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_source:
.. rst-class:: classref-method
:ref:`TileSetSource<class_TileSetSource>` **get_source**\ (\ source_id\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_source>`
Returns the :ref:`TileSetSource<class_TileSetSource>` with ID ``source_id``.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_source_count:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_source_count**\ (\ ) |const| :ref:`🔗<class_TileSet_method_get_source_count>`
Returns the number of :ref:`TileSetSource<class_TileSetSource>` in this TileSet.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_source_id:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_source_id**\ (\ index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_source_id>`
Returns the source ID for source with index ``index``.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_source_level_tile_proxy:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_source_level_tile_proxy**\ (\ source_from\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_get_source_level_tile_proxy>`
Returns the source-level proxy for the given source identifier.
If the TileSet has no proxy for the given identifier, returns -1.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_terrain_color:
.. rst-class:: classref-method
:ref:`Color<class_Color>` **get_terrain_color**\ (\ terrain_set\: :ref:`int<class_int>`, terrain_index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_terrain_color>`
Renvoie la couleur d'un terrain.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_terrain_name:
.. rst-class:: classref-method
:ref:`String<class_String>` **get_terrain_name**\ (\ terrain_set\: :ref:`int<class_int>`, terrain_index\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_terrain_name>`
Renvoie le nom d'un terrain.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_terrain_set_mode:
.. rst-class:: classref-method
:ref:`TerrainMode<enum_TileSet_TerrainMode>` **get_terrain_set_mode**\ (\ terrain_set\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_terrain_set_mode>`
Returns a terrain set mode.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_terrain_sets_count:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_terrain_sets_count**\ (\ ) |const| :ref:`🔗<class_TileSet_method_get_terrain_sets_count>`
Returns the terrain sets count.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_get_terrains_count:
.. rst-class:: classref-method
:ref:`int<class_int>` **get_terrains_count**\ (\ terrain_set\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_get_terrains_count>`
Returns the number of terrains in the given terrain set.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_has_alternative_level_tile_proxy:
.. rst-class:: classref-method
:ref:`bool<class_bool>` **has_alternative_level_tile_proxy**\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`, alternative_from\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_has_alternative_level_tile_proxy>`
Returns if there is an alternative-level proxy for the given identifiers.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_has_coords_level_tile_proxy:
.. rst-class:: classref-method
:ref:`bool<class_bool>` **has_coords_level_tile_proxy**\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`\ ) :ref:`🔗<class_TileSet_method_has_coords_level_tile_proxy>`
Returns if there is a coodinates-level proxy for the given identifiers.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_has_custom_data_layer_by_name:
.. rst-class:: classref-method
:ref:`bool<class_bool>` **has_custom_data_layer_by_name**\ (\ layer_name\: :ref:`String<class_String>`\ ) |const| :ref:`🔗<class_TileSet_method_has_custom_data_layer_by_name>`
Returns if there is a custom data layer named ``layer_name``.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_has_source:
.. rst-class:: classref-method
:ref:`bool<class_bool>` **has_source**\ (\ source_id\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_has_source>`
Returns if this TileSet has a source for the given source ID.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_has_source_level_tile_proxy:
.. rst-class:: classref-method
:ref:`bool<class_bool>` **has_source_level_tile_proxy**\ (\ source_from\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_has_source_level_tile_proxy>`
Returns if there is a source-level proxy for the given source ID.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_map_tile_proxy:
.. rst-class:: classref-method
:ref:`Array<class_Array>` **map_tile_proxy**\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`, alternative_from\: :ref:`int<class_int>`\ ) |const| :ref:`🔗<class_TileSet_method_map_tile_proxy>`
According to the configured proxies, maps the provided identifiers to a new set of identifiers. The source ID, atlas coordinates ID and alternative tile ID are returned as a 3 elements Array.
This function first look for matching alternative-level proxies, then coordinates-level proxies, then source-level proxies.
If no proxy corresponding to provided identifiers are found, returns the same values the ones used as arguments.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_move_custom_data_layer:
.. rst-class:: classref-method
|void| **move_custom_data_layer**\ (\ layer_index\: :ref:`int<class_int>`, to_position\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_move_custom_data_layer>`
Moves the custom data layer at index ``layer_index`` to the given position ``to_position`` in the array. Also updates the atlas tiles accordingly.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_move_navigation_layer:
.. rst-class:: classref-method
|void| **move_navigation_layer**\ (\ layer_index\: :ref:`int<class_int>`, to_position\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_move_navigation_layer>`
Moves the navigation layer at index ``layer_index`` to the given position ``to_position`` in the array. Also updates the atlas tiles accordingly.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_move_occlusion_layer:
.. rst-class:: classref-method
|void| **move_occlusion_layer**\ (\ layer_index\: :ref:`int<class_int>`, to_position\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_move_occlusion_layer>`
Moves the occlusion layer at index ``layer_index`` to the given position ``to_position`` in the array. Also updates the atlas tiles accordingly.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_move_physics_layer:
.. rst-class:: classref-method
|void| **move_physics_layer**\ (\ layer_index\: :ref:`int<class_int>`, to_position\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_move_physics_layer>`
Moves the physics layer at index ``layer_index`` to the given position ``to_position`` in the array. Also updates the atlas tiles accordingly.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_move_terrain:
.. rst-class:: classref-method
|void| **move_terrain**\ (\ terrain_set\: :ref:`int<class_int>`, terrain_index\: :ref:`int<class_int>`, to_position\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_move_terrain>`
Moves the terrain at index ``terrain_index`` for terrain set ``terrain_set`` to the given position ``to_position`` in the array. Also updates the atlas tiles accordingly.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_move_terrain_set:
.. rst-class:: classref-method
|void| **move_terrain_set**\ (\ terrain_set\: :ref:`int<class_int>`, to_position\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_move_terrain_set>`
Moves the terrain set at index ``terrain_set`` to the given position ``to_position`` in the array. Also updates the atlas tiles accordingly.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_remove_alternative_level_tile_proxy:
.. rst-class:: classref-method
|void| **remove_alternative_level_tile_proxy**\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`, alternative_from\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_remove_alternative_level_tile_proxy>`
Removes an alternative-level proxy for the given identifiers.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_remove_coords_level_tile_proxy:
.. rst-class:: classref-method
|void| **remove_coords_level_tile_proxy**\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`\ ) :ref:`🔗<class_TileSet_method_remove_coords_level_tile_proxy>`
Removes a coordinates-level proxy for the given identifiers.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_remove_custom_data_layer:
.. rst-class:: classref-method
|void| **remove_custom_data_layer**\ (\ layer_index\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_remove_custom_data_layer>`
Removes the custom data layer at index ``layer_index``. Also updates the atlas tiles accordingly.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_remove_navigation_layer:
.. rst-class:: classref-method
|void| **remove_navigation_layer**\ (\ layer_index\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_remove_navigation_layer>`
Removes the navigation layer at index ``layer_index``. Also updates the atlas tiles accordingly.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_remove_occlusion_layer:
.. rst-class:: classref-method
|void| **remove_occlusion_layer**\ (\ layer_index\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_remove_occlusion_layer>`
Removes the occlusion layer at index ``layer_index``. Also updates the atlas tiles accordingly.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_remove_pattern:
.. rst-class:: classref-method
|void| **remove_pattern**\ (\ index\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_remove_pattern>`
Remove the :ref:`TileMapPattern<class_TileMapPattern>` at the given index.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_remove_physics_layer:
.. rst-class:: classref-method
|void| **remove_physics_layer**\ (\ layer_index\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_remove_physics_layer>`
Removes the physics layer at index ``layer_index``. Also updates the atlas tiles accordingly.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_remove_source:
.. rst-class:: classref-method
|void| **remove_source**\ (\ source_id\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_remove_source>`
Removes the source with the given source ID.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_remove_source_level_tile_proxy:
.. rst-class:: classref-method
|void| **remove_source_level_tile_proxy**\ (\ source_from\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_remove_source_level_tile_proxy>`
Removes a source-level tile proxy.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_remove_terrain:
.. rst-class:: classref-method
|void| **remove_terrain**\ (\ terrain_set\: :ref:`int<class_int>`, terrain_index\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_remove_terrain>`
Removes the terrain at index ``terrain_index`` in the given terrain set ``terrain_set``. Also updates the atlas tiles accordingly.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_remove_terrain_set:
.. rst-class:: classref-method
|void| **remove_terrain_set**\ (\ terrain_set\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_remove_terrain_set>`
Removes the terrain set at index ``terrain_set``. Also updates the atlas tiles accordingly.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_alternative_level_tile_proxy:
.. rst-class:: classref-method
|void| **set_alternative_level_tile_proxy**\ (\ source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`, alternative_from\: :ref:`int<class_int>`, source_to\: :ref:`int<class_int>`, coords_to\: :ref:`Vector2i<class_Vector2i>`, alternative_to\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_set_alternative_level_tile_proxy>`
Create an alternative-level proxy for the given identifiers. A proxy will map set of tile identifiers to another set of identifiers.
Proxied tiles can be automatically replaced in TileMapLayer nodes using the editor.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_coords_level_tile_proxy:
.. rst-class:: classref-method
|void| **set_coords_level_tile_proxy**\ (\ p_source_from\: :ref:`int<class_int>`, coords_from\: :ref:`Vector2i<class_Vector2i>`, source_to\: :ref:`int<class_int>`, coords_to\: :ref:`Vector2i<class_Vector2i>`\ ) :ref:`🔗<class_TileSet_method_set_coords_level_tile_proxy>`
Creates a coordinates-level proxy for the given identifiers. A proxy will map set of tile identifiers to another set of identifiers. The alternative tile ID is kept the same when using coordinates-level proxies.
Proxied tiles can be automatically replaced in TileMapLayer nodes using the editor.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_custom_data_layer_name:
.. rst-class:: classref-method
|void| **set_custom_data_layer_name**\ (\ layer_index\: :ref:`int<class_int>`, layer_name\: :ref:`String<class_String>`\ ) :ref:`🔗<class_TileSet_method_set_custom_data_layer_name>`
Sets the name of the custom data layer identified by the given index. Names are identifiers of the layer therefore if the name is already taken it will fail and raise an error.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_custom_data_layer_type:
.. rst-class:: classref-method
|void| **set_custom_data_layer_type**\ (\ layer_index\: :ref:`int<class_int>`, layer_type\: :ref:`Variant.Type<enum_@GlobalScope_Variant.Type>`\ ) :ref:`🔗<class_TileSet_method_set_custom_data_layer_type>`
Sets the type of the custom data layer identified by the given index.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_navigation_layer_layer_value:
.. rst-class:: classref-method
|void| **set_navigation_layer_layer_value**\ (\ layer_index\: :ref:`int<class_int>`, layer_number\: :ref:`int<class_int>`, value\: :ref:`bool<class_bool>`\ ) :ref:`🔗<class_TileSet_method_set_navigation_layer_layer_value>`
Based on ``value``, enables or disables the specified navigation layer of the TileSet navigation data layer identified by the given ``layer_index``, given a navigation_layers ``layer_number`` between 1 and 32.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_navigation_layer_layers:
.. rst-class:: classref-method
|void| **set_navigation_layer_layers**\ (\ layer_index\: :ref:`int<class_int>`, layers\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_set_navigation_layer_layers>`
Sets the navigation layers (as in the navigation server) for navigation regions in the given TileSet navigation layer.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_occlusion_layer_light_mask:
.. rst-class:: classref-method
|void| **set_occlusion_layer_light_mask**\ (\ layer_index\: :ref:`int<class_int>`, light_mask\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_set_occlusion_layer_light_mask>`
Sets the occlusion layer (as in the rendering server) for occluders in the given TileSet occlusion layer.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_occlusion_layer_sdf_collision:
.. rst-class:: classref-method
|void| **set_occlusion_layer_sdf_collision**\ (\ layer_index\: :ref:`int<class_int>`, sdf_collision\: :ref:`bool<class_bool>`\ ) :ref:`🔗<class_TileSet_method_set_occlusion_layer_sdf_collision>`
Enables or disables SDF collision for occluders in the given TileSet occlusion layer.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_physics_layer_collision_layer:
.. rst-class:: classref-method
|void| **set_physics_layer_collision_layer**\ (\ layer_index\: :ref:`int<class_int>`, layer\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_set_physics_layer_collision_layer>`
Sets the collision layer (as in the physics server) for bodies in the given TileSet physics layer.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_physics_layer_collision_mask:
.. rst-class:: classref-method
|void| **set_physics_layer_collision_mask**\ (\ layer_index\: :ref:`int<class_int>`, mask\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_set_physics_layer_collision_mask>`
Sets the collision mask for bodies in the given TileSet physics layer.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_physics_layer_collision_priority:
.. rst-class:: classref-method
|void| **set_physics_layer_collision_priority**\ (\ layer_index\: :ref:`int<class_int>`, priority\: :ref:`float<class_float>`\ ) :ref:`🔗<class_TileSet_method_set_physics_layer_collision_priority>`
Sets the collision priority for bodies in the given TileSet physics layer.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_physics_layer_physics_material:
.. rst-class:: classref-method
|void| **set_physics_layer_physics_material**\ (\ layer_index\: :ref:`int<class_int>`, physics_material\: :ref:`PhysicsMaterial<class_PhysicsMaterial>`\ ) :ref:`🔗<class_TileSet_method_set_physics_layer_physics_material>`
Sets the physics material for bodies in the given TileSet physics layer.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_source_id:
.. rst-class:: classref-method
|void| **set_source_id**\ (\ source_id\: :ref:`int<class_int>`, new_source_id\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_set_source_id>`
Change l'identifiant d'une source.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_source_level_tile_proxy:
.. rst-class:: classref-method
|void| **set_source_level_tile_proxy**\ (\ source_from\: :ref:`int<class_int>`, source_to\: :ref:`int<class_int>`\ ) :ref:`🔗<class_TileSet_method_set_source_level_tile_proxy>`
Creates a source-level proxy for the given source ID. A proxy will map set of tile identifiers to another set of identifiers. Both the atlas coordinates ID and the alternative tile ID are kept the same when using source-level proxies.
Proxied tiles can be automatically replaced in TileMapLayer nodes using the editor.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_terrain_color:
.. rst-class:: classref-method
|void| **set_terrain_color**\ (\ terrain_set\: :ref:`int<class_int>`, terrain_index\: :ref:`int<class_int>`, color\: :ref:`Color<class_Color>`\ ) :ref:`🔗<class_TileSet_method_set_terrain_color>`
Sets a terrain's color. This color is used for identifying the different terrains in the TileSet editor.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_terrain_name:
.. rst-class:: classref-method
|void| **set_terrain_name**\ (\ terrain_set\: :ref:`int<class_int>`, terrain_index\: :ref:`int<class_int>`, name\: :ref:`String<class_String>`\ ) :ref:`🔗<class_TileSet_method_set_terrain_name>`
Définit un nom de terrain.
.. rst-class:: classref-item-separator
----
.. _class_TileSet_method_set_terrain_set_mode:
.. rst-class:: classref-method
|void| **set_terrain_set_mode**\ (\ terrain_set\: :ref:`int<class_int>`, mode\: :ref:`TerrainMode<enum_TileSet_TerrainMode>`\ ) :ref:`🔗<class_TileSet_method_set_terrain_set_mode>`
Sets a terrain mode. Each mode determines which bits of a tile shape is used to match the neighboring tiles' terrains.
.. |virtual| replace:: :abbr:`virtual (Cette méthode doit typiquement être redéfinie par l'utilisateur pour avoir un effet.)`
.. |required| replace:: :abbr:`required (This method is required to be overridden when extending its base class.)`
.. |const| replace:: :abbr:`const (Cette méthode n'a pas d'effets de bord. Elle ne modifie aucune des variables membres de l'instance.)`
.. |vararg| replace:: :abbr:`vararg (Cette méthode accepte n'importe quel nombre d'arguments après ceux décris ici.)`
.. |constructor| replace:: :abbr:`constructor (Cette méthode est utilisée pour construire un type.)`
.. |static| replace:: :abbr:`static (Cette méthode n'a pas besoin d'instance pour être appelée, elle peut donc être directement appelée en utilisant le nom de la classe.)`
.. |operator| replace:: :abbr:`operator (Cette méthode décrit un opérateur valide à utiliser avec ce type en tant qu'opérande gauche.)`
.. |bitfield| replace:: :abbr:`BitField (Cette valeur est un nombre entier composé d'un masque de bits des options suivantes.)`
.. |void| replace:: :abbr:`void (Aucune valeur de retour.)`