react-native-unity
react-native-unity copied to clipboard
Unity Jar issue with Unity Version 2023
System Configuration Mac Mini 2023 Apple M2 chip MacOS: 14.1.1 (23B81)
Unity Version I tried with 2 different unity version which is 2023.2.5f1 and 2023.2.20fa
Package.json @azesmway/react-native-unity: 1.0.7 react-native: 0.73.6
Unity Player Build Settings Minimum API Level :Android 8.0 'Oreo' (API level 26) Target API Level: API Level 34 Target Architecture: ARM64
Issue When I export the build and try run android app then getting error: 'UnityPlayer' is abstract; cannot be instantiated
I am having the same problem with unity 6000.0.0f1
Looking into this, it seems the UnityPlayer class has been made abstract and replaced with the class UnityPlayerForActivityOrService from Unity 2023.1 on.
See: https://docs.unity3d.com/2023.1/Documentation/Manual/UpgradeGuide20231.html
Absolutely! It's time to update the implementation within the library. https://github.com/azesmway/react-native-unity/blob/main/android/src/main/java/com/azesmwayreactnativeunity/ReactNativeUnity.java
For now I am using Unity 2022 version and it is working
Yes, I did the same. For me it is now also working with 2022.
Though I also just found a fork of this repo that has updated the code to work with 2023. https://github.com/byplay-io/react-native-unity
But to implement this in the main repo, there probably would need to be a more complex implementation that supports version pre 2023 as well as post 2023.
Added support for Unity 2023 and higher