AI and map fixes