Launching Minecraft with more RAM

Discussion in 'Minecraft Server Tutorials' started by Rokugin, Sep 2, 2012.

  1. Rokugin

    Rokugin New Member

    Joined:
    Aug 13, 2012
    Messages:
    28
    Likes Received:
    7
    Code:
    java -Dsun.java2d.noddraw=false -Dsun.java2d.d3d=true -Dsun.java2d.opengl=false -Xms1024M -Xmx3072M -jar "%appdata%\.minecraft\minecraft.exe" username password
    Right click where you want the batch (launcher) located and click New > Text Document.

    Copy paste the above code into the text document. You can add your username and password to the end if you want it to log in automatically; If you don't want to do that, delete username and password from the end of the code.

    Click File > Save As...

    Name the file whatever you want and add .bat to the end of the name.

    Find where it says Save as type: Text Documents (*.txt)
    Click it and select All Files (*.*)

    Click Save

    It should create a batch file, which when double clicked will launch minecraft.exe with 1-3 GB of RAM, it scales as necessary.




    NOTE: If you have more RAM you can increase the -Xmx3072M accordingly. 1 GB of RAM is 1024M, for each GB you want to have as your max multiply 1024 by that amount.
     
    • Like Like x 5
  2. jokerr77

    jokerr77 Active Member

    Joined:
    Aug 26, 2011
    Messages:
    476
    Likes Received:
    93
    You could just change the M to G after the amount of RAM desired if you wanted to make it easier to understand if you have quite a bit of RAM. Thanks for this, now my 16g will be useful :D
    Also, where and how would one add their username and password? You should put what you need to add under the code as optional line to add to end.

    Eg, [What you need to add for username]: {username}; [What you need to add for password]: {password}
     
  3. Rokugin

    Rokugin New Member

    Joined:
    Aug 13, 2012
    Messages:
    28
    Likes Received:
    7
    Added the username and password to the code, thanks for the heads up.
     
    • Like Like x 1
  4. Brayneeah360

    Brayneeah360 Well Known Member

    Joined:
    Mar 29, 2012
    Messages:
    1,377
    Likes Received:
    230
    damn it... won't work. my (school) laptop won't recognize java as an internal or external command. :(
     
  5. TechTeller

    TechTeller Forum Legend

    Joined:
    Aug 23, 2011
    Messages:
    1,789
    Likes Received:
    745
    Make sure you can access java from the command line.
     
  6. Rokugin

    Rokugin New Member

    Joined:
    Aug 13, 2012
    Messages:
    28
    Likes Received:
    7
    The problem is that your computer doesn't know what to do with the command java since it hasn't been told what to do with it.

    You'll need to check to see if java is set as your Path. If you are comfortable following a guide to set that up online just make sure to include your operating system's information. There's a slight difference between setting it for 64bit and 32bit, as well as somewhat different locations between versions. If you reply with your information here I can help you locate a guide to set it.
     
  7. Brayneeah360

    Brayneeah360 Well Known Member

    Joined:
    Mar 29, 2012
    Messages:
    1,377
    Likes Received:
    230
    thanks for the help guys, but my school laptop blocks command prompt. also, i have java 6 32-bit installed. even though i have a 64-bit machine :( but i will try to change my java path, thanks. i hope that helps.
    (wait, would i be able to install java on another machine, then transfer it by USB, or bluetooth, or dropbox, or whatever, would i be able to change the path so that it accessed the pre-installed java 7u5?)
     
  8. Rokugin

    Rokugin New Member

    Joined:
    Aug 13, 2012
    Messages:
    28
    Likes Received:
    7
    Specifically for this type of launcher it might be possible, although it could cause issues setting your path to a USB drive that isn't always plugged in if you're trying to make it recognize java as being there.

    It might also help if you simply upgrade to java 7, if possible.


    EDIT: I misread your post, sort of, previous still stands.
    I don't advocate using pre-installed platforms like java or flash simply because of their wide variety of use, things like games or simple programs would not have much of an issue.

    Theoretically placing a pre-install of java on your machine and setting your path to it should work without a problem, assuming you can get the pre-install on there.

    I would suggest more research before becoming dedicated to a course of action like that, although worse case scenario you can delete the pre-install and reset your path to the proper location.
     
  9. Brayneeah360

    Brayneeah360 Well Known Member

    Joined:
    Mar 29, 2012
    Messages:
    1,377
    Likes Received:
    230
    thanks i will take a look into this. maybe i can increase my minecraft speed too :D
     
  10. jokerr77

    jokerr77 Active Member

    Joined:
    Aug 26, 2011
    Messages:
    476
    Likes Received:
    93
    Just wondering, do you increase the the 1024 or the 3072 to add more RAM? :/ Never really knew which one to change.
     
  11. ProForYou

    ProForYou Active Member

    Joined:
    Jul 20, 2012
    Messages:
    350
    Likes Received:
    45
    To be honest i did use the minecraft with more RAM before this tutorial. It worked. And it made my minecraft a little bit better. I could see that because i had a little bit of lag. But after that it was nothing. For you (the people) that got good computer don't even bother doing this. IT is more for the low pcs.
     
  12. Rokugin

    Rokugin New Member

    Joined:
    Aug 13, 2012
    Messages:
    28
    Likes Received:
    7
    Changing 1024 will increase the lowest amount it launches with, I don't suggest that since it's unnecessary for MC to run with more than a 1 GB of RAM. If you change the 3072 it changes the max that it can run with, allowing it to scale up to that number if it needs to do so.

    Well, it's mostly for PC's that have a lot of RAM but not a good processor or video card.
    If you do have those then it won't help much unless you're trying to run several resource heavy mods. Such as cranking up Optifine or Rei's Minimap. There are others that would benefit, I'm sure, but those are the two I'm aware of at the moment.
     
  13. ProForYou

    ProForYou Active Member

    Joined:
    Jul 20, 2012
    Messages:
    350
    Likes Received:
    45
    I am not really sure about the Optifine mod. What it does it boosts up your minecraft. It helped a lot! I got like 40-60 more FPS. Well i can't say that it made my minecraft lag. I was not lagging at all with or without extra ram. I just noticed that is it running a little bit smoother with extra ram. Also the optifine mod as far as i know just makes your fps boosts up. For the Rei's minimap i don't know. But thanks for the info.
     
  14. Rokugin

    Rokugin New Member

    Joined:
    Aug 13, 2012
    Messages:
    28
    Likes Received:
    7
    Optifine has a lot of options which are great for low end pc's, but it also grants the capability to use super high definition texture packs, which are massive resource hogs. You can also crank the view distance up to Extreme on working versions. You can turn up AA and Anistropic Filtering as well.

    It basically offers a ton of tweaks that can unleash your system on MC, if your system is up to par. Some of those options won't work if you have a weak PC, some of them pull more RAM
     
    • Like Like x 1
  15. ProForYou

    ProForYou Active Member

    Joined:
    Jul 20, 2012
    Messages:
    350
    Likes Received:
    45

    I see you know a lot about it. I know i tried once the Extreme on the working version. Ended with deleted the whole minecraft folder and redownloading the hole shit :D
     
  16. Mrfurret

    Mrfurret New Member

    Joined:
    Mar 22, 2013
    Messages:
    5
    Likes Received:
    0
    This sort of worked for me. I got more max RAM, but minecraft doesn't use it. Help!
     
  17. Luciano

    Luciano Stars of the Forums

    Joined:
    Jun 12, 2012
    Messages:
    1,132
    Likes Received:
    287
    Minecraft will only the ram it needs - you can set a max of lets say, 24gb - but it will only use as needed
     
  18. Exavious

    Exavious Forum Legend

    Joined:
    Jun 22, 2011
    Messages:
    2,013
    Likes Received:
    1,323
    You could also just download a program to do this for you instead of using a batch file, I use SKLauncher and it has the option in it to specify how much ram you want to devote to MC along with loading your mods for you.
     
  19. Dzyriq

    Dzyriq Just another humble Overseer

    Joined:
    Jun 22, 2011
    Messages:
    2,033
    Likes Received:
    950
    you may want to get MCMYAdmin and run minecraft through that. Then you get a very nice UI that deals with minecraft quite well
     
  20. coolskimmpyss

    coolskimmpyss Active Member

    Joined:
    Mar 30, 2012
    Messages:
    266
    Likes Received:
    104
    Ok so what is RAM. Im what you guys would call computer challenged.
     

Share This Page