Everyplay pluging conflics with unity project

I’m getting the following exception and I don’t know how to debug it, that’s while building the game using Unity3D game engine.

When I import everyplay there is a resource folder in the Android Project, it seems it conflicts with my R$.class, so from my game there is an R.Class and also there is one that is generated from the resources folder of the Android project and I get a dex error, as following…

BuildPipeline.BuildPlayer failed, error=Error building Player:CommandInvokationFailure:Unable to convert classes into dex format.See the Consolefor details.
C:\Program Files\Java\jdk1.7.0_51\bin\java.exe -Xmx1024M-Dcom.android.sdkmanager.toolsdir=“C:/Program Files (x86)/android-sdk\tools”-Dfile.encoding=UTF8 -jar “C:/Program Files (x86)/Unity4.5/Editor/Data/BuildTargetTools/AndroidPlayer\sdktools.jar”-

stderr[

UNEXPECTED TOP-LEVEL EXCEPTION:
java.lang.IllegalArgumentException: already added:Lcom/asgatech/app/R$attr;
at com.android.dx.dex.file.ClassDefsSection.add(ClassDefsSection.java:122)
at com.android.dx.dex.file.ClassDefsSection.add(ClassDefsSection.java:122)
at com.android.dx.dex.file.DexFile.add(DexFile.java:161)
at com.android.dx.command.dexer.Main.processClass(Main.java:732)
at com.android.dx.command.dexer.Main.processFileBytes(Main.java:673)
at com.android.dx.command.dexer.Main.access$300(Main.java:83)
at com.android.dx.command.dexer.Main$1.processFileBytes(Main.java:602)
at com.android.dx.cf.direct.ClassPathOpener.processArchive(ClassPathOpener.java:284)
at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:166)
at com.android.dx.cf.direct.ClassPathOpener.processDirectory(ClassPathOpener.java:229)
at com.android.dx.cf.direct.ClassPathOpener.processOne(ClassPathOpener.java:158)
at com.android.dx.cf.direct.ClassPathOpener.process(ClassPathOpener.java:144)
at com.android.dx.command.dexer.Main.processOne(Main.java:632)
at com.android.dx.command.dexer.Main.processAllFiles(Main.java:510)
at com.android.dx.command.dexer.Main.runMonoDex(Main.java:280)
at com.android.dx.command.dexer.Main.run(Main.java:246)
at com.android.dx.command.dexer.Main.main(Main.java:215)
at com.android.dx.command.Main.main(Main.java:106)
at sun.reflect.NativeMethodAccessorImpl.invoke0(NativeMethod)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at SDKMain.main(SDKMain.java:129)1 error; aborting

The build process (specifically, the DEX tool) is complaining that the same class was added twice.
The class is this : Lcom/asgatech/app/R$attr;

Are you sure you are not adding this class twice somehow (e.g: including the same sources twice, for example)

@liortoal,
Thanks for your response. The problem that the Everyplay unity plugin, in the Android plugin, there is .jar and there are resource folders, and manifest. maybe it generates r$attr.class too, but how can I prevent that… If I remove the plugin directory, and just keep it’s jar, the everyplay can’t identify that there is support for android platform, but in that case the build works…
everyplay unity plugin, on android platform there are folders of res, manifest,…etc… how can I prevent them from not generating R$class too ?

here is the folder of the sdk

Every Android library usually places its code under a different package to avoid these collisions.
I would doubt that the generated R class from Everyplay gets mixed with other code.

What other Java stuff do you have in your project? Could you list the entire output of Assets/Plugins/Android ?

the entire plugins folder just have the everyplay plugin, now I figured out another problem, build fails not only with everyplay, but with any other plugins like Unity Ads.

resolution?

Are you also facing this issue @ev3d ?