Skip to content
This repository was archived by the owner on Feb 18, 2026. It is now read-only.

HSZemi/aoe2dat

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

65 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Warning

This project is no longer maintained. I simply got fed up with C++.
To access dat values directly, you can instead use the python package genieutils-py.

Tip

genieutils-py also offers a way to dump the dat file into one big json file, if you are into that kind of thing. The command is described in its README file. The keys are usually snake-cased versions of the CamelCase keys in the original genieutils (e.g. PlayerColours becomes player_colours).

aoe2dat

Extract Unit and Tech data from the Age of Empires II dat file

Cloning this repository

This repository uses git submodules, so clone it like this:

git clone --recurse-submodules <url>

Compiling

You will need cmake >3.0.0 and (some development dependencies).

cd code
mkdir build
cd build
cmake ..
cmake --build .

You should get a aoe2dat executable in the build folder.

Using

Call the aoe2dat executable with your dat file as an argument, for example:

./aoe2dat ~/aoe/Aoe2DE\ proton/resources/_common/dat/empires2_x2_p1.dat

You will get some console output and two files will be created in your current directory:

  • full.json which contains all extracted data, and
  • units_buildings_techs.json, a subset of the data which is used for Halfon.

Useful Paths

Units

data->Civs[civ]->Units[i]->HitPoints
data->Civs[civ]->Units[i]->Type50->DisplayedAttack
data->Civs[civ]->Units[i]->Type50->DisplayedMeleeArmour
data->Civs[civ]->Units[i]->Creatable->DisplayedPierceArmour
data->Civs[civ]->Units[i]->Creatable->ResourceCosts[Type=0]->Amount //Food
data->Civs[civ]->Units[i]->Creatable->ResourceCosts[Type=1]->Amount //Wood
data->Civs[civ]->Units[i]->Creatable->ResourceCosts[Type=2]->Amount //Stone
data->Civs[civ]->Units[i]->Creatable->ResourceCosts[Type=3]->Amount //Gold

About

Unit and Tech data, extracted from the Age of Empires II dat file

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors