nicer tree animations
code cleanup in tree