AppLovin / AppLovin-MAX-Unity-Plugin

127 stars 35 forks source link

Cannot build Standalone/Addressables due to compilation error #385

Closed dkasenko closed 5 months ago

dkasenko commented 5 months ago

MAX Plugin Version

6.5.2

Unity Version

2023.2.17f1

Device/Platform Info

Standalone/Editor

Current Behavior

Compilation failed

Expected Behavior

Compilation success

How to Reproduce

Additional Info

// Assets/MaxSdk/Scripts/MaxSdk.cs
public class MaxSdk :
#if UNITY_EDITOR
    // Check for Unity Editor first since the editor also responds to the currently selected platform.
    MaxSdkUnityEditor
#elif UNITY_ANDROID
    MaxSdkAndroid
#elif UNITY_IPHONE || UNITY_IOS
    MaxSdkiOS
#else
    MaxSdkUnityEditor // <<<------- compilation error
#endif
santoshbagadi commented 5 months ago

@dkasenko Could you please share the exact compilation error? We were not able to reproduce the issue on our end

dkasenko commented 5 months ago
Addressables Errors ``` Assets\MaxSdk\Scripts\MaxSdkUnityEditor.cs(1438,26): error CS0117: 'MaxEventExecutor' does not contain a definition for 'Instance' Failed to compile player scripts UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&) Addressable content build failure (duration : 0:00:10,739) UnityEngine.DebugLogHandler:LogFormat (UnityEngine.LogType,UnityEngine.Object,string,object[]) UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&) ```
Build Errors ``` Assets\MaxSdk\Scripts\MaxSdkUnityEditor.cs(1438,26): error CS0117: 'MaxEventExecutor' does not contain a definition for 'Instance' Error building Player because scripts had compiler errors Build completed with a result of 'Failed' in 396 seconds (395582 ms) 2 errors UnityEngine.DebugLogHandler:LogFormat (UnityEngine.LogType,UnityEngine.Object,string,object[]) UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&) ```
santoshbagadi commented 5 months ago

@dkasenko do you mind sharing the contents of MaxEventExecutor file.

dkasenko commented 5 months ago

Thanks for the reply. I was mistake with version. Fixed in 6.4.4