Ajarmar / universal-pokemon-randomizer-zx

Public repository of source code for the Universal Pokemon Randomizer ZX
GNU General Public License v3.0
602 stars 154 forks source link

java.lang.OutOfMemoryError: Java heap space #86

Closed JordyJace closed 3 years ago

JordyJace commented 3 years ago

Downloaded v4.0.2 today and I keep getting this in the log, tried with v4.0.1 as well and got the same message. It's a 3ds file I'm trying to use.

Picked up _JAVA_OPTIONS: -Xmx256M Exception in thread "Thread-4" java.lang.OutOfMemoryError: Java heap space at com.dabomstew.pkrandom.ctr.RomfsFile.getContents(RomfsFile.java:52) at com.dabomstew.pkrandom.ctr.NCCH.getFile(NCCH.java:696) at com.dabomstew.pkrandom.romhandlers.Abstract3DSRomHandler.readFile(Abstract3DSRomHandler.java:185) at com.dabomstew.pkrandom.romhandlers.Abstract3DSRomHandler.readGARC(Abstract3DSRomHandler.java:174) at com.dabomstew.pkrandom.romhandlers.Gen7RomHandler.getAreaData(Gen7RomHandler.java:1247) at com.dabomstew.pkrandom.romhandlers.Gen7RomHandler.loadedROM(Gen7RomHandler.java:248) at com.dabomstew.pkrandom.romhandlers.Abstract3DSRomHandler.loadRom(Abstract3DSRomHandler.java:74) at com.dabomstew.pkrandom.newgui.NewRandomizerGUI.lambda$loadROM$94(NewRandomizerGUI.java:652) at com.dabomstew.pkrandom.newgui.NewRandomizerGUI$$Lambda$118/1605938864.run(Unknown Source) at java.lang.Thread.run(Unknown Source) edit: I AM using the launcher as well, my command prompt can't even find the program to run it manually without using the launcher.

tom-overton commented 3 years ago

Are you on Windows? Open a command prompt and do this: echo %_JAVA_OPTIONS%

And let me know what (if anything) shows up

tom-overton commented 3 years ago

Issue #91 was this exact issue too, and I updated the Java wiki with steps on how to resolve it: https://github.com/Ajarmar/universal-pokemon-randomizer-zx/wiki/About-Java#when-i-try-to-randomize-the-game-it-fails-and-i-see-something-like-picked-up-_java_options--xmx512m-in-launcher-logtxt