Project Zomboid

Project Zomboid

418 ratings
Wake Them Up
3
4
2
2
3
4
2
3
2
   
Award
Favorite
Favorited
Unfavorite
File Size
Posted
Updated
278.132 KB
May 6, 2023 @ 11:10am
Dec 26, 2024 @ 10:23am
5 Change Notes ( view )

Subscribe to download
Wake Them Up

In 2 collections by Tchernobill
Project Zomboid Performances
3 items
B42
22 items
Description
Spawn building zombies fast optimizing performances costs.
Problem description in that video.
Ducks' Zombie Building Spawn Fix correction explained in this video.
This mod is a replacement to Ducks' Zombie Building Spawn Fix.
It adds the same improvement but with less drawbacks, see details below.

Technical stuff
  • does one room per cycle and suspends once the cell is fully woken up.
  • continues when the size increases (when new rooms are loaded). The trick is: the size never decreases.
  • as a primary consequence: the peak cost is only one room's cost. (instead of many as it occures a lot that many pop in one cycle) => that's what reduces / removes the stutters.
  • as a consequence: each room is only requested once. (instead of constantly)
  • as a consequence: long time server runs bigroom list is not a problem as the room list is never parsed.
  • Mimic Vanilla behaviour to avoid spawning Zombies in the player's spawning building.
  • Mimic Vanilla behaviour to avoid spawning Zombies in specific 'empty' rooms.

Remaining drawback
  • Spawning zombies faster than vanilla will increase the CPU load. So you have to choose between that CPU cost increase and the risk of last second zombie spawn as described in the video.

Non technical stuff


On Lockdown[theindiestone.com]
This mod cannot be modified by anyone else, for anything else, at all, ever. Even if the user disappears, he or she would much rather you didn't touch the fruits of their hard labour.

If you wanna support, kind words are very welcome.
If you don't have any, you can still give constructive criticism.

Workshop ID: 2972287975
Mod ID: WakeThemUp
109 Comments
Tchernobill  [author] Apr 2 @ 3:46pm 
@Gootube
From memory, the RoomList keeps all rooms loaded during the session.
It was not only the rooms of the current cell despite the namings.
There was no unloading from that list when cells were unloaded.
If it changed with B42, there should be a spam of the log I prepared for that potential evolution.

Such tricks are probably not the easiest way to start. Anyway what matters is not the difficulty, it is to your keep motivation going.
Have fun with modding.
Gootube Apr 2 @ 9:08am 
I tested this in debug mode and can confirm that it works.
But can you explain to me why did you say "The trick is: the size never decreases". Because when I check your code, the counter variable you use is cell.getRoomList(), why does that number never decreases. I thought each cell has its own room list so when you move to a new cell, that counter can increase/decrease depending on the new cell?
Just want to dive a little into modding stuff as a hobby so it's would be very nice if you can explain that to me.
SP4RTAN Apr 1 @ 4:22pm 
Well 42.6 apparently made forest zombies non-existent again.
Tchernobill  [author] Mar 24 @ 11:15am 
@SP4RTAN Interesting. I can't say for sure. Thanx for the Info. Retanaru is the Goat
SP4RTAN Mar 23 @ 2:16pm 
So I just learned that forest zombies in B42 kinda spawn the same way zombies spawn in buildings from this video: The Forests Are Dangerous In Project Zomboid. Would it be possible to apply this mod to that as well or would that not be feasible?
lancekro Mar 2 @ 6:08am 
I was wondering if a mod could simply remove the "line of sight inside building" requirement from the base game mechanic instead of forcing all buildings in the player's chuck to spawn the zombies.
Metal Izanagi Feb 28 @ 7:03pm 
Just from some testing on my own I think this mod doesn't play nice with either the Bandits mod or the Knox Event Expanded mod. Seems to cause some serious issues with how and where zombies spawn, especially with Bandits since they're technically zombies with different scripts attached to them. Shame to have to remove it, but it's killing my FPS with either of those mods active.
Berserk Feb 27 @ 6:08am 
Does this mod work in Raven cliff and allow people to maintain a high fps?
I usually play on insane pop but have a ryzen 7 3700x cpu.
Angela Feb 17 @ 12:56pm 
Thanks anyway.
Brett Orsborn Feb 16 @ 11:26am 
@Angela No sorry, I play over Geforce Now Ultimate on my Series X so only B41 is available till B42 goes stable.