Rudimentary tree construction mostly working
Tree construction fully implemented