It took me 6 hours but I found the fix!
What you need to do is go to control panel, then system and security, then system.
On the left hand side is a list of stuff; click advanced system settings in the new window, click "Environment Variables" on the bottom right.
In the new window, find the variable "_JAVA_OPTIONS", select it and click edit then change the value to whatever amount of RAM you like. For example -Xmx4096M for 4GB, or -Xmx2048 for 2GB
Done.