diff --git a/Sources/UBKit/Files/Xcode/SpecFile.swift b/Sources/UBKit/Files/Xcode/SpecFile.swift index fafd879..c8abbc0 100644 --- a/Sources/UBKit/Files/Xcode/SpecFile.swift +++ b/Sources/UBKit/Files/Xcode/SpecFile.swift @@ -61,7 +61,7 @@ extension File { OTHER_CFLAGS: $(inherited) -DINIT_SCRIPTING_BACKEND=1 -fno-strict-overflow -DRUNTIME_IL2CPP=1 CLANG_CXX_LANGUAGE_STANDARD: c++11 CLANG_CXX_LIBRARY: libc++ - SWIFT_OBJC_BRIDGING_HEADER: UnityBuildKit/UnityBridge/UnityBridge.h + SWIFT_OBJC_BRIDGING_HEADER: \(projectName)/UnityBridge/UnityBridge.h CLANG_ENABLE_MODULES: NO CLANG_WARN_BOOL_CONVERSION: NO CLANG_WARN_CONSTANT_CONVERSION: NO diff --git a/Sources/UBKit/Files/Xcode/ViewControllerFile.swift b/Sources/UBKit/Files/Xcode/ViewControllerFile.swift index 47d18c2..1d8353f 100644 --- a/Sources/UBKit/Files/Xcode/ViewControllerFile.swift +++ b/Sources/UBKit/Files/Xcode/ViewControllerFile.swift @@ -36,10 +36,9 @@ extension File { override func viewDidAppear(_ animated: Bool) { super.viewDidAppear(animated) - DispatchQueue.main.asyncAfter(deadline: DispatchTime.now()+2) { - let appDelegate = UIApplication.shared.delegate as! AppDelegate - appDelegate.startUnity() - + let appDelegate = UIApplication.shared.delegate as! AppDelegate + appDelegate.startUnity() + DispatchQueue.main.asyncAfter(deadline: DispatchTime.now()+5) { if let newUnityView = UnityGetGLView() { newUnityView.translatesAutoresizingMaskIntoConstraints = false self.view.addSubview(newUnityView)