Project Zomboid

Project Zomboid

[B42] Week One NPC
Fix for NPC's taking over playspawn home
Npc's taking over spawn house. Regardless of what the mod author says, this is an issue I keep having. It doesn't matter how long I'm gone or what I'm doing, but if I leave my starter home, even for a second, letting the cell 'reset' (house isn't visible on screen or mini map) npcs will move in. If you try to get rid of them, or even enter the house I'll be attacked and usually killed. This is a nuance and is frankly ruining the game for me. Thankfully I found a fix.

1. navigate to the mods folder. This is usually

C:\SteamLibrary\steamapps\workshop\content\108600\3403180543

Note:
- the drive in which your steam content folder is located might be different. Mine for example is on an external D: drive.
- 108600 is the game zomboid
- 340318054 is the mod id

2. go through another set of folders:
mods\BanditsWeekOne\42\media\lua\client

3. find and open "BWOScheduler.lua" in notepad
4. search "function BWOScheduler.PlayerStart()" with CTRL F (no quotes)
5. inbetween this:

BWOScheduler.Add("VariantCall", {func="setup2"}, 500)
end

and this:

BWOScheduler.Add("FadeIn", {time=4}, conf.fadeIn)

add this:
BWOScheduler.Add("Start", {}, 50)

BWOScheduler.Add("BuildingHome", {addRadio = true}, 100)


do note, this seems related to those starting scenarios (which I hate). You can get rid of these simply by removing the files from

C:\SteamLibrary\steamapps\workshop\content\108600\3403180543\mods\BanditsWeekOne\42\media\lua\shared\Variants

don't remove the "VOriginal" start, and don't delete the other files, simple put them somewhere else, like your desktop or something. This way if you *want* to use them you can manually choose, instead of restarting the game a gazillion times, hoping for the one start you *do* want.

Also, do be aware, my fix does not prevent npcs from spawning *around* your house and looting it.
最后由 SinfulPetGirlRD 编辑于; 9 月 14 日 上午 11:51