diff options
author | Juan Linietsky <reduzio@gmail.com> | 2017-01-14 16:52:16 -0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2017-01-14 16:52:16 -0300 |
commit | 94609305a021305db2a02c63890f9e23c37d0dd8 (patch) | |
tree | 43bca91ad666008664b416e2211e3b6d0896c333 /scene/resources/tile_set.h | |
parent | 52666b88b39a91655553ba6ab5bbe47c09861e28 (diff) | |
parent | 86789c7071836b802e6edb0538ce6de2b7949c7b (diff) |
Merge pull request #6519 from RandomShaper/enhance-tileset
Add modulate (color) to TileSet tiles
Diffstat (limited to 'scene/resources/tile_set.h')
-rw-r--r-- | scene/resources/tile_set.h | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/scene/resources/tile_set.h b/scene/resources/tile_set.h index ce40e5ebe3..b80889fc6f 100644 --- a/scene/resources/tile_set.h +++ b/scene/resources/tile_set.h @@ -52,6 +52,10 @@ class TileSet : public Resource { Vector2 navigation_polygon_offset; Ref<NavigationPolygon> navigation_polygon; Ref<CanvasItemMaterial> material; + Color modulate; + + // Default modulate for back-compat + explicit Data() : modulate(1,1,1) {} }; Map<int,Data> tile_map; @@ -94,6 +98,9 @@ public: void tile_set_material(int p_id,const Ref<CanvasItemMaterial> &p_material); Ref<CanvasItemMaterial> tile_get_material(int p_id) const; + void tile_set_modulate(int p_id,const Color &p_color); + Color tile_get_modulate(int p_id) const; + void tile_set_occluder_offset(int p_id,const Vector2& p_offset); Vector2 tile_get_occluder_offset(int p_id) const; |