View Single Post
06/17/20, 08:00 AM   #3
remosito
AddOn Author - Click to view addons
Join Date: Dec 2019
Posts: 30
Originally Posted by Baertram View Post

Code:
(random( 0..x) seconds to avoid 50 parallel zone chat announcments by different players with addon)
(x might have to be sufficiently high, zone chat lags sometimes)
I'd rather listen to chat message event and if any message about the same HS was broadcasted in the same zone chat in the last x seconds forget your broadcast at all -> supress it.
Else you still get the chat spam by 20+ addon users within a few secons which will be makign A LOT of the players mad that woudl like to use teh chat for other searches (mobs, bosses, qeusts) as well
What you are describing is what I meant with: "if none have been detected in the meantime"

the 0..x random delay is to prevent message spam from 3 players with addon that have just been waiting there. Harrowstorm goes up. They are all very fast at reacting and attacking. All three detect its happening and broadcast because it all happened before any broadcast by one player to zone chat would have even been received by other players with addon due to chat lag.

The random wait makes it so ideally player 1 gets short wait say 0.5 seconds...player 2 gets medium wait say 3 seconds and player 3 gets long wait of 9.7 seconds.

If chat lag is 2 seconds, then player 2 and 3 receive player 1's announcement in time and dont broadcast.

Without random delay all three would have broadcast....

Obviously rng is a harsh mistress and chances are that at least two players would have gotten delays within "chat lag" seconds of each other and will all broadcast anyway.

But in general would cut down on multiple broadcasts quite a bit....

a kindom for a hidden addon channel for addons to communicate with each other....

Last edited by remosito : 06/17/20 at 08:03 AM.
  Reply With Quote