Jump to content

WalkerSim 2 (Beta)


ZehMatt

Recommended Posts

This is a continuation of my previous mod (A19) WalkerSim - Enhanced roaming zombies - Mods - 7 Days to Die but written from scratch. If you ever felt like this game lacks wandering zombies then this mod will be what you are looking for.

 

What is this?

Instead of having zombies spawned at random this mod will simulate thousands of zombies on the map and when a player is close enough it will actually spawn them in-game, if the player is too far away the zombie will despawn and be put back into the simulation also remembering the state such as health and class. So if you clear some area then this area is actually clear until the zombies advance in the simulation to that area again.

 

This is a fast-forwarded illustration of how the simulation reacts to loud noises, the red circles illustrate the position and will fade out over time. WalkerSim will also load the roads which the zombies will prefer to navigate creating a more realistic behavior, even the undead probably prefer a path with least resistance. Most aspects of the simulation can be modified, see the xml file and its schema, proper documentation will follow at some point.

image.gif.5b2ccc8cce7bc333ee77d32505f01095.gif

 

This preview is from the Viewer which is not polished enough yet to release and acts more as a debug tool for me, however you can see the simulation in-game by using the console command walkersim show which looks like following:

image.thumb.png.65b625052e8f3af0f925331a1c2727c7.png

 

I want to see it before I test it!

@Guppycur did stream some testing, 

 

 

Download

You can download the latest version from Releases · ZehMatt/7dtd-WalkerSim2 (github.com) (Last updated 8/30/2024)

 

Contact

Feel free to hop on the Discord Channel if you have any questions or issues, the channel is kindly hosted by @Guppycur

 

Installation & Usage

Local/Singleplayer

Download the latest version and unpack the zip into <YOUR_STEAM_PATH>/steamapps/common/7 Days to Die/Mods , so when unpacked it will be <YOUR_STEAM_PATH>/steamapps/common/7 Days to Die/Mods/WalkerSim/WalkerSimMod.dll 

Servers

Download the latest version and unpack the zip into <PATH_TO_INSTALL>/steamapps/common/7 Days to Die Dedicated Server/Mods , so when unpacked it will be <YOUR_STEAM_PATH>/steamapps/common/7 Days to Die Dedicated Server/Mods/WalkerSim/WalkerSimMod.dll

 

WalkerSim comes with a standard configuration file which was created to work with Navezgane, the best way to modify the simulation configuration is to run WalkerSim.exe which is located in the Mods/WalkerSim directory, this is a GUI application to help you configure and preview the simulation before starting the game/server. The best way to get started is to import the default configuration Mods/WalkerSim in the GUI and change it as you please, once you are satisfied with the preview simply export the configuration and either replace the default WalkerSim.xml or place it in the world folder, if WalkerSim.xml exists in the world folder it will take priority and load that instead of the one inside the Mods/WalkerSim directory.

 

EAC NOTE

When using this mod on your computer, EAC should be turned off. When the mod is installed on a server then the clients do not require to turn it off.

 

LINUX NOTE

In case you see some exception when starting a dedicated server on Linux you may be missing some dependencies, run apt-get update && apt-get install -y apt-utils libgdiplus libc6-dev to resolve the issue, depending on your OS it might be a different package manager, just ensure libgdiplus and libc6-dev is installed.

 

! Beta !

The reason I'm putting it out there right now is to get early feedback and suggestions. A lot of the functionality is not properly documented.

 

Changelog

0.9-beta.8

  • IMPORTANT: The configuration MaxAgents is now replaced by PopulationDensity to better support multiple world sizes with a single configuration. The new configuration specifies how many agents per square kilometer, so the total amount of agents will be square kilometers multiplied by density, for example having density set to 160 and playing on a 6k map will be 6 x 6 x 160 which will be 5760 agents in total.
  • A lot of fixes to the viewer. If you don't see any Worlds in the Viewer that means it failed to detect your 7 Days to Die Install, I will fix this in the next version.
  • A couple bug fixes in the mod.
  • Added new movement processors and re-organized them, existing configurations will probably no longer function correctly. 
  • Added walkersim stats console commands to print some information.

0.9-beta.7

  • The simulation is now persistent which means that if a game is continued from a save file the simulation will be also restored.
  • The viewer 'WalkerSim.exe' should be in a usable state now, you can now setup and preview the simulation and export the configuration.
  • Fixed an issue that wouldn't fast forward the newly created simulation when using TicksToAdvanceOnStartup
  • Fixed custom sounds not being registered in the simulation.
  • Changed how sound events decay, instead of decreasing the radius it has a duration and stays the same size.
  • EnemySpawnMode is now respected, when disabled no zombies will be spawned. 
  • Added walkersim timescale <value> console commands to modify the simulation speed.

