mirror of
https://github.com/Relintai/pandemonium_engine.git
synced 2024-12-22 20:06:49 +01:00
Ported: Fix TileMap error msg when optional navigation node is not set
Fixes TileMap error msg spam when bake_navigation=true but the optional and depr navigation node is not set.
- smix8
30d4555c65
This commit is contained in:
parent
6a30262311
commit
f1c29650eb
@ -159,7 +159,11 @@ void RTileMap::_update_quadrant_transform() {
|
||||
|
||||
Transform2D nav_rel;
|
||||
if (bake_navigation) {
|
||||
nav_rel = get_relative_transform_to_parent(navigation);
|
||||
if (navigation) {
|
||||
nav_rel = get_relative_transform_to_parent(navigation);
|
||||
} else {
|
||||
nav_rel = get_transform();
|
||||
}
|
||||
}
|
||||
|
||||
for (Map<PosKey, Quadrant>::Element *E = quadrant_map.front(); E; E = E->next()) {
|
||||
@ -355,7 +359,11 @@ void RTileMap::update_dirty_quadrants() {
|
||||
Vector2 tofs = get_cell_draw_offset();
|
||||
Transform2D nav_rel;
|
||||
if (navigation) {
|
||||
nav_rel = get_relative_transform_to_parent(navigation);
|
||||
if (navigation) {
|
||||
nav_rel = get_relative_transform_to_parent(navigation);
|
||||
} else {
|
||||
nav_rel = get_transform();
|
||||
}
|
||||
}
|
||||
|
||||
Vector2 qofs;
|
||||
|
Loading…
Reference in New Issue
Block a user