summaryrefslogtreecommitdiff
path: root/scene
diff options
context:
space:
mode:
authorRĂ©mi Verschelde <rverschelde@gmail.com>2019-10-08 22:52:29 +0200
committerGitHub <noreply@github.com>2019-10-08 22:52:29 +0200
commit2d6b9f5034fba2c1c70ca82364727445dce2aaf6 (patch)
tree396b18f55deb9dcab51e737f9992466b93293db4 /scene
parent9a929a7e4d9aa32ea46f824096694534109ad459 (diff)
parentbb685147f9636112da4ee7e3a6e6dcbd739d8da4 (diff)
Merge pull request #32649 from qarmin/another_crash_fix_for_tile_map
Fix crash in TileMap::update_cell_bitmask
Diffstat (limited to 'scene')
-rw-r--r--scene/2d/tile_map.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/scene/2d/tile_map.cpp b/scene/2d/tile_map.cpp
index c9ba51bafb..173214dfe4 100644
--- a/scene/2d/tile_map.cpp
+++ b/scene/2d/tile_map.cpp
@@ -955,6 +955,7 @@ void TileMap::update_bitmask_region(const Vector2 &p_start, const Vector2 &p_end
void TileMap::update_cell_bitmask(int p_x, int p_y) {
+ ERR_FAIL_COND_MSG(tile_set.is_null(), "Cannot update cell bitmask if Tileset is not open.");
PosKey p(p_x, p_y);
Map<PosKey, Cell>::Element *E = tile_map.find(p);
if (E != NULL) {