Filter items and sigils in your inventory based on affixes, aspects and thresholds of their values. For questions, feature request or issue reports join the discord or use github issues.
]
C:/Users/<WINDOWS_USER>/.d4lf/profiles
folder. The GUI
importer has a button to open this folder directly. If imported they are placed there automatically.[ dexterity, 33 ]
[ dexterity, 33 ]
are still completely valid. The importer creates affix fields which look
like {name: dexterity, value: 33}
. These are identical and either format can be used interchangeably. We
recommend starting all new builds through the importer, so examples show the format the importer uses.vision_mode_only
to true
.The config folder in C:/Users/<WINDOWS_USER>/.d4lf
contains:
[general] | Description |
---|---|
profiles | A set of profiles separated by comma. d4lf will look for these yaml files in config/profiles and in C:/Users/WINDOWS_USER/.d4lf/profiles |
keep_aspects | - all : Keep all legendary items - upgrade : Keep all legendary items that upgrade your codex of power - none : Keep no legendary items based on aspect (they are still filtered!) |
handle_rares | - filter : Filter them based on your profiles - ignore : Ignores all rares, vision mode shows them as blue and auto mode never junks or favorites them - junk : Vision mode shows them always as red, auto mode always junks rares |
handle_uniques | How to handle uniques that do not match any filter. This property does not apply to filtered uniques. All mythics are favorited regardless of filter. - favorite : Mark the unique as favorite and vision mode will show it as green (default)- ignore : Do nothing with the unique and vision mode will show it as green- junk : Mark any uniques that don't match any filters as junk and show as red in vision mode |
run_vision_mode_on_startup | If the vision mode should automatically start when starting d4lf. Otherwise has to be started manually with the vision button or the hotkey |
check_chest_tabs | Which chest tabs will be checked and filtered for items in case chest is open when starting the filter. You need to buy all slots. Counting is done left to right. E.g. 1,2,4 will check tab 1, tab 2, tab 4 |
move_to_inv_item_type move_to_stash_item_type |
Which types of items to move when using fast move functionality. Will only affect tabs defined in check_chest_tabs. You can select more than one option. - favorites : Move favorites only - junk : Move junk only - unmarked : Only items not marked as favorite or junk - everything : Move everything |
mark_as_favorite | Whether to favorite matched items or not. Defaults to true |
minimum_overlay_font_size | The minimum font size for the vision overlay, specifically the green text that shows which filter(s) are matching. Note: For small profile names, the font may actually be larger than this size but will never go below this size. |
hidden_transparency | The overlay will become transparent after not hovering it for a while. This can be changed by specifying any value between [0, 1] with 0 being completely invisible and 1 completely visible |
browser | Which browser to use to get builds, please make sure you pick an installed browser: chrome, edge or firefox are currently supported |
full_dump | When using the import build feature, whether to use the full dump (e.g. contains all filter items) or not |
[char] | Description |
---|---|
inventory | Your hotkey for opening inventory |
[advanced_options] | Description |
---|---|
move_to_inv | Hotkey for moving items from stash to inventory |
move_to_chest | Hotkey for moving items from inventory to stash |
run_scripts | Hotkey to start/stop vision mode |
run_filter | Hotkey to start/stop filtering items |
run_filter_force_refresh | Hotkey to start/stop filtering items with a force refresh. All item statuses will be reset |
force_refresh_only | Hotkey to reset all item statuses without running a filter after |
exit_key | Hotkey to exit d4lf.exe |
log_level | Logging level. Can be any of [debug, info, warning, error, critical] |
scripts | Running different scripts |
process_name | Process name of the D4 app. Defaults to "Diablo IV.exe". In case of using some remote play this might need to be adapted |
vision_mode_only | If set to true, only the vision mode will be available. All functionality that clicks the screen is disabled. |
Documentation is not yet finished. For now, it should be self-explanatory. Just start gui.bat
in the archive.
Current functionality:
Each tab gives further instructions on how to use it and what kind of input it expects.
All profiles define whitelist filters. If no filter included in your profiles matches the item, it will be discarded.
Your config files will be validated on startup and will prevent the program from starting if the structure or syntax is incorrect. The error message will provide hints about the specific problem.
The following sections will explain each type of filter that you can specify in your profiles. How you define them in
your YAML files is up to you; you can put all of these into just one file or have a dedicated file for each type of
filter, or even split the same type of filter over multiple files. Ultimately, all profiles specified in
your params.ini
will be used to determine if an item should be kept. If one of the profiles wants to keep the item, it
will be kept regardless of the other profiles. Similarly, if a filter is missing in all profiles (e.g., there is
no Sigils
section in any profile), all corresponding items (in this case, sigils) will be kept.
You have three choices on how to specify aspects or affixes of an item:
[NAME, THRESHOLD, CONDITION]
. The
condition can be any of [larger, smaller]
and defaults to larger
if no value is given.{name: dexterity, value: 33, comparison: larger}
. This is completely interchangeable
with the shorthand notation.As we recommend using the importer for a base version of your build, even if you intend to then manually create your own build, the examples below will use the same format as the importer.
Affixes are defined by the top-level key Affixes
. It contains a list of filters that you want to apply. Each filter
has a name and can filter for any combination of the following:
itemType
: The name of the type or a list of multiple types.
See assets/lang/enUS/item_types.jsonminPower
: Minimum item powerminGreaterAffixCount
: Minimum number of greater affixes. Note that this is on the overall item and independent
of affixPool
affixPool
: A list of multiple different rulesets to filter for. Each ruleset must be fulfilled or the item is
discarded
count
: Define a list of affixes (see syntax) and
optionally minCount
, maxCount
and minGreaterAffixCount
minCount
: specifies the minimum number of affixes that must match the item. defaults to amount of specified
affixesmaxCount
specifies the maximum number of affixes that must match the item. defaults to amount of specified
affixesminGreaterAffixCount
: specifies the minimum number of greater affixes inside this count group. defaults
to 0
inherentPool
: The same rules as for affixPool
apply, but this is evaluated against the inherent affixes of the
itemAffix names are lower case and spaces are replaced by underscore. You can find the full list of names in assets/lang/enUS/affixes.json.
Sigils are defined by the top-level key Sigils
. It contains a list of affix or location names that you want to filter
for. If no Sigil filter is provided, all Sigils will be kept.
Sigil affixes and location names are lower case and spaces are replaced by underscore. You can find the full list of names in assets/lang/enUS/sigils.json.
Uniques are defined by the top-level key Uniques
. It contains a list of parameters that you want to filter for. If no
Unique filter is provided, uniques will be handled according to the handle_uniques configuration. All mythics are
marked as favorite regardless of any filter or configuration.
Uniques can be filtered in two ways. First the aspect and affix for a specific unique can be filtered directly. This is how imported profiles are configured. If only aspect filtering is applied, then all other uniques will be handled according to the handle_uniques property. For aspect filtering, since uniques all have a predefined affix, you'll only need to specify the threshold that you want to apply (see examples below).
Additionally, you can filter all uniques based on a generic property like their item power or if they have greater affixes. Once a "global" filter like this is applied then all uniques will have a filter that now applies to them and handle_uniques will be ignored.
In vision mode, uniques show as
Unique names are lower case and spaces are replaced by underscore. You can find the full list of names in assets/lang/enUS/uniques.json.
Conda setup:
git clone https://github.com/aeon0/d4lf
cd d4lf
conda env create -f environment.yml
conda activate d4lf
python -m src.main
Python setup (windows, linux venv activation differs):
git clone https://github.com/aeon0/d4lf
cd d4lf
python -m venv venv
venv\Scripts\activate
python -m pip install -r requirements.txt
python -m src.main
Ruff is used for linting and auto formatting. You can run it with:
ruff format
ruff check
Setup VS Code by using the ruff extension. Also turn on "trim trailing whitespaces" is VS Code settings.