Fix crash in TileMap::update_cell_bitmask
This commit is contained in:
parent
02d75f99b9
commit
bb685147f9
1 changed files with 1 additions and 0 deletions
|
@ -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) {
|
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);
|
PosKey p(p_x, p_y);
|
||||||
Map<PosKey, Cell>::Element *E = tile_map.find(p);
|
Map<PosKey, Cell>::Element *E = tile_map.find(p);
|
||||||
if (E != NULL) {
|
if (E != NULL) {
|
||||||
|
|
Loading…
Reference in a new issue