Improved tree search. Still horrible tho