Skip to main content
Darksouls Save File Parser
==========================
.. image:: https://travis-ci.org/tarvitz/dsfp.svg?branch=master
:target: https://travis-ci.org/tarvitz/dsfp


* DSFP means Darksouls Save File Parser.
* `Dark Souls <http://darksouls.wikia.com/wiki/Dark_Souls>`_ is game of
Namco Bandai with pretty hard to get it finished without being killed.
Lot's of death, fun and broken gamepads/keyboards.

**DSFP** *serves* for getting/fetching your saved characters statistics purposes.

.. contents:: :local:
:depth: 2

Original source
~~~~~~~~~~~~~~~

Original source and some key knowledge were taken from this
`gist <https://gist.github.com/infausto/8382836/>`_.

Common features
~~~~~~~~~~~~~~~
Supports fetching data about character's death, his/her general stats, hp and stamina.
Whole bunch of reversed stats you can see in datasheet document which is placed
`here <docs/datasheet.rst>`_

(*Help for reverse engineering DarkSouls save file is appreciated*).

Installation
~~~~~~~~~~~~
For general installation you would probably need virtual environment with pip
installed:

Python 2.7
``````````
.. code-block:: bash

user@localhost$ virtualenv --no-site-packages venv
user@localhost$ source venv/bin/activate
user@localhost$ pip install -r requirements/base.txt

*optional*

.. code-block:: bash

user@localhost$ pip install -r requirements/docs.txt

Python 3.x
``````````
document build requirements stored in py3.txt

.. code-block:: bash
user@localhost$ virtualenv --no-site-packages venv3
user@localhost$ source venv3/bin/activate
user@localhost$ pip install -r requirements/py3.txt

Dependencies
------------
* python 2.7
* python 3.3
* python 3.4


Tests
~~~~~
Simply run ``python setup.py test`` or
You could run tests via `python -m unittest module` or via `run_tests.sh` script

.. code-block:: bash

user@localhost$ ./run_tests.sh tests.TestDSFPReader

Fast Usage
~~~~~~~~~~
You can parse Dark Souls save files and get data in standard python
dictionary format

.. code-block:: python

>>> import dsfp
>>> ds = dsfp.DSSaveFileParser('saves/DRAKS0005.sl2')
>>> data = ds.get_stats()
>>> data
[{
'attunement': 8, 'body': 0, 'class': 0, 'color': 0, 'deaths': 0,
'dexterity': 13, 'earned': 60, 'endurance': 12, 'face': 0, 'faith': 9,
'gift': 0, 'hairs': 0, 'hp': 594, 'hp2': 594, 'hp_current': 594,
'humanity': 0, 'intelligence': 9, 'level': 4,
'male': False, # False means female
'name': u'TEST_2', 'resistance': 11, 'souls': 60, 'stamina': 95,
'stamina2': 95, 'stamina3': 95, 'strength': 13,
'time': 62, # in seconds
'vitality': 11
}]




Datasheets
~~~~~~~~~~
There's no many information about Dark Souls save file format (as well as the
other games), so there's not much complete around its format.
Some knowledge represented `here <docs/datasheet.rst>`_.

Please notify me here or by email (tarvitz [at] blacklibrary.ru)
if you have something interesting around whole file format.

Documentation
~~~~~~~~~~~~~
Whole bunch of the docs you can read by clicking this link
`dsfp.readthedocs.org <http://dsfp.readthedocs.org>`_


Development
~~~~~~~~~~~

.. note::

Huge buch of data now represented in datasheets are still not covered in
dsfp "api" just cause whole file-format and its datasheet is the main priority.
You can use it for build your own parser or just read some non-random data
from *.sl2 files.
Though dsfp is not complete as it should, please search/read information in
the docs mentioned above.

Roadmap
~~~~~~~
I have no certain roadmap for this project and I inspect the data whenever I want
to do it. In general these moments could be very short/long from time to time. So don't
expect me finishing this work to some certain moment or something clear enough.

Use ``./scripts/watcher.py`` and the other scripts (or may be another methods) to inspect
data you need, contact me if you want to share them and have fun ;).

Metadata

Release files for dsfp 0.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for dsfp 0.0.1
File Size Uploaded Provenance
dsfp-0.0.1.tar.gz 9.8 kB Without provenance Details

Release files / dsfp-0.0.1.tar.gz

Download URL dsfp-0.0.1.tar.gz
Size 9.8 kB
Tags Source
SHA-256 checksum
How to use checksums
1552920538111211b3d01bc6f22733446608737c4fed01d11508243ba56e773c
BLAKE2b-256 checksum
How to use checksums
82bbcfde8f5565b53e76686a789192ccfc232d8fd2f09c1f93190a7aa06b543c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Security for dsfp 0.0.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

Release history Release notifications | RSS feed

This release

0.0.1 This release

1 release file No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page