0.9-beta.6

  • Fixed a performance issue.
  • Implemented more functionality in the viewer.

0.9-beta.5

  • Fixed exception when game is starting.

0.9-beta.4

  • Fixed zombies not spawning near players that previously died.
  • Respawning is now implemented, agents will respawn according the configuration of AgentRespawnPosition
  • Added walkersim pause and walkersim resume console commands to pause/resume the simulation.
  • Added detection to see if the client is the host and disables the mod accordingly, joining servers with the mod installed will no longer error.

 

 

Edited by ZehMatt
0.9-beta.8 (see edit history)
Link to comment
Share on other sites

25 minutes ago, uppedzulu said:

How do I change the maxentity?? 

Max agents my apologies, I found out where I can actually see what it's set to, but I cannot change it, where do I need to go to edit the number? 

Link to comment
Share on other sites

13 hours ago, MrSamuelAdams said:

This is definitely a interesting take. 

 

I would assume any mods that affect zombie spawn rate should be removed if you have this mod installed. 

 

Does it affect wandering Hordes at all or just biome/spawns. 

Its both, wandering hordes and biome spawns are replaced.

 

7 hours ago, uppedzulu said:

Max agents my apologies, I found out where I can actually see what it's set to, but I cannot change it, where do I need to go to edit the number? 

Modify WalkerSim.xml and set MaxAgents to the number you like.

 

3 hours ago, nismo1969 said:

Question, does RandomSeed need to be the world seed? Or is this something different entirely. Thanks

No, it just influences the simulation.

Link to comment
Share on other sites

1 hour ago, ZehMatt said:

Its both, wandering hordes and biome spawns are replaced.

 

Modify WalkerSim.xml and set MaxAgents to the number you like.

 

No, it just influences the simulation.

I figured it out, I didn't see the part in notepad (literally right in front of my face) that said "file" 😅😅 ever tried to ramp the number up to 1.5 million?? I did and let me tell you what!!! Like McDonald's, I'm loving it!!! I took almost 40 minutes to load every one of them @%$#s BUT it loaded up, and without any lag in my world, wandering hordes?? Why?? When I have almost 150,000 zombies per kilometer of map 😅🤣🤣 

Link to comment
Share on other sites

10 minutes ago, uppedzulu said:

I figured it out, I didn't see the part in notepad (literally right in front of my face) that said "file" 😅😅 ever tried to ramp the number up to 1.5 million?? I did and let me tell you what!!! Like McDonald's, I'm loving it!!! I took almost 40 minutes to load every one of them @%$#s BUT it loaded up, and without any lag in my world, wandering hordes?? Why?? When I have almost 150,000 zombies per kilometer of map 😅🤣🤣 

 

I honestly never tried such huge numbers but the entire thing was specifically designed not to cause any performance issues, but I'm a bit surprised, my max target was around 30k at most.

Link to comment
Share on other sites

So just continuing the train of thought on types of spawns it may influence...
I assume things like POI/sleepers, blood moon hordes, alarm-type spawns are not affected.
What would add to this, mod-wise?
Would other mods that affect wandering hordes, roaming/biome spawn that use "append" coding add to yours, or would there still be a conflict?
Would others that increase the size of hordes and/or number of biome spawns/biome conflict or add-to yours?
I know there are some issues on word-use of things like "wandering" "roaming" etc for horde spawns, but this is strictly for static spawns, right?
Shouldn't affect any mechanics that spawn in pathing groups of mobs, right?
Just trying to get some clarity on what mods to pair with it and where to place it in load order with others.

Thanks ZehMatt!

Link to comment
Share on other sites

6 minutes ago, LordSoth01 said:

So just continuing the train of thought on types of spawns it may influence...
I assume things like POI/sleepers, blood moon hordes, alarm-type spawns are not affected.
What would add to this, mod-wise?
Would other mods that affect wandering hordes, roaming/biome spawn that use "append" coding add to yours, or would there still be a conflict?
Would others that increase the size of hordes and/or number of biome spawns/biome conflict or add-to yours?
I know there are some issues on word-use of things like "wandering" "roaming" etc for horde spawns, but this is strictly for static spawns, right?
Shouldn't affect any mechanics that spawn in pathing groups of mobs, right?
Just trying to get some clarity on what mods to pair with it and where to place it in load order with others.

Thanks ZehMatt!

 

