Daily Deeds
Customizing Daily Deeds
Nothing below is actually a part of KoLmafia yet. It requires a patch posted on the forum here. I just wanted to put this information in a place where I could find it easily.
All deeds are specified by one comma-delimited preference "dailyDeedsOptions". Order matters. Built-in deeds are simply called by referring to their built-in name; these are viewable by pulling up the Daily Deeds tab and looking in the "Built-in Deeds" list. In the source code these can be found in DailyDeedsPanel.BUILTIN_DEEDS.
Custom deeds provide the user with a way of adding buttons or text to their daily deeds panel that is not natively provided for. All deeds start with the keyword $CUSTOM followed by a pipe symbol, |. As you are constructing a custom deed, you separate the different arguments with pipes.
All deed types except for Text require a preference to track. If you want to add a button that is always enabled, you will have to create a dummy preference that is always false.
There are currently 5 different types of custom deeds. Remember that all of these "acceptable forms" are prefaced by $CUSTOM|.
BooleanPref
one-a-day deed
acceptable forms: BooleanPref|displayText|preference BooleanPref|displayText|preference|command
displayText - the text that will be displayed on the button preference - the boolean preference to track. The button will be enabled when the preference is false, and disabled when the preference is true. command (optional) - the command to execute. If not specified, will default to displayText.
MultiPref
n-times-a-day deed
acceptable forms: BooleanPref|displayText|preference|command|maxUses
- preference - the integer preference to track. The button will be enabled when preference < maxUses.
- maxUses - an arbitrary integer. Specifies a threshold to disable the button at. A counter in the form of <preference>/<maxUses> will be displayed to the right of the button.
BooleanItem
this button will use fuzzy matching to find the name of the item specified. Will execute "use <itemName>" when clicked. Will only be visible when you possess one or more of the item.
acceptable forms: BooleanItem|displayText|preference BooleanItem|displayText|preference|itemName
- itemName - the name of the item that will be used. If not specified, will default to displayText.
Skill
cast a skill that is tracked by a boolean or int preference. Will execute "cast <skillName>" when clicked.
acceptable forms: Skill|displayText|preference Skill|displayText|preference|skillName Skill|displayText|preference|skillName|maxCasts
- preference - a boolean preference if the 3- or 4-argument version is used, or an integer preference if the 5-argument version is used.
- skillName- the name of the skill that will be cast. If not specified, will default to displayText. Must be specified if maxCasts are specified.
- maxCasts - an arbitrary integer. Specifies a threshold to disable the button at. A counter in the form of <preference>/<maxCasts> will be displayed to the right of the button.
Text
acceptable forms: Text|pretty much anything.
You can supply as many arguments as you want to a Text deed. Any argument that uniquely matches a preference will be replaced by that preference's value. If you want to use a comma in your text, immediately follow the comma with a pipe character so it will not be parsed as the end of the Text deed.