Page 1 of 1

WorldFilter - Addon to filter world/trade channel by keyword

PostPosted: Sat Sep 26, 2015 1:29 am
by Two
If you are tired of the constant spam in world/trade for instances and you only want to go specific ones, this is the addon for you. It allows to filter world/trade by keyword, so if i.E. you only want Strat living, add it as a filter and only requests for that instance are shown.

Download: https://github.com/twothe/WorldFilter

Usage:

/wf (prints help)
/wf add <keyword> (adds a new keyword to the list)
/wf del <keyword> (removes that keyword from the list)
/wf list (list all keywords currently on the list)
/wf on (enables this addon)
/wf off (disables this addon)

All variables are saved per character.

The filter is a white-list, so only what is on the list is shown. If you have nothing on the list the entire channel will be blocked. Since this is the default when this addon is loaded for the first time, don't be afraid if the channel is suddenly so silent, just add something or use /wf off to disable the addon for the moment. If you add multiple keywords (like Strat, DM, UBRS) then all chat lines containing at least one of those words will be shown.

All keywords are case sensitive and treated as regular expressions!

If you don't know what regular expressions are, just add the standard names of the instances (DM, Strat, ...) and don't worry about it. If you know what those are, then you can do all kinds of fancy stuff with it.

Examples:
/wf add Scholo (show all lines that contain 'Scholo')
/wf add Strat.*UD (show everything that starts with 'Strat' and is eventually followed by 'UD')
/wf add DM.[wWeE] (show all Diremaul lines that are followed by W or N, e.g DM:W)
/wf add LF.?M (show everyone that is looking for more, like 'LFM' or 'LF3M')

Re: WorldFilter - Addon to filter world/trade channel by key

PostPosted: Sat Sep 26, 2015 6:58 am
by Aunstic
I love it. I was about to suggest the keywords be channel-bound until I looked at the source and seen
Code: Select all
          if ((channel == "world") or (channel == "trade")) then

Re: WorldFilter - Addon to filter world/trade channel by key

PostPosted: Sat Sep 26, 2015 11:07 am
by Two
Yeah I was thinking about that but too lazy to implement that for now. Might come in a future version. ;)

For the moment just turn off the WorldFilter if you want to trade something.

Re: WorldFilter - Addon to filter world/trade channel by key

PostPosted: Sat Sep 26, 2015 5:47 pm
by Drunkwizzard
Oi !

Can you reverse your addon to black list spam messages on trade/world ? You know... globlin money and illidan 73

This would be awesome!

Re: WorldFilter - Addon to filter world/trade channel by key

PostPosted: Mon Sep 28, 2015 12:16 am
by Two
Reversing to a black-list is very simple, but finding good keywords that filter out money spam is very difficult. If you have easy keywords, the Nos team for sure would implement those right away.

Re: WorldFilter - Addon to filter world/trade channel by key

PostPosted: Mon Sep 28, 2015 12:23 am
by Aunstic
Drunkwizzard wrote:Oi !

Can you reverse your addon to black list spam messages on trade/world ? You know... globlin money and illidan 73

This would be awesome!

SpamThrottle is the blacklist version of this: https://forum.nostalrius.org/viewtopic.php?f=63&t=5350
If you don't know regex, you can use both WorldFilter and SpamThrottle to filter your whitelist. Just a thought.

Re: WorldFilter - Addon to filter world/trade channel by key

PostPosted: Tue Jan 12, 2016 3:45 pm
by Ourk
Tyvm Two, my life is easier with your addon.

/love & /bow

Re: WorldFilter - Addon to filter world/trade channel by key

PostPosted: Wed Jan 13, 2016 9:54 pm
by RedBanner
Two wrote:/wf add DM.[wWeE] (show all Diremaul lines that are followed by W or N, e.g DM:W)


I'll just end up getting messages about Deadmines.

"What's VC?" Go back to pandaland.

Re: WorldFilter - Addon to filter world/trade channel by key

PostPosted: Thu Jan 14, 2016 5:18 am
by Finrodi
I would love if it would be the other way around so I could just block specific words and not show the message at all. According Aunstic SpamThrottle should do exactly this but it is not working for me and even if it would be, I'd have to disable Prat which would suck. I quickly looked over the code but am still not 100% sure how I could reverse the function so I see all messages but the ones which I filtered. Would appreciate any help!