It disables the wandering hordes and biome spawns however it will still use the biome data when it spawns them near a player unless the virtual zombie has already a class id assigned from a previous spawn. As for mod conflicts you have to just try it, I'm not sure what other mods hook the biome spawner and wandering horde spawner, that is the only thing my mod really touches, once they are spawned the mod has no say in how they function. Someone else has tried this mod with the NPC mod and that seems to be working fine, so I can't really say more than that, just try it and if something breaks I can look into it.

Link to comment
Share on other sites

1 hour ago, ZehMatt said:

 

I honestly never tried such huge numbers but the entire thing was specifically designed not to cause any performance issues, but I'm a bit surprised, my max target was around 30k at most.

I'd really like to try and make a server with it but being the fact it took around 37ish minutes to even load into the world, I know that nobody else is gonna want to wait I've half an hour just to get in. So I actually thought of trying 30k myself because I attempted it incrementally, first I went 50k, then 150, then to 1.5mil, 50k still took a while to load though I suspect with more updates that may change, 150 also took a while but 1.5mil took a WHILE lol so I'm gonna test it at 30k to see what kind of result I get, if you try 1.5mil it may seem like it's not loading, just let it be and it'll load up in time, like I said for me it took around 37-40 minutes so be patient if you dare to try it lol 

Link to comment
Share on other sites

31 minutes ago, uppedzulu said:

I'd really like to try and make a server with it but being the fact it took around 37ish minutes to even load into the world, I know that nobody else is gonna want to wait I've half an hour just to get in. So I actually thought of trying 30k myself because I attempted it incrementally, first I went 50k, then 150, then to 1.5mil, 50k still took a while to load though I suspect with more updates that may change, 150 also took a while but 1.5mil took a WHILE lol so I'm gonna test it at 30k to see what kind of result I get, if you try 1.5mil it may seem like it's not loading, just let it be and it'll load up in time, like I said for me it took around 37-40 minutes so be patient if you dare to try it lol 

 

I will most likely cap the limit to something reasonable in the future, I think 30k should be the maximum limit. As for the slow startup, when it creates the initial simulation it will advance 1000 ticks directly so that may take a while if you do it with 1.5 million agents, I will remove this or at least make it optional. I think you should try out something smaller first like 15k, the simulation does not ignore the maximum zombies allowed to spawn and is in fact only using half of the size to still allow sleepers to spawn so cranking this up to really big numbers won't really make that much of a difference at the end.

Link to comment
Share on other sites

7 hours ago, ZehMatt said:

Its both, wandering hordes and biome spawns are replaced.

 

Modify WalkerSim.xml and set MaxAgents to the number you like.

 

No, it just influences the simulation.

1. Interesting so would you say that it's more or less zombies than say khaines wandering horde mod or an increase Wilderness spawn or yours is just a different experience?   

Because currently I use Khaine's wandering horde mod and this one. 

https://www.nexusmods.com/7daystodie/mods/5176

 

and if I want to use yours I should remove Khaine's and Dan's zombies yes?

 

I saw above, as far as blood moon mods I have, they should be OK? I'll have to test it. I'm interested in this idea. 

 

 

2. When you kill all the zombies in the area, is there a timer for them to respawn or are they dead forever then? 

 

"advance in the simulation to that area again." 

 

How long does that usually take? What's the respawn timer for it. 

 

 

Edited by MrSamuelAdams (see edit history)
Link to comment
Share on other sites

4 hours ago, MrSamuelAdams said:

1. Interesting so would you say that it's more or less zombies than say khaines wandering horde mod or an increase Wilderness spawn or yours is just a different experience?   

Because currently I use Khaine's wandering horde mod and this one. 

https://www.nexusmods.com/7daystodie/mods/5176

 

and if I want to use yours I should remove Khaine's and Dan's zombies yes?

 

I saw above, as far as blood moon mods I have, they should be OK? I'll have to test it. I'm interested in this idea. 

 

 

2. When you kill all the zombies in the area, is there a timer for them to respawn or are they dead forever then? 

 

"advance in the simulation to that area again." 

 

How long does that usually take? What's the respawn timer for it. 

 

 

 

I never tried this mod so I can not really make a good comparison to how it works but from what I understand the both are not too far apart, that is something you have to try out and see how they are different when it comes down to gameplay. As for running both at the same time, I suspect it hooks the same functions as this mod so running both at the same time is probably not going to work and I would also not really recommend it when two things try to address more or less the same issue.

 

When zombies are killed they are sent back to the simulation and will spawn at the location specified in the configuration, that can be at the map border, random location, random poi or just entirely random position, this is currently however not implemented but I figured it will take a while to sweep 15k zombies off the map before anyone would even notice, quite a few things from the configuration have currently no effect but that is where its heading to.

