How Animal Spawns work in DayZ
Animal spawns work a bit different to event spawns. Lets see how we do it!
Looking for DayZ console bot setup guides?
See our feature pages for DayZ auto ban, and DayZ economy bot.
Animal Spawns in DayZ are controlled by two files: events.xml and AnimalName_territories.xml located in the env folder.
Below is an example configuration for bears:
<event name="AnimalBear">
<nominal>0</nominal>
<min>2</min>
<max>2</max>
<lifetime>180</lifetime>
<restock>0</restock>
<saferadius>200</saferadius>
<distanceradius>0</distanceradius>
<cleanupradius>0</cleanupradius>
<flags deletable="0" init_random="0" remove_damaged="1"/>
<position>fixed</position>
<limit>custom</limit>
<active>1</active>
<children>
<child lootmax="0" lootmin="0" max="1" min="1" type="Animal_UrsusArctos"/>
</children>
</event>Configuration Explanation:
- <name> defines the event identifier.
- <nominal> represents the target number the system attempts to maintain.
- <min> and <max> define the minimum and maximum number of active events allowed.
- <lifetime> controls how long the event remains active before cleanup.
- <restock> determines the respawn delay.
- <saferadius> defines the minimum spawn distance from players.
- <distanceradius> defines how close this event can spawn relative to other similar events.
- <cleanupradius> defines the distance from players at which the event becomes eligible for cleanup.
In this configuration:
- nominal is set to 0
- min and max are both set to 2
This ensures that exactly two bears will always exist on the map.
If instead you configure:
- min = 0
- max = 2
- nominal = 2
The server may initially spawn 0, 1, or 2 bears. If the active count drops below two, the system will attempt to respawn additional bears over time.
Child Configuration:
<child lootmax="0" lootmin="0" max="1" min="1" type="Animal_UrsusArctos"/>This entry instructs the Central Loot Economy to spawn one bear per selected location.
If you change min="1" and max="2", up to two bears may spawn at a single location, depending on event calculations.
Territory and Zone Configuration:
Spawn locations are defined inside the corresponding AnimalName_territories.xml file.
Each file is structured using Territories and Zones.
When spawning an animal, the Central Loot Economy: 1. Selects a Territory. 2. Selects one Zone within that Territory. 3. Spawns the animal within that Zone’s defined radius.
Example:
<territory color="4294923520">
<zone name="Graze" smin="0" smax="0" dmin="0" dmax="0" x="1920" z="13115" r="100"/>
<zone name="Graze" smin="0" smax="0" dmin="0" dmax="0" x="2085" z="13415" r="200"/>
<zone name="Graze" smin="0" smax="0" dmin="0" dmax="0" x="2465" z="14005" r="150"/>
<zone name="Graze" smin="0" smax="0" dmin="0" dmax="0" x="2485" z="14580" r="150"/>
<zone name="Graze" smin="0" smax="0" dmin="0" dmax="0" x="2780" z="14350" r="150"/>
<zone name="Graze" smin="0" smax="0" dmin="0" dmax="0" x="3260" z="14625" r="150"/>
</territory>If you want each of these zones to function as independent spawn locations, you can either:
- Split each zone into its own Territory, or
- Create additional Territories with custom locations.
By increasing the min and max values in your event configuration, more animals can spawn across these new Territories.
Example of closely grouped individual territories:
<territory color="4294929405">
<zone name="Graze" smin="0" smax="0" dmin="0" dmax="0" x="12804.70" z="10504.61" r="60"/>
</territory>
<territory color="4294929405">
<zone name="Graze" smin="0" smax="0" dmin="0" dmax="0" x="12908.30" z="10528.26" r="60"/>
</territory>
<territory color="4294929405">
<zone name="Graze" smin="0" smax="0" dmin="0" dmax="0" x="12876.43" z="10475.07" r="60"/>
</territory>Additional Zone Parameter Definitions:
- r = Radius of the zone (spawn area size).
- smin / smax = Static minimum and maximum. These control guaranteed (always present) spawns within the zone.
- dmin / dmax = Dynamic minimum and maximum. These are controlled by the event system and determine how many entities can spawn dynamically within the zone.