restructuring + RRT load function done