Link to comment
Share on other sites

Very interesting concept. A few questions if you don't mind:

  • Does this work in co-op? I never did bother with a dedicated server for just three people.
  • Would mods like remove vultures conflict with it. Remove snakes, etc.? I don't think they are actually removed per-se, just replaced with something else.
  • What about the popular ImprovedHordes. I'm guessing this will conflict and needs to be removed?
  • Do I need a new save and map?
Edited by Canes (see edit history)
Link to comment
Share on other sites

Does this mod remove pop-in zombies? You, know, the ones that aren't there until they suddenly pop-in ...magically appearing out of nowhere right in front of you (or behind you)? I hope I'm not the only one who experiences that phenomenon. I'm not talking about the closet ones or sleepers, but ones that  are just suddenly standing there all of the sudden like they been beamed down from a space ship, it's ridiculous. 

Link to comment
Share on other sites

Very cool to see this being developed further. Is the animal spawning unaffected in this version? In A19 it did have some issues with no animals spawning if i remember correctly, especially hostile ones.

How does it handle horde night? I haven't tried so far. Massive shooting resulting in even more zombies?

Link to comment
Share on other sites

9 hours ago, Canes said:

Very interesting concept. A few questions if you don't mind:

  • Does this work in co-op? I never did bother with a dedicated server for just three people.
  • Would mods like remove vultures conflict with it. Remove snakes, etc.? I don't think they are actually removed per-se, just replaced with something else.
  • What about the popular ImprovedHordes. I'm guessing this will conflict and needs to be removed?
  • Do I need a new save and map?

You should be able to play co-op with this mod, whoever hosts the game needs to have the mod installed and also EAC turned off. I don't think its compatible with ImprovedHordes. You can use this mod with any pre-existing save.

 

8 hours ago, r3mot3control said:

Does this mod remove pop-in zombies? You, know, the ones that aren't there until they suddenly pop-in ...magically appearing out of nowhere right in front of you (or behind you)? I hope I'm not the only one who experiences that phenomenon. I'm not talking about the closet ones or sleepers, but ones that  are just suddenly standing there all of the sudden like they been beamed down from a space ship, it's ridiculous. 

Yes this mod is made to change exactly this, random spawning is entirely removed and instead relies on the simulation data to mimic wandering zombies across the map.

 

2 hours ago, Midnighter90 said:

Very cool to see this being developed further. Is the animal spawning unaffected in this version? In A19 it did have some issues with no animals spawning if i remember correctly, especially hostile ones.

How does it handle horde night? I haven't tried so far. Massive shooting resulting in even more zombies?

That animal spawning is unaffected by this mod.

Link to comment
Share on other sites

On 8/9/2024 at 4:13 PM, ZehMatt said:

You should be able to play co-op with this mod, whoever hosts the game needs to have the mod installed and also EAC turned off. I don't think its compatible with ImprovedHordes. You can use this mod with any pre-existing save.

 

Thanks for the fast reply, but for co-op only the host needs to install this, not all clients? That doesn't sound right.

Edited by Canes (see edit history)
Link to comment
Share on other sites

The one thing I need to figure out now is why the world is desolate. No zombies around besides the sleeper ones. I wonder if it's something related to co-op or if I need to use a bigger MaxAgents number.

Also, do we need Enemy Spawning setting to off or it doesn't matter? -- I've seen it mentioned somewhere and I was wondering.

Edited by Canes (see edit history)
Link to comment
Share on other sites

5 hours ago, Canes said:

 

Thanks for the fast reply, but for co-op only the host needs to install this, not all clients? That doesn't sound right.

 

EDIT: Wow, this is taking forever to load on default settings. 30+ minutes. Co-op buddies will not agree to this.

Only the host/server needs this mod, the server is the thing that spawns/despawns them so the client doesn't need to be aware to how thats done.

 

3 hours ago, Canes said:

Can't edit the post above anymore so here's the follow-up. The loading issue was because of another mod, this one loaded fairly quickly, no issues there. The one thing I need to figure out now is why the world is desolate. No zombies around besides the sleeper ones. I wonder if it's something related to co-op or if I need to use a bigger MaxAgents number.

Also, do we need Enemy Spawning setting to off or it doesn't matter? -- I've seen it mentioned somewhere and I was wondering.

Turning off enemy spawning will probably disable the mod as it still asks for permissions before spawning a zombie.

 

30 minutes ago, r3mot3control said:

I hate to be that guy, but how/where do I install this?

 

 

