From 59e8c4c4e55ec641da5df02e82e0ca2eca438c52 Mon Sep 17 00:00:00 2001 From: alexiscatnip Date: Mon, 14 Feb 2022 00:38:41 +0800 Subject: [PATCH] add AOT.MonoPInvokeCallback at MediaObject So that Fmod can work. --- Assets/Raindrop/Core/Media/MediaObject.cs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Assets/Raindrop/Core/Media/MediaObject.cs b/Assets/Raindrop/Core/Media/MediaObject.cs index 887a855..c59a668 100644 --- a/Assets/Raindrop/Core/Media/MediaObject.cs +++ b/Assets/Raindrop/Core/Media/MediaObject.cs @@ -251,7 +251,9 @@ namespace Raindrop.Media /// /// /// - protected RESULT DispatchEndCallback( + /// We changed this to static, in hope that it will fix that nasty IL2cpp does not support marshalling runtime error + [AOT.MonoPInvokeCallback(typeof(CHANNELCONTROL_CALLBACK))] + protected static RESULT DispatchEndCallback( IntPtr channelraw, CHANNELCONTROL_TYPE controltype, CHANNELCONTROL_CALLBACK_TYPE type,