![]() |
Collision Math Toy
Game Physics with Bespoke Code
|
Quadtree node. More...
#include <QuadTree.h>

Public Member Functions | |
| virtual | ~CQuadTreeNode () |
| Virtual destructor. | |
Friends | |
| class | CQuadTree |
A quadtree node, which represents a small rectangle of the game world. Each node represents a quadrant of the rectangle represented by its parent.
|
virtual |
A virtual destructor is necessary here because CQuadTree has a list of pointers to CQuadTreeNode, some of which point to the derived class CQuadTreeLeaf. If thie destructor is not declared virtual then the CQuadTreeLeaf destructor doesn't get run in the CQuadTree destructor.