Skip to main content

Re-implementation of genieutils in Python

Project description

genieutils-py

Python implementation of genieutils.

This library can be used to read and write empires2_x2_p1.dat files for Age of Empires II Definitive Edition.

Supported dat versions

Currently, only the latest version used in Age of Empires II Definitive Edition is supported (GV_LatestDE2/GV_C20).

Installation

pip install genieutils-py

Usage examples

Dump the whole dat file as json

The package comes with a handy command line tool that does that for you.

dat-to-json path/to/empires2_x2_p1.dat

Change cost of Loom to 69 Gold

from genieutils.datfile import DatFile

data = DatFile.parse('path/to/empires2_x2_p1.dat')
data.techs[22].resource_costs[0].amount = 69
data.save('path/to/modded/empires2_x2_p1.dat')

Prevent Kings from garrisoning

from genieutils.datfile import DatFile

data = DatFile.parse('path/to/empires2_x2_p1.dat')
for civ in data.civs:
    civ.units[434].bird.tasks.pop()
data.save('path/to/modded/empires2_x2_p1.dat')

Authors

HSZemi - Original Author

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

genieutils_py-0.0.4.tar.gz (20.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

genieutils_py-0.0.4-py3-none-any.whl (26.6 kB view details)

Uploaded Python 3

File details

Details for the file genieutils_py-0.0.4.tar.gz.

File metadata

  • Download URL: genieutils_py-0.0.4.tar.gz
  • Upload date:
  • Size: 20.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.9

File hashes

Hashes for genieutils_py-0.0.4.tar.gz
Algorithm Hash digest
SHA256 9fa625ef2e7261f30382132570c92e25cd12bbbe3179099374cd869ab615ce31
MD5 e3835d6109c12b48a65b9c9330f37f0e
BLAKE2b-256 ce3e1b7f29c7944dc18f391668943778f01d4e07e2a54b82914f22cd1d83a95f

See more details on using hashes here.

File details

Details for the file genieutils_py-0.0.4-py3-none-any.whl.

File metadata

  • Download URL: genieutils_py-0.0.4-py3-none-any.whl
  • Upload date:
  • Size: 26.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.0.0 CPython/3.11.9

File hashes

Hashes for genieutils_py-0.0.4-py3-none-any.whl
Algorithm Hash digest
SHA256 6ffc815a3a99c825aa230f876ae00f5d4353c39a7fef31f76519482fd8267e0e
MD5 1b93209930755b894e651c78067baf68
BLAKE2b-256 255c775df9211b590e3423f90212a17c662b3f308bbf1c06e6c4dfc1e0135ab7

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page