Skip to main content

Read, transform, and write BioWare TLK V1 dialogue files

Project description

tlk-parser

Python library for reading, transforming, and writing BioWare TLK V1 dialogue files (used in games such as Baldurs Gate 2).

Install

pip install tlk-parser

For local development:

git clone https://github.com/mldelaney94/tlk_v1_parser.git
cd tlk_v1_parser
./setup_venv.sh
source ./activate_venv.sh

Usage

from tlk_parser import Tlk

tlk = Tlk("dialog.tlk")

# Inspect strings
for rep in tlk.string_reps:
    print(rep.str_string)

# Transform strings without mutating the original
translated = tlk.map_strings(lambda s: s.upper())
translated.save_tlk("dialog_upper.tlk")

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

tlk_parser-1.0.0.tar.gz (4.3 kB view details)

Uploaded Source

Built Distribution

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

tlk_parser-1.0.0-py3-none-any.whl (4.8 kB view details)

Uploaded Python 3

File details

Details for the file tlk_parser-1.0.0.tar.gz.

File metadata

  • Download URL: tlk_parser-1.0.0.tar.gz
  • Upload date:
  • Size: 4.3 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.3

File hashes

Hashes for tlk_parser-1.0.0.tar.gz
Algorithm Hash digest
SHA256 9e87749d74337f43044221fbcd8af1296e20a27b382b27842c20f9afdcab458d
MD5 0127e7d31f59c7b301e6c48dd21b9f87
BLAKE2b-256 a91214b6bae5409e53e0e2b6f296921cc504c43728dd83ae20253823dfae8156

See more details on using hashes here.

File details

Details for the file tlk_parser-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: tlk_parser-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 4.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.3

File hashes

Hashes for tlk_parser-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 63be5cfa1b09f839843ce90621b0c7bde3bb442e69e411ea5edf4f70d78ced69
MD5 ca456309577941f5f98ed0c9a943990d
BLAKE2b-256 0f54e8b76509e3d150c24b1b4f3137ca949c2e69a33509fb4fe3a380290ef8eb

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