Created binary search tree to hold events and updated existing files to use new data structure