Moving uneeded shared_ptrs to unique_ptr

A lot of the objects that were using shared_ptrs actually had a sole owner and a well-defined lifetime, so I refactored them to be held in unique_ptrs.

This makes it easier to reason about the value's lifetime, as well as ensures that destruction is deterministic and has performance benefits.

The shared pointers being used in pathfinding are removed in #150
space after `if` and behind condition closing `)` missing