amplitude / unity-plugin

Official Amplitude Unity Plugin
https://developers.amplitude.com/docs/unity
MIT License
44 stars 34 forks source link

feat: update iOS plugin version #102

Closed dnshi closed 2 years ago

dnshi commented 2 years ago

Summary

bgiori commented 2 years ago

Ah, I am not sure this is going to work (with regards to analytics connector)...

The analytics connector works by having the customer pull in both dependencies, which in turn share a dependency. The assumption is that the build system is smart enough to resolve the shared dependency. However, if we are re-defining the analytics connector here, then the code will be duplicated, and the shared dependency is no longer shared.

Is this just a direct copy of the iOS SDK? Sorry I am a bit clueless about unity.

dnshi commented 2 years ago

@bgiori It is a direct copy of the iOS SDK and the analytics connector, but I add/update 3 .h files for Swift:

The analytics connector is a dependency but I copy the files into this project. Adding .h to import Swift into Objc. The main effort in this PR is the above three .h files, and the build is succeeded on the Xcode.

image

Please let me know if I miss anything. Thanks!

bgiori commented 2 years ago

Would we be able to test that both SDKs communicate with each other in a unity iOS app?

dnshi commented 2 years ago

Unity iOS part is same as iOS SDK. Currently, Unity SDK is a wrapper for iOS SDK and Android SDK. The Unity methods written in C# are calling iOS SDK or Android SDK. We will build C# SDK next and then replace the existing Unity SDK.