Jetzt sollten auch Jars plattformunabhängig laufen.

This commit is contained in:
Jan Philipp Timme 2014-11-02 01:39:12 +01:00
parent a4fa1edce9
commit f22d16941d
1 changed files with 5 additions and 1 deletions

View File

@ -22,7 +22,11 @@ public class Loader {
* Return the loaded BufferedImage by its filename.
*/
public static BufferedImage getBufferedImageByFilename(String filename) {
return Loader.images.get(filename.replace("/", File.separator));
if(CodeEnvironment.isJar()) {
return Loader.images.get(filename);
} else {
return Loader.images.get(filename.replace("/", File.separator));
}
}
/**