Skip to content
kahlen-tech edited this page Oct 4, 2026 · 2 revisions

Description

Rewrites the game's item lists into tidy, sorted categories. When you look in a container, rummage, check your inventory or look at someone, sorter shows the items grouped by type (clothing, containers, weapons, gems, herbs and so on), counts duplicates, and lists each group alphabetically.

It runs in the background and changes nothing in game; it only changes what you see. Most people start it automatically when they log in.

It's hidden from your running-scripts list. Stop it with ;kill sorter.
Inventory Manager stops sorter while it reads your containers, and starts it again afterwards.

Settings

YAML Settings

sorter:
  width: 0
  mute_old_inventory: true
  sort_inv_command: true
  sort_look_others: true
  sort_look_items_command: true
  ignore_categories: lootables|trash

If you add a sorter: block to your yaml, include every key. Your block replaces the default one completely, and any key you leave out counts as off. For example, a block with only width: stops the original lines being hidden and stops inventory and look sorting. An empty sorter: is the same as leaving every key out.

Setting Default Purpose
width 0 0: each category is one line, items separated by commas. Above 0: items are laid out in columns to fit this many characters. In Stormfront this uses a monospaced font.
mute_old_inventory true Hide the game's original line, so you only see the sorted version. With false you see both.
sort_inv_command true Also sort INVENTORY ("You are wearing...").
sort_look_others true Also sort what other people are wearing when you look at them ("He is wearing..." or "She is wearing...").
sort_look_items_command true Also sort "You take a moment to look for all the items in the area and see...".
ignore_categories lootables|trash Categories not to use, as a regular expression matched against category names. An item that would go in an ignored category goes in the next category that fits, or in "other". The current data file has no categories with these names, so by default nothing is ignored.

Container lists ("In the ... you see", "On the ... you see") and RUMMAGE are always sorted. If you turn off one of the sort_ settings, that list is shown as the game sends it.

Categories

  • The categories and the item names and nouns in them come from data/base-sorting.yaml. Gem and scroll nouns come from data/base-items.yaml.
  • Each item goes in the first category it matches, by its noun or its name without flavor text. Anything that matches nothing goes in "other". Creatures (shown bold by the game) go in "NPC".
  • Categories, and the items in each, are listed alphabetically by their last word. Duplicates are shown once with a count, for example blunt stones (3).
  • To change categories, copy data/base-sorting.yaml to data/custom/base-sorting.yaml and edit the copy (this needs a recent Lich 5). The custom file replaces the shipped one completely, so you'll need to copy over future updates yourself.

Troubleshooting

To see the name, noun and category it uses for every item it sorts, turn on debug output:

;e UserVars.sorter_debug = 'true'

Turn it off again with ;e UserVars.sorter_debug = nil.

Bold category names show in Stormfront and Profanity. Other front ends get plain text.

Argument Settings

There are no arguments.

Usage

;sorter

Leave it running. To have it start every time you log in, add it to your Lich autostart.

Clone this wiki locally