NetLogo User Community Models
WHAT IS IT?
This is a simulation of a town in which a zombie infection arises. The first version was a moderately faithful rewrite of Kevan Davis' Zombie Infection Simulation in NetLogo; since then we've added a lot of functionality.
HOW IT WORKS
Zombies are green, shamble around very slowly and change direction randomly and frequently unless they can see something moving in front of them, in which case they start walking towards it. After a while they get bored and wander randomly again.
If a zombie finds a human on the same patch, it infects them; the human immediately joins the ranks of the undead.
Humans are lightish gray and walk five times as fast as zombies, changing direction when they run into a wall, and sporadically otherwise. If they see a zombie in front of them, they turn around and panic.
Panicked humans are pink and run twice as fast as other humans. If a human sees another panicked human, it starts panicking as well. A panicked human who has seen nothing to panic about for a while will calm down again.
The military are red and move as regular humans do, unless they see a zombie or panicked human, which they will run towards. A member of the military will kill any zombies on a patch they walk into. Further options are open to the military if authorised:
HOW TO USE IT
Press SETUP to create and populate a new city.
*Town parameters* (only takes effect on SETUP)
*Initial populations* (only takes effect on SETUP or SETUP-BEINGS)
SIGNIFICANT DIFFERENCES FROM KEVAN'S
Beings' fields of vision are cones with 90 degree width instead of just the lines directly ahead. These fields of vision go through walls (I guess the beings can hear, or smell, or something).
The city wraps around unless you change the model topology; again, this is more natural in NetLogo than it might be in proce55ing.
Arbitrarily many beings may occupy one patch.
The city is carved out differently: although it has the same general feel, more types of passages can occur, for instance zig-zags:
Beings only look ahead of themselves every fifth time step. This was done to speed the model up, and appears to have no significant effects on the simulation.
THINGS TO NOTICE
Infection takes place much more slowly, in terms of simulation timesteps, than in the original model.
In zombie-dominated areas of the city, the zombies tend to form into lines (in the original model, we instead observe blobs).
THINGS TO TRY
In general: when do humans win, when do zombies win? Find combinations of settings that make it a fair fight. (E.g. does zombie wall-breaking actually help the zombie side? Do zombies do better when they sit in wait in their corridors, or destroy them digging out to where the brains are?)
What population density does panic need to be self-sustaining?
Make everyone a zombie, let zombies break walls 100% of the time, and watch the zombie streamers.
Play with NetLogo perspective features like watch and follow.
Resize the city, using the Edit button on the city display. This will probably require adjusting the numbers in the setup-town procedure to get the same overall proportion of open space.
EXTENDING THE MODEL
You've seen at least as many zombie movies as I have...
These extensions are more like bug-fixes:
And, of course, it would be nice to make it run faster.
The tunnels in the city are carved by a dedicated breed of turtle (an initial attempt to generate them with patch agentsets proved horribly slow).
I like the way beings reorient themselves after hitting a wall -- they can even follow tunnels with no special case movement rules.
Building damage after a nuke is implemented by having each patch in the blast radius
Beings never move by more than distance 1 at a time, to prevent them from jumping through walls.
CREDITS AND REFERENCES
Alex Fink and Sai Emrys, this version
Kevan Davis' original Zombie Infection Simulation, version 2.3:
NetLogo zombie simulators seem to've become popular in these last few years;
(back to the NetLogo User Community Models)