1

i have an error on the logcat which reads

FATAL EXCEPTION: main

RunTime exception unable to instatiate activity componentInfo(android launcher) 
java.lang.classNotFoundException: Didn't find class " androidLauncher " on path : DexPathList[[zip file "/android-3.apk"],nativeLibraryDirectories=[android-3, /vendor/lib, /system/lib]]

i shortened it down as i couldnt copy and paste it but the basic error is there If you need any more details just ask but hopefully this should be enough

My game compiles but doesnt run and a message pops up on my android device "game has stopped"

Hopefully someone can help as i have been messing around with this for a few days and still no luck :(

thankyou

rekoDolph
  • 813
  • 1
  • 9
  • 31
  • What IDE are you using? – EpicPandaForce Sep 22 '14 at 14:31
  • Did you import the project into Eclipse ADT as a "Gradle project"? – EpicPandaForce Sep 22 '14 at 14:32
  • @Zhuinden yeah, theres a 'G' on all four of the folders to show this too :/ as far as i know i did that correctly – rekoDolph Sep 22 '14 at 14:33
  • So you *did* do it like this: http://stackoverflow.com/questions/24031573/opening-libgdx-project-in-eclipse-adt-bundle hmm... >.< well that makes it problematic because then that is correct, did you change ANYTHING in the gradle files, or about the initial class name or anything of that sort? – EpicPandaForce Sep 22 '14 at 14:34
  • 1
    @Zhuinden i tried refactoring the project to change the name so i could copy the project and make alot of changes to it, but it didnt work so i refactored it back to the original name, maybe that changed something ? but as far as i can remember thats all i changed :/ – rekoDolph Sep 22 '14 at 14:38
  • That's possible that it made some inconsistency with the build.gradle settings. I'd recommend creating a new project using the LibGDX project setup, and recreate your classes and copypaste your code from the old project to the new. – EpicPandaForce Sep 22 '14 at 14:46
  • Unfortunately I personally don't see a better alternative in the given situation, although there might be a better solution, I don't know what it is, sorry. – EpicPandaForce Sep 22 '14 at 14:51
  • @Zhuinden no worrys, appreciate the advice :) – rekoDolph Sep 22 '14 at 14:52

1 Answers1

0
java.lang.classNotFoundException: Didn't find class " androidLauncher " on path : DexPathList[[zip file "/android-3.apk"],nativeLibraryDirectories=[android-3, /vendor/lib, /system/lib]]

You seem to have changed the AndroidLauncher.java name. (notice the caps A).

  • You can make a file search (Ctrl + H), with "case sensitive" checked, and change any references to this non-existing "androidApplication" class.

  • Also cleaning your projects may pop these wrong references.

  • Also remaking your project with the Gdx Setup, and importing your code is a 100% error proof way of fixing your problem, but may take you more time.

Daahrien
  • 10,190
  • 6
  • 39
  • 71