     static let bullets  = CollisionCategory(rawValue: 1 << 0)
     static let ship = CollisionCategory(rawValue: 1 << 1)
 }
+
+extension utsname {
+    func hasAtLeastA9() -> Bool { // checks if device has at least A9 chip for configuration
+        var systemInfo = self
+        uname(&systemInfo)
+        let str = withUnsafePointer(to: &systemInfo.machine.0) { ptr in
+            return String(cString: ptr)
+        }
+        switch str {
+        case "iPhone8,1", "iPhone8,2", "iPhone8,4", "iPhone9,1", "iPhone9,2", "iPhone9,3", "iPhone9,4": // iphone with at least A9 processor
+            return true
+        case "iPad6,7", "iPad6,8", "iPad6,3", "iPad6,4", "iPad6,11", "iPad6,12": // ipad with at least A9 processor
+            return true
+        default:
+            return false
+        }
+    }
+}

    override func viewWillAppear(_ animated: Bool) {
        super.viewWillAppear(animated)
        
        // Create a session configuration
        let configuration = ARWorldTrackingSessionConfiguration()
        configuration.planeDetection = ARWorldTrackingSessionConfiguration.PlaneDetection.horizontal
        print(configuration.planeDetection)
        
        // Run the view's session
        sceneView.session.run(configuration)
    }
    
    override func viewWillDisappear(_ animated: Bool) {

        
        // ARKit owns the node corresponding to the anchor, so make the plane a child node.
        node.addChildNode(planeNode)
    } */
    
    // MARK: - Actions
    
