Please note that the provided batch file from AetherPirate will forcefully terminate any javaw.exe processes running and clear the _JAVA_OPTIONS environment variable. This may be undesirable, if you wish to manually do the edit, follow these instructions, note in Step 4 it will have "-Xmx:1024M" in your case.
Edit Environmental Variables in Windows 10 and Windows 8
1) In Search, search for and then select: System (Control Panel)
2) Click the Advanced system settings link.
3) Click Environment Variables. In the section System Variables, find the _JAVA_OPTIONS environment variable and select it. Click Edit.
4) In the Edit System Variable (or New System Variable) window, remove the -Xmx java option. Click OK. Close all remaining windows by clicking OK.
5) Restart the game