forked from sascha/godot
Fix not refitting upward from leaf nodes.
Previously, the wrong node id (root node id) was used. Dirty leaf nodes do not actually recalculate aabb. Additionally, when requesting a new leaf, mark `dirty` as `false` in `clear()`. Make sure to only mark the leaf as **dirty** when shrinking the border of the leaf when removing items. In other cases, the leaf node's aabb will get the correct result immediately. 1. When adding an item, the leaf nodes will be calculated immediately. 2. Removing the item within the border of the leaf node has no effect on the original aabb.4.2
parent
4c3dc26367
commit
e705aa4550
Loading…
Reference in New Issue