Pluggable native SDK
Starting from v2.6.0, you can dynamically switch the code logic that runs on the iOS/Android native platforms. By default, Objective-C/Java logic runs; after you switch, C# code logic runs.
For iOS/Android apps that are already live, after users update to a version that "runs C# code logic", persisted data is lost, including the device ID, account ID, distinct ID, and super properties, and these users are identified as new users. Choose carefully.
1. Pluggable workflow
1.1 iOS platform
By default, Objective-C code logic runs; after you switch, C# code logic runs.
- Download the Unity SDK and unzip it to get the
ta_unity_sdk.unitypackagefile. Double-click the file to import the SDK, clear thePlugins/iOSdirectory in the import window, and then import
Note: If you have already imported the Unity SDK, check the files in the Plugins/iOS directory. If it contains no files or directories other than "ThinkingSDK", "TAThirdParty", and "ThinkingAnalytics.m", delete Plugins/iOS directly. Otherwise, delete only the files and directories listed above.
- Open the
Project Settingswindow, switch to theiOStab, findScripting Define Symbols, add a line withTE_DISABLE_IOS_OC, and then clickApplyto complete the setting. After development is complete, export the Xcode project as usual
1.2 Android platform
By default, Java code logic runs; after you switch, C# code logic runs.
- Download the Unity SDK and unzip it to get the
ta_unity_sdk.unitypackagefile. Double-click the file to import the SDK, clear thePlugins/Androiddirectory in the import window, and then import
Note: If you have already imported the Unity SDK, check the files in the Plugins/Android directory. If it contains no files or directories other than "ThinkingSDK.aar", "ThinkingSDK-gameengine.aar", and "ThinkingSDK-thirdparty.aar", delete Plugins/Android directly. Otherwise, delete only the files listed above.
- Open the
Project Settingswindow, switch to theAndroidtab, findScripting Define Symbols, add a line withTE_DISABLE_ANDROID_JAVA, and then clickApplyto complete the setting. After development is complete, export the Android project as usual

