From what I understand the pilot advises on the docking procedures and navigation through the harbor, but the ships crew remains in command of the vessel. Generally rhese ships do have data recorders similar to planes though, so that would likely be used as evidence in whatever investigation may occur.