如何让 AR Core flutter 插件工作?

How can I make the AR Core flutter plugin work?

我正在尝试在我的 flutter 应用程序中使用 AR。我正在使用包 arcore_flutter_plugin。 添加插件后,我无法 运行 应用程序并且出现此错误(在禁用空安全功能后):

e: C:\Users\LENOVO THINKPAD\OneDrive\Bureau\Hackathon\ar_test\android\src\main\kotlin\com\difrancescogianmarco\arcore_flutter_plugin\ArCoreView.kt: (245, 38): Object is not abstract and does not implement abstract member public abstract fun onActivityCreated(p0: Activity, p1: Bundle?): Unit defined in android.app.Application.ActivityLifecycleCallbacks
e: C:\Users\LENOVO THINKPAD\OneDrive\Bureau\Hackathon\ar_test\android\src\main\kotlin\com\difrancescogianmarco\arcore_flutter_plugin\ArCoreView.kt: (246, 13): 'onActivityCreated' overrides nothing

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':arcore_flutter_plugin:compileDebugKotlin'.
> Compilation error. See log for more details

* Try:
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 1m 57s

有人可以帮我让它工作吗?

这是 arcore_flutter_plugin 中的一个错误。

导航到 ArCoreView.kt 文件:

C:\Users\LENOVO THINKPAD\OneDrive\Bureau\Hackathon\ar_test\android\src\main \kotlin\com\difrancescogianmarco\arcore_flutter_plugin\ArCoreView.kt

从以下行中删除“?”

override fun onActivityCreated(activity: Activity?, savedInstanceState: Bundle?)

New-line:

override fun onActivityCreated(activity: Activity, savedInstanceState: Bundle?)