Demonhighlighter: A game agnostic highlighter

Share your scripts and packages with other Mudlet users.
Post Reply
User avatar
demonnic
Posts: 773
Joined: Sat Dec 05, 2009 3:19 pm

Demonhighlighter: A game agnostic highlighter

Post by demonnic »

https://github.com/demonnic/Highlighter/releases
Includes aliases you can use to control it, but also has functions so you can add things in triggers/etc. Make as many highlighter categories as you want, each with their own configuration. Has fg, bg, bold, underline, italics options, and the ability to pause all highlighting or just specific categories of highlighting. Any given highlight item can only belong to one category at a time, so if you add it to another it will remove from the old one and add to the new one.

The readme at https://github.com/demonnic/Highlighter has full information on the aliases and API involved.

Code: Select all

hl cat add enemy#fg = "red", bold = true

Code: Select all

hl item add enemy#Bob
your nemesis Bob better beware

Code: Select all

Highlighter:addCategory("quest items", {fg = "purple", italics = true})

Code: Select all

Highlighter:add("a rotting pumpkin", "quest items")
need to finish that Halloween event, yo

Code: Select all

hl item remove a rotting pumpkin
but now it's over

Code: Select all

hl item add friend#Bob
you finally repair your relationship with Bob, huzzah!

User avatar
demonnic
Posts: 773
Joined: Sat Dec 05, 2009 3:19 pm

Re: Demonhighlighter: A game agnostic highlighter

Post by demonnic »

Highlighter 1.1.0 released <https://github.com/demonnic/Highlighter ... tag/v1.1.0> Now includes functions to highlight strings for use in c/d/hecho.
Screenshot shows raw decho, decho with highlights, and dfeedTriggers to show it highlighted from the server.
Code: [show] | [select all] lua
decho(str)
decho(Highlighter:dhighlight(str))
dfeedTriggers(str)
If you use a background color in your highlight it will bleed over under certain circumstances, see the release post for more info.
unknown.png

User avatar
demonnic
Posts: 773
Joined: Sat Dec 05, 2009 3:19 pm

Re: Demonhighlighter: A game agnostic highlighter

Post by demonnic »

1.2.0 released, now adds right-click menu options for interacting with the Highlighter to add and remove selected text from the Highlighter.
https://github.com/demonnic/Highlighter ... tag/v1.2.0


Image

Post Reply