Closed daxini closed 5 years ago
@daxini
1: The reason why you got the error is that you didn't get the latest SDK. I've adapted the master branch to amg_2.1 to fix the problem.
2: You need to run Hello-Unity3D-Agora in two device ,you must ensure the appId and the channelName is the same and you will hear the voice.
Please try again, thanks !
I got the SDK from http://download.agora.io/sdk/release/AMG_Voice_Unity3D_HD_v2_1.zip and followed the instructions to replace the android, ios and scripts files, earlier and again so not sure why I didnt have the lastest SDK. But tried again and now I get the following error...
CommandInvokationFailure: Gradle build failed. /home/scd/Unity/Hub/Editor/2018.3.0f2/Editor/Data/PlaybackEngines/AndroidPlayer/Tools/OpenJDK/Linux/bin/java -classpath "/home/scd/Unity/Hub/Editor/2018.3.0f2/Editor/Data/PlaybackEngines/AndroidPlayer/Tools/gradle/lib/gradle-launcher-4.6.jar" org.gradle.launcher.GradleMain "-Dorg.gradle.jvmargs=-Xmx4096m" "assembleRelease"
stderr[
FAILURE: Build failed with an exception.
Where: Build file '/home/scd/Source/unity/Voice-Call-for-Mobile-Gaming-master/Advanced-Voice-Call-for-Gaming/Spacewar-with-AMG-Voice-SDK-Unity/Temp/gradleOut/build.gradle' line: 17
What went wrong: A problem occurred evaluating root project 'gradleOut'.
Failed to apply plugin [id 'com.android.application'] Gradle version 2.10 is required. Current version is 4.6. If using the gradle wrapper, try editing the distributionUrl in /home/scd/Source/unity/Voice-Call-for-Mobile-Gaming-master/Advanced-Voice-Call-for-Gaming/Spacewar-with-AMG-Voice-SDK-Unity/Temp/gradleOut/gradle/wrapper/gradle-wrapper.properties to gradle-2.10-all.zip
Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights.
Get more help at https://help.gradle.org
BUILD FAILED in 0s ] stdout[
]
exit code: 1
UnityEditor.Android.Command.WaitForProgramToRun (UnityEditor.Utils.Program p, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
UnityEditor.Android.Command.Run (System.String command, System.String args, System.String workingdir, UnityEditor.Android.WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg)
UnityEditor.Android.AndroidJavaTools.RunJava (System.String args, System.String workingdir, System.Action1 progress, System.String error) UnityEditor.Android.GradleWrapper.Run (UnityEditor.Android.AndroidJavaTools javaTools, System.String workingdir, System.String task, System.Action
1 progress)
Rethrow as GradleInvokationException: Gradle build failed
UnityEditor.Android.GradleWrapper.Run (UnityEditor.Android.AndroidJavaTools javaTools, System.String workingdir, System.String task, System.Action`1 progress)
UnityEditor.Android.PostProcessor.Tasks.BuildGradleProject.Execute (UnityEditor.Android.PostProcessor.PostProcessorContext context)
UnityEditor.Android.PostProcessor.PostProcessRunner.RunAllTasks (UnityEditor.Android.PostProcessor.PostProcessorContext context)
UnityEditor.BuildPlayerWindow:BuildPlayerAndRun()
I get this error both for "Voice-Call-for-Mobile-Gaming/Advanced-Voice-Call-for-Gaming/Spacewar-with-AMG-Voice-SDK-Unity/" as well as "Video-Call-for-Mobile-Gaming/Hello-Video-Unity-Agora/"
I get the following error when I follow the instructions for Unity3D (2018.3.0f2) version of "Advanced-Voice-Call-for-Gaming"
Assets/GameScene/Scripts/GameController.cs(254,15): error CS1501: No overload for method
SetClientRole' takes
1' argumentsIt works for Hello-Unity3D-Agora but I only get a msg of joining or leaving a channel but no actual voice is tx/rx. Please help get voice communication working in the sample app.