Block Those Stars! |
||
|
Block those stars!
A friend asked about this so here is the simple explaination:
You will need to download Notepad++ probably (or at least I did) to make a .lua, unless I'm stupid. Asura.Eiryl said: » make a new folder (I called it stars, obviously) Copy paste [the code below] onto note++ save as Stars.lua Drop it in the new file, drop file in add-ons //lua load stars (then add stars to the init text so that its always on) and then: Asura.Chiaia said: » Here's a quick and dirty addon that's more like Masunasu's but actually only checks the incoming chat packet, has some modes added, and is easier to add other strings. Code _addon.name = '***' _addon.version = '0.10' _addon.author = 'Chiaia (Asura)' _addon.commands = {'***','fo'} --Won't do anything atm. packets = require('packets') local blackListedUsers = T{'TotallyABotOne','TotallyABotTwo','TotallyABotThree',} -- Want to block all messages from X user then added there name(s) here. -- I could do a general digit check on JP instead of set 500/2100 values but atm I feel it's not needed. Will see if they change thier tactics. -- If you want to learn more about "Magical Characters" or Patterns in Lua: https://riptutorial.com/lua/example/20315/lua-pattern-matching local blackListedWords = T{string.char(0x81,0x99),string.char(0x81,0x9A),'1%-99','Job Point.*2100','Job Point.*500','JP.*2100','JP.*500','Capacity Point.*2100','Capacity Point.*500','CP.*2100','CP.*500',} -- First two are '☆' and '★' symbols. windower.register_event('incoming chunk', function(id,data) if id == 0x017 then -- 0x017 Is incoming chat. local chat = packets.parse('incoming', data) local cleaned = windower.convert_auto_trans(chat['Message']):lower() if blackListedUsers:contains(chat['Sender Name']) then -- Blocks any message from X user in any chat mode. return true elseif (chat['Mode'] == 3 or chat['Mode'] == 1 or chat['Mode'] == 26) then -- RMT checks in tell, shouts, and yells. Years ago they use to use tells to be more stealthy about gil selling. for k,v in ipairs(blackListedWords) do if cleaned:match(v:lower()) then return true end end end end end) The guy running Hqsupermarket is as bad as the god damn RMT. And now there's a second one. and he does it from Svein too.
[00:57:05] Hqsupermarket : [00:57:06] Hqforyou : [00:57:59] Hqsupermarket : [00:58:07] Hqforyou : [01:03:30] Hqforyou : [01:03:39] Hqsupermarket : [01:06:45] Hqsupermarket : [01:11:34] Hqsupermarket : [01:12:21] Hqforyou : [01:12:48] Hqsupermarket : [01:13:26] Hqforyou : Jesus *** I'm glad I put momma(mom mama moma mother) in my list of blocked words
"Flat Earth" lol, only on Asura.
Offline
Posts: 173
Sylph.Cossack said: » "Flat Earth" lol, only on Asura. Asura.Dexterm said: » And man lived among the dinosaurs. L O L.
Necro Bump Detected!
[66 days between previous and next post]
This should never be necro, but... I'll revive with some new questions.
So I nicknamed the thing stars.lua and put it in the add-ons folder in a folder names "stars". Any idea where I would add a line to auto-load it because I must have mucked up somewhere. I just have to type: //lua load stars every time I have my character logged in. It works when I do that. It lasts an entire playthrough, but I have to do it ever time. I'm sure I'm just dumb with .lua stuff and could use a hand-hold. Thanks. So in addition to the above stuff, can anyone add something to catch the auto-translated word "ballista" (because seriously *** that spam) and whatever this person is saying that is getting through as well, please: I was trying to add "buy?99" and "ballista" into that code in the spoiler'd text in my last post using notepad++ and saving it as a .lua. When I try to load it in windower, the message I get is:
stars: Lua syntax error: stars/stars.lua:1: unexpected symbol near '?' and the '?' at the end is a question mark in a box (not the question mark plainly like I put there. It seems to have ruined the .lua somehow. I remove everything I entered and save it, then try to load it, and still get the error. I make an entirely new .lua with the copy-pasted code from my post above and it works. Thoughts or help, please? I'm a lua n00b. I just want a code to block out all the stupid JP sellers and ballista spammers on Asura. I can handle the ***-talking. The spammers just gots-ta-go. Thanks in advance. Offline
Posts: 218
local blackListedWords = T{string.char(0x81,0x99),string.char(0x81,0x9A),'Job Points', 'Faster', 'kill', 'Kill', 'Fast Cast', 'Shop', 'shop', 'delivery', 'Midle-man', 'Stock', 'stock', '1%-99', 'Job Point.*2100', 'job points', 'Buy?', 'Job Point.*500', 'JP.*2100', 'JP.*500', 'Capacity Point.*2100', 'Capacity Point.*500', 'CP.*2100', 'CP.*500', '★', '★★', '★★★', '★ ', '★★ ', '★★★ ', 'save', 'Save', 'buy?99', 'ballista' -- First two are '☆' and '★' symbols.
Enjoy a Quiet world ( ps: i got cp mastered all job, so you can delete cp if you still need it )
Necro Bump Detected!
[34 days between previous and next post]
Offline
Posts: 5
I'm trying to add multiple names to the BlackListUsers section, but I can't get it to work when I add more than one.
Code if blackListedUsers:contains(chat['PLAYERNAME']) then -- Blocks any message from X user in any chat mode. return true Where PLAYERNAME is, I tried to add names with a comma, without comma, etc but I get an error: " ' expected near ' , ' " What am I doing wrong here? That line should read as:
Code if blackListedUsers:contains(chat['Sender Name']) then -- Blocks any message from X user in any chat mode. return true You don't edit that line for blocking users. That's where it compares blocked users to the person who sent the message and see if it should block it. You change: Code local blackListedUsers = T{'TotallyABotOne','TotallyABotTwo','TotallyABotThree',} -- Want to block all messages from X user then added there name(s) here. Still one of the most important things for trying to remain sane on Asura through the JP bot selling yell spam from multiple different yellers. Bumping for that reason.
This has probably already been said, but why not just turn off yells?
Necro Bump Detected!
[79 days between previous and next post]
Bumping for great justice.
(and because some people don't know this exists). Offline
Posts: 697
Asura.Chiaia said: » Here's a quick and dirty addon that's more like Masunasu's but actually only checks the incoming chat packet, has some modes added, and is easier to add other strings. Code _addon.name = '***' _addon.version = '0.10' _addon.author = 'Chiaia (Asura)' _addon.commands = {'***','fo'} --Won't do anything atm. packets = require('packets') local blackListedUsers = T{'TotallyABotOne','TotallyABotTwo','TotallyABotThree',} -- Want to block all messages from X user then added there name(s) here. -- I could do a general digit check on JP instead of set 500/2100 values but atm I feel it's not needed. Will see if they change thier tactics. -- If you want to learn more about "Magical Characters" or Patterns in Lua: https://riptutorial.com/lua/example/20315/lua-pattern-matching local blackListedWords = T{string.char(0x81,0x99),string.char(0x81,0x9A),'1%-99','Job Point.*2100','Job Point.*500','JP.*2100','JP.*500','Capacity Point.*2100','Capacity Point.*500','CP.*2100','CP.*500',} -- First two are '☆' and '★' symbols. windower.register_event('incoming chunk', function(id,data) if id == 0x017 then -- 0x017 Is incoming chat. local chat = packets.parse('incoming', data) local cleaned = windower.convert_auto_trans(chat['Message']):lower() if blackListedUsers:contains(chat['Sender Name']) then -- Blocks any message from X user in any chat mode. return true elseif (chat['Mode'] == 3 or chat['Mode'] == 1 or chat['Mode'] == 26) then -- RMT checks in tell, shouts, and yells. Years ago they use to use tells to be more stealthy about gil selling. for k,v in ipairs(blackListedWords) do if cleaned:match(v:lower()) then return true end end end end end) Yeah. Yell is still cancer if you don't block out the JP vendors. Thankfully, they normally stick to the same players to yell so you could just blacklist them, but unfortunately the blacklist has to load every time you zone so messages will still get through unless you use the above code or block yell entirely.
You'd miss on those sweet Sarameya shouts, better use the addon.
Adding "Discord" to my list because like I want to listen to a bunch of other FFXI players with bad mics try to organize Ambuscade runs for their job that isn't geared nor suitable for VDV1 or to hear players beg people to come to do dead content (Ballista) with them.
Only if we can have a Bibiki Bay Clamming event!
|
|
All FFXI content and images © 2002-2024 SQUARE ENIX CO., LTD. FINAL
FANTASY is a registered trademark of Square Enix Co., Ltd.
|