This site requires JavaScript, please enable it in your browser!
Greenfoot back
lux
lux wrote ...

2012/3/21

Problems with export to .jar

lux lux

2012/3/21

#
Hello there I am aware of the fact that there has been multiple discussions concerning problems with exporting to .jar nevertheless I was not able to find a suitable solution for my problem since there seems to be different factors wich causes the export not to work. my problem is that after i run the project only the run and pause button appears. I also tried to share my project to this lovely community but the problem remains the same. is there any chance someone wants to help me with this problem? I honestly dont even know where to start.. Greetings lux
davmac davmac

2012/3/21

#
lux, if you upload a scenario we can take a look. The key is getting the "java console" to appear and you can then see exceptions which occur. Often the problem is because you are trying to perform file access, which isn't possible from an applet.
lux lux

2012/3/21

#
accessing files will most likely be the reason why it does not work.. unfortunately the animations of the game are depending on a certain structure of the images folder.. never thought it might become a problem i uploaded the scenario just dont get mad about the programming style ^^ Edit: guess the java console is telling me that there really is a problem with the images.. how do i fix this?
davmac davmac

2012/3/21

#
Well, it looks like you're using File.listFiles() - how about coding the existing files in an array instead: String fileNames = {"firstFile.png", "secondFile.png", ... }; (I haven't looked at your code, just the exception).
lux lux

2012/3/22

#
ok, finally the scenario works.. thanks for the help davmac!
You need to login to post a reply.