Added diving and surfacing logic for submarine class