         locationManager.desiredAccuracy = kCLLocationAccuracyBest
         
         // 現在位置からどれぐらい動いたら更新するか. 単位はm
-        locationManager.distanceFilter = 10
+        locationManager.distanceFilter = 1
         locationManager.delegate = self
         locationManager.startUpdatingLocation()
         

                                              zoom: cameraZoomLevel)
        self.mapView.camera = camera
        
        guard
            let goal = checkpoints.first else {
                checkpoints = mapCheckpoint.getRandomDummyCheckpoint()
                return
            }
        
        
        if oldLocation == nil {
            oldLocation = location
            mapRouteManager.getRoutes(location, goal)
        }
        let locationDistance = location.distance(from: oldLocation)
        //notification()
        if mapRouteManager.isCheckpointArrive(location, goal){
            notification()
            // 遷移
            self.fromMaptoEventCotroller()
            
        }else{

            mapRouteManager.updateRoute(myLocation: location)
            scoreManager.setScore(locationDistance)
            oldLocation = location
        }
    }
    
    func notification() {
        

    
    let locationManager = CLLocationManager()
    let scoreManager = ScoreManager()
    let mapCheckpoint = MapCheckpoint()
    
    // エレメントの数
    let elmentNum = 10
    
    // エレメントを選択した時に必要な変数群
    var selectElementWindow: UIWindow!
    var selectElementButton = UIButton()
    let initWaitTime = 5.0 + 1.0;
    var waitTime = 0.0;
    var waitTimeLabel = UILabel()
    
    
    var checkpoints:[CLLocation] = []
    
    @IBOutlet var mapView: GMSMapView!
    
    var selectElementPos = CLLocation()
    var isGetCheckpoint = false

    let cameraZoomLevel:Float = 17
    
