rive-unity icon indicating copy to clipboard operation
rive-unity copied to clipboard

Rive overrides UnityAppController, breaking app functionality

Open Nezz opened this issue 6 months ago • 2 comments

We recently tried Rive and noticed that it was breaking iOS lifecycle events. This is because the plugin declares its own UnityAppController which takes precedence over ours: https://github.com/rive-app/rive-unity/blob/c589e52f539a1bbf3004b6c7ac56c523530c9f44/package/Runtime/Libraries/iOS/register_plugin.mm

Would it be possible to switch to a different initialization method that does not break other UnityAppControllers?

I also found that UnityRegisterRenderingPluginV5 was deprecated in Unity 6000.0.10.

Nezz avatar May 06 '25 09:05 Nezz

I asked the people at Unity and they said that registering the plugin can be done anytime - it does not need to happen from a native iOS call:

Our developers have advised that there are various ways to initialise plugins Plugins are registered before calling the registration function. The registration function can be called from anywhere if Unity is initialised and ready to accept the plugins. For example, you can initialise a plugin from a C# script by calling a P/Invoke function with the __Internal keyword, as long as it's not too late for the scenario in which it's required.

Nezz avatar May 09 '25 13:05 Nezz

Thanks for reporting this. We're looking into it! Will get back to you as soon as we have an update on this.

damzobridge avatar May 09 '25 17:05 damzobridge