Use large offset for tilemap layer level canvas items

This matches the logic in _rendering_update_dirty_quadrants
This commit is contained in:
clayjohn 2022-12-15 11:41:27 -08:00
parent 1c5cfc4675
commit 7d6a25c91e

View file

@ -1092,7 +1092,7 @@ void TileMap::_rendering_update_layer(int p_layer) {
/*Transform2D xform;
xform.set_origin(Vector2(0, p_layer));
rs->canvas_item_set_transform(ci, xform);*/
rs->canvas_item_set_draw_index(ci, p_layer);
rs->canvas_item_set_draw_index(ci, p_layer - (int64_t)0x80000000);
layers[p_layer].canvas_item = ci;
}