Changed EntityQuadTree.clear() from a  recursive call to just setting all other values to null. Same functionality but actually works, as this seems to be getting rid of the multiple copies of same entity bug.