Explainer

DayZ cfgeventspawns.xml explained

If you've doubled your cars in events.xml and still see the same number on the map, this is the file you're missing. events.xml decides how many of each event exist. cfgeventspawns.xml decides where they're allowed to appear: every car park, every helicopter crash site, every police wreck. An event can never exceed the number of places it has to spawn. Here's how the file works and how to add your own spots.

  • 4 min read
  • Updated
  • PlayStation, Xbox and PC
cfgeventspawns.xmlExample
<eventposdef>    <event name="VehicleCivilianSedan">        <pos x="12071.93" z="9129.99" a="317.95" />        <pos x="12302.37" z="9051.29" a="60.40" />    </event></eventposdef>

How it fits with events.xml

Each event in events.xml, such as VehicleCivilianSedan or StaticHeliCrash, has a matching block in cfgeventspawns.xml with the same name. That block lists positions. When the economy spawns the event, it picks one of the free positions.

So the real limit on cars or crashes is the smaller of two numbers: the event's nominal in events.xml and the positions in this file. Raising nominal past the positions does nothing. See events.xml explained.

What a position looks like

Each position is a pos line with an x and a z coordinate, and often an a for the angle the object faces in degrees. x runs west to east and z runs south to north across the map, in metres from the bottom left corner. Height isn't given because DayZ places the object on the ground.

The vanilla Chernarus file has 35 event blocks, from cars, boats and the bus to helicopter crashes, trains, convoys, infected and animal events.

Add a new spawn position

To add a spot where a car can appear:

  • Find the coordinates using an interactive DayZ map that shows x and z when you hover
  • Pick flat, open ground, such as a road side or a car park, so the car doesn't spawn into a wall
  • Add a pos line inside the right event block with x, z and an angle
  • Raise that event's nominal in events.xml if you want more at once
  • Restart, then check the spot in game

Choose good positions

A bad position is worse than none. Cars placed on slopes, in trees or inside buildings get stuck or explode on spawn. Crash sites in towns spawn on roofs. Keep positions spread across the map so events aren't all in one area, and keep them away from your own spawn and trader areas unless that's intended.

Static events and loot piles

Static events such as helicopter crashes, police wrecks, trains and military convoys use the same file. Their loot is set in events.xml as children of the event. Adding positions to StaticHeliCrash gives crashes more places to appear, which makes them harder to camp. See heli crash settings.

Changes and restarts

Positions are read when the server starts. Events already on the map stay where they are until they're destroyed or despawn, so new positions are used gradually as events respawn. If you need a clean slate for events, a loot reset clears them. See how to reset loot.

Planning a car-heavy server

Car servers are popular, especially on PvE and roleplay servers. A good set-up uses both files together. Add positions where players will actually find cars, such as car parks, petrol stations, farms and village roads, then raise nominal in events.xml to match. Keep min below nominal so cars come back over time after they're wrecked, and make sure cars spawn with enough parts to drive (see cfgspawnabletypes.xml explained).

More cars also means more for the server to track, and cars left in odd places can clutter the map. Watch performance for a few days before adding more.

Common mistakes

Most broken event files come down to one of these.

  • An event name that doesn't exactly match events.xml, so the positions are never used
  • A missing closing tag, which can stop the economy loading events at all
  • Copying another map's positions, which puts cars in the sea or mid-air
  • Hundreds of positions in one small area, which crowds the map

Tools for this

Common questions

Why don't I get more cars after raising nominal?

There aren't enough positions in cfgeventspawns.xml for that vehicle event. Add more pos lines to its block.

What do x, z and a mean?

x is east-west, z is north-south (both in metres) and a is the angle the object faces in degrees.

Can I edit cfgeventspawns.xml on console?

Yes. PlayStation and Xbox servers have the same file in the mission folder.

Can I add positions for boats?

Yes. Boats use the VehicleBoat event. Place positions on water near the shore, facing out to sea, so the boat doesn't spawn on land.

Why do cars spawn in the same places?

The event has few positions, or nominal is close to the number of positions. Add more spread-out positions so the economy has more choice.

How many positions should an event have?

At least a few more than its nominal, so the economy has a choice and events don't always appear in the same spots.

Do new positions work straight away?

After a restart, as events respawn. Events already on the map stay where they are.

Run your DayZ server from one place

Free editors for every config file, plus a live dashboard and Discord feeds when you're ready.