Unpack the folder from the archive to "<path_to_7daystodie>/Mods", example: "C:\Program Files\Steam\steamapps\common\7 Days To Die\Mods".

Link to comment
Share on other sites

So this is what I have so far with the debug, but there are no zombies anywhere, it's desolate. Loud sounds, like firing the guns doesn't do anything either. I wonder what I'm doing wrong.

 

spacer.png

 

This doesn't do anything either:

 

spacer.png

Edited by Canes (see edit history)
Link to comment
Share on other sites

I would like to try this mod but I only get two  error messages:

2024-08-09T22:24:46 3.443 INF [MODS]   Trying to load from folder: 'WalkerSim'
2024-08-09T22:24:46 3.447 INF [MODS]     Loaded Mod: WalkerSim (1.0.0.0)
2024-08-09T22:24:46 3.449 INF [MODS] Initializing mod code
2024-08-09T22:24:46 3.451 INF [MODS]   Initializing mod WalkerSim
2024-08-09T22:24:46 3.454 INF [MODS]     Found ModAPI in WalkerSimMod.dll, creating instance
2024-08-09T22:24:46 3.461 ERR [MODS]     Failed initializing ModAPI instance on mod 'WalkerSim' from DLL 'WalkerSimMod.dll'
2024-08-09T22:24:46 3.466 EXC Could not load file or assembly '0Harmony, Version=2.13.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies.
  at WalkerSim.WalkerSimMod.IModApi.InitMod (Mod _modInstance) [0x0003b] in <757adcf7281b45fca7e123c5ac586321>:0 
  at Mod.InitModCode () [0x0009d] in <40e9b6e9762f43cf836123d0f549ad32>:0 
UnityEngine.StackTraceUtility:ExtractStringFromException(Object)
Log:Exception(Exception)
Mod:InitModCode()
ModManager:LoadMods()
GameManager:Awake()

 

2024-08-09T22:24:46 3.624 ERR Error loading types from assembly C:\Disks\Games\Data\Clients\Steam\steamapps\common\7 Days To Die\Mods\WalkerSim\WalkerSimMod.dll
2024-08-09T22:24:46 3.627 EXC Could not load file or assembly '0Harmony, Version=2.13.0.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies.
  at (wrapper managed-to-native) System.MonoCustomAttrs.GetCustomAttributesDataInternal(System.Reflection.ICustomAttributeProvider)
  at System.MonoCustomAttrs.GetCustomAttributesDataBase (System.Reflection.ICustomAttributeProvider obj, System.Type attributeType, System.Boolean inheritedOnly) [0x00010] in <467a840a914a47078e4ae9b0b1e8779e>:0 
  at System.MonoCustomAttrs.GetCustomAttributesData (System.Reflection.ICustomAttributeProvider obj, System.Boolean inherit) [0x00011] in <467a840a914a47078e4ae9b0b1e8779e>:0 
  at System.Reflection.CustomAttributeData.GetCustomAttributesInternal (System.RuntimeType target) [0x00000] in <467a840a914a47078e4ae9b0b1e8779e>:0 
  at System.RuntimeType.GetCustomAttributesData () [0x00000] in <467a840a914a47078e4ae9b0b1e8779e>:0 
  at System.Reflection.MemberInfo.get_CustomAttributes () [0x00000] in <467a840a914a47078e4ae9b0b1e8779e>:0 
  at ReflectionHelpers.MemberHasAttribute (System.Reflection.MemberInfo _memberInfo, System.Type _attributeType) [0x00000] in <40e9b6e9762f43cf836123d0f549ad32>:0 
  at ReflectionHelpers.FindTypesWithAttribute[T] (System.Action`1[T] _typeFoundCallback, System.Boolean _allowAbstract) [0x00058] in <40e9b6e9762f43cf836123d0f549ad32>:0 
UnityEngine.StackTraceUtility:ExtractStringFromException(Object)
Log:Exception(Exception)
ReflectionHelpers:FindTypesWithAttribute(Action`1, Boolean)
XmlPatcher:.cctor()
<PatchAndLoadXuiXml>d__100:MoveNext()
ThreadManager:RunCoroutineSync(IEnumerator)
LocalPlayerUI:Start()

 

I am running 7 Days to Die without EAC on Windows 11 and created an exception for the mod folder in my Antivirus software.

Any ideas what the problem could be?

 

Kind regards,
Shashahan

 

 

 

 

 

 

 

 

 

Forget it 🤦‍♂️. It was my fault for deleting the Harmony Folder... https://7daystodiemods.com/stop-deleting-the-harmony-folder/

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...