Anyone Tried Gree for Android? I've followed the PDF instructions but when i go to build my game I get this error: Code (csharp): System.IO.IOException: Failed to Move File / Directory from 'Assets/Editor/GREE/Android/c2dm/bin/classes.jar' to 'Assets/Plugins/Android/greeplatformforunity_c2dm.jar'. at (wrapper managed-to-native) UnityEditor.FileUtil:MoveFileOrDirectory (string,string) at GreeAndroidC2DMReceiverBuilder.Build () [0x0023f] in C:\Users\derkoi\Desktop\Unity Projects\Tests\Gree Test\Assets\Editor\GREE\GreeAndroidC2DMReceiverBuilder.cs:166 UnityEngine.Debug:LogError(Object) GreeAndroidC2DMReceiverBuilder:Build() (at Assets/Editor/GREE/GreeAndroidC2DMReceiverBuilder.cs:168) AndroidBuilder:Build(Boolean, Boolean, String) (at Assets/Editor/GREE/AndroidBuilder.cs:35) ApplicationSettingsMenu:OnGUI() (at Assets/Editor/GREE/ApplicationSettingsMenu.cs:356) UnityEditor.DockArea:OnGUI() Any ideas?
Ah so it's not just me? I emailed Gree support and they asked me to provide them with a log after double checking my paths to Ant Java.
Same issue here. The weird thing is that classes.jar is not even built, so there's nothing to move by Unity3d. Would be great if you will post Gree's support feedback.
Just so you know I've send logs and stuff to Gree, they're still trying to sort it. I'll let you know any feedback I get.
I had this, if you browse further up your logs it usually reveals the answer. Mine was a couple of things... The PATH was defaulting to an older version of JRE (c:\windows\system32) instead of the required JDK (c:\program files\java\jdk 7......) as system32 was the first location where java was 'found'. Secondly, Apache ANT (the required 'ant.bat' file) was out of date. If you get the latest version of eclipse it'll be the appropriate version, or update it yourself. Hope that helps.
Thanks for that Akira. Could you please post your absolute paths to java ant, plus the versions you are using?
You can get the latest version of Apache Ant with Eclipse Indigo. (I had been using an older version of eclipse) Otherwise you can get it here http://ant.apache.org/ I pointed the "Ant Path" to "YOUR ECLIPSE FOLDER\plugins/org.apache.ant_1.8.2.v20120109-1030/bin/ant.bat." Any version around 1.8.x will work I believe. The version of JDK you should have is the latest. I haven't tried older ones as the PDF states that 7 is required. http://www.oracle.com/technetwork/java/javase/downloads/jdk-7u4-downloads-1591156.html You will then have to add ";C:\Program Files\Java\jdk1.7.0_04\bin" to your path. In Windows 7: Start Menu -> Type "environment" in the search box. Open "Edit environment variables for your account" Append the existing PATH variable, or create a new one.
What does your log say when you try to build MSC? You should get the error at the top of this thread, which unhelpfully actually just means you've failed to build. (It can't copy the file because it was never created.) Locate that error, then click on each log entry above that, one of those will hold the clues. Most likely related to java or ant.
I can confirm it working with Unity Indie. Run the build from the GREE menu. Cancel the part where you select the APK location (or let it fail). You only have to do this once, as its to build the GREE jar files and create the AndroidManifest.XML, after this you can just keep building from Unity as normal. (I then had to manually merge a few things (Mobclix and AdMob settings) into the new generated AndroidManifest, but this was a once off.
Hi, i have the same problem. I tried the solution based on your post but still I can't build my application. I'm not sure if I selected the correct path for "Java Path". I selected " C:\Program Files\Java\jdk1.7.0_04\bin\ java.exe". Which path should I select for "Java Path"? Thanks!
When the GREE plugin tries to build the C2DM jar, it goes looking for Java, however as far as I'm aware, it doesn't actually use the path you specify in the GREE window's "Java Path" field. According to the .pdf, "Java Path" is used for the "absolute path for Java command used for execution encrypting tool," but it doesn't elaborate. You can actually leave this field empty and still build the plugin without errors. When your system goes looking for Java, its going to use the first one it finds. In all likelihood, you've got multiple copies installed, likely at "C:/Windows/System32/Java.exe" / "Windows/SysWOW64/Java.exe" and perhaps multiple JDK/JRE's. To solve the error, you need to make sure the first instance of Java it finds is the version you need, in this case JDK7. I can't remember the exact order it goes searching for Java in, but adding ";C:\Program Files\Java\jdk1.7.0_04\bin" to your PATH environment variable should point it the right way. Like so:
We have solved the problem by commenting out the below codes from "GreeAndroidC2DMReceiverBuilder" Class Code (csharp): // move /* try { FileUtil.MoveFileOrDirectory(prjDir + "/bin/classes.jar", jarFile); FileUtil.DeleteFileOrDirectory(jarFile); } catch (IOException e) { UnityEngine.Debug.LogError(e); EditorUtility.ClearProgressBar(); EditorUtility.DisplayDialog("Build C2DMReceiver", "Build Failed - Moving JAR archive file.", "ok"); return false; }*/ Then we've found the "classes.jar" file from "C:\Program Files (x86)\Unity\Editor\Data\PlaybackEngines\androiddevelopmentplayer\bin" and copied it manually to "C:\Users\pc\Desktop\GreeTest\Assets\Editor\GREE\Android" and renamed it to "greeplatformforunity_c2dm" this is exactly what the above code tries to do. That's it, now we can build our application and GREE just works without a single problem.
I am Getting Error for GREE integration in Unity 3d .When I am trying to build the project it is showing following errors 1- Moving File failed. Assets/editor/gree/android/c2dm/bin/classes.jar to assets/plugin/android/greeplatformforunity_c2dm.jar When I manually move the file classes .jar to this location .Then It ask for path and when building apk. It shows following error 2. Building DEX Failed! Failed to compile java code to DEX. See the console for details. I search for all the forums and unity community for this they all provide me only solution to move file update java . I have latest and compatable version of java already installed on my windows. Kindly Help.
When launching dasboard, the app is force closing after few seconds.This issues is not in google nexus devices. But reported its HTC Desire,HTC evo devices ..I have refer "https://docs.developer.gree.net/en/globaltechnicalspecs/sdkforunity/sdk-for-unity-developerguide20120831-en.pdf".
I'm also trying to build a project with GREE, but I get this following error when I build: BUILD FAILED (path to project)\build.xml:46:sdk.dir is missing. Make sure to generate local.properties using 'android update project' or to inject it through an env var and there pops out another error afterwards Build Activity Failed to build activity classes with ant Does anyone have a solution for this problem? Thank you!