Project Zomboid

Project Zomboid

[41.78] Vanilla++ 'Sophie MAIN' - SP & MP - v1.14 | Updated December 12th 2024
 Denne tråd er blevet fastgjort, så den er sikkert vigtig
Deathstar  [udvikler] 31. okt. 2023 kl. 10:37
4
How to allocate more RAM to your game
This is an older method but I want to include it anways for people who are struggling with poor performance. By doing the following steps, you can allow for the game to make use of more of your RAM. Only do this if your machine has sufficient memory that's not occupied by other apps (browser, steam etc.). Check your task manager to see how much free RAM you have on average.

PLEASE NOTE: This may not actually result in increased performance. Some users have reported even more performance issues when allocating large amounts of memory (16 GB) when compared to the default. Project Zomboid is a CPU-heavy game moreso than a memory-heavy one.

++ 8 GB seems to be the sweetspot! ++

ALSO, note that anytime the game updates, you will likely have to make this edit again as the JSON files get redownloaded.


Step 1: Find your Zomboid JSON config file in the root folder

Navigate to your game's installation folder (NOT in Documents). To easily find this on Steam, right click your game in the library, hit Properties, go to Local Files and select Browse Local Folder. The address should look something like this: D:\Program Files\Steam\steamapps\common\ProjectZomboid\

This is your root folder. Inside here, find the following file: ProjectZomboid64.json (the .json may not appear). Open this file with an editor such as notepad or better yet, Notepad++.

Step 2: Allocate a custom amount of memory by editing a line

With the JSON file open, scroll down top the "vmArgs" section. Here, you should see a line that starts with "-Xmx". The number in this line dictates how much maximum memory the game can use. Edit only the four digits and give it a value that makes use of your free RAM without fully choking it. Ideally, this should be a Gigabyte amount, meaning the number should be divisible by 1024, e.g. 4096 or 8192.

If you want to allocate 8 GB of memory, the line should look like this: "-Xmx8192m",

Note that you can also use "g" for Gigabytes instead of m so "-Xmx8g" also works.

Again, please check the initial note of this post. This method may not increase performance at all, but it's there for you to try.

Step 2.1: If you are using Alternate Launch, edit the .bat file as well

In the same folder, find the ProjectZomboid64.bat or 32.bat depending on what you use and open it with notepad. Find "-Xmx" and change this to the same value as above, 8g for 8 Gigabytes and so on.
Sidst redigeret af Deathstar; 25. feb. 2024 kl. 5:01
< >
Viser 1-8 af 8 kommentarer
[+| CL rautamiekka 31. jan. 2024 kl. 10:15 
How are you not aware of the G suffix ? Using the M suffix is way more work than it's worth, if you're giving gigs of memory instead of megs.
Deathstar  [udvikler] 31. jan. 2024 kl. 10:24 
3
3
4
Oprindeligt skrevet af +| CL rautamiekka:
How are you not aware of the G suffix ? Using the M suffix is way more work than it's worth, if you're giving gigs of memory instead of megs.

I'm aware. Outcome is the same. Also pretty rude way to phrase that.
garbey 31. jan. 2024 kl. 16:37 
Oprindeligt skrevet af +| CL rautamiekka:
How are you not aware of the G suffix ? Using the M suffix is way more work than it's worth, if you're giving gigs of memory instead of megs.
"more work than it's worth" lol
Torflurch 2. feb. 2024 kl. 15:19 
Thank you for the tutorial, that is very helpful.
Is there a maximum you can allocate or is it also possible to set it to 16384MB?
Deathstar  [udvikler] 2. feb. 2024 kl. 22:05 
Oprindeligt skrevet af Torflurch:
Thank you for the tutorial, that is very helpful.
Is there a maximum you can allocate or is it also possible to set it to 16384MB?

Theoretically, you can set it as high as your hardware can handle, BUT this may actually cause issues. The game runs on a JVM and Java has some issues when handed too much memory. Some users reported weird glitches when using 16 GB, turning this down to 8 fixed it. This is why I refer to 6-8 GB as the sweetspot and it's also what I do all of my testing with.
Torflurch 3. feb. 2024 kl. 8:03 
Thanks, will stay with 8GB then :)
Xaquri 24. feb. 2024 kl. 13:22 
this is changing for the game itself right? Not for server allocation?
Deathstar  [udvikler] 24. feb. 2024 kl. 13:23 
Oprindeligt skrevet af Xaquri:
this is changing for the game itself right? Not for server allocation?

Correct. Client and server are separate.
< >
Viser 1-8 af 8 kommentarer
Per side: 1530 50