Thread Tools Display Modes
05/20/14, 10:04 AM   #1
zgrssd
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 280
Addons Communicating Guildwide via Member Notes?

It is general knowledge that addons running on different clients cannot communicate with one another effectively.
While they can send mail (1/5 seconds due to spam protection), this is not very fast.
While they could easily parse chat messages, the top they can do with the chat sending is prepare a message for you that you have to commit via enter or write soemthing that only appears on your client (d() or CHAT_SYSTEM:AddMessage).

But recently somebody asked if we could make a Guild Callendar Addon. And I noticed something:
Addons can communicate to some degree via the Guild Member Notes!
Specifically SetGuildMemberNote(integer guildId, luaindex memberIndex, string note) is totally allowed (there is no indication this is private, propably because one needs to have an addon to parse the events to even notice chagnes there)

There is also an Event Called EVENT_GUILD_MEMBER_NOTE_CHANGED, but the arguments are not fully known (so I cannot say if it would get Changed Member Nots of other users). If not, a polling approach might be feasible (check one member every X MS, start from beginnign ocne you reached end).

We would need a way to serialise & deserilaise the data, wich is not that hard.

We would need to know what exactly the Character limit for Member notes are.
Edit: Tested it. The Textbox to enter only allows 254 Characters. It is likely to be the limit of the Database too, but testing if direct set can exceed this limit won't hurt.

Optionally, the Addons should only affect the member note after a certain "#tag" one puts in the note. That way normal use data (what you normally write there) could stay around, leaving only stuff past a certain Threshold to be used for sending/receving).

Unfortunately I still have to finish my first Addon or risk it becomming an eternal work in Progress. But if anybody else would want to figure out if my Theory works (or has already used it), I would appreciate results.

Last edited by zgrssd : 05/21/14 at 07:35 AM.
  Reply With Quote
05/21/14, 07:50 AM   #2
zgrssd
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 280
More thoughts. First we need a name for this.
How about the MoGMN-Protocol? "Multicast over Guild Member Notes".

I think we would need two versions:
1) This one is limited to one Notes size. It's usefull for normal guild members that want to put in some announcement that can be auto-parsed by other addons.

2) This version is designed to split large messages over multiple notes, so the 254 Character Limit is not so much of a problem. It's designed for higher ups in the ranks that have the right to set Member Notes of other Members in addition to thier own. That way up too 500 * 200 Characters large Messages would be quite feasible.
On the Sender side this one would have to deal with issues like packages vanishing (members leaving or changing thier Note), becomming incomplete (someone needs more of thier Note Space for thier own message) and generally uncertain amount of data/Note (you might have 240 Characters after the headers, or only 20). On the receiver side there must be a way to differentiate between the packages of different messages.
Ideally members should be able to "opt in" for this. i.e. they put the proper Tag into thier notes, and the addon only writes to those who have been tagged (and only as much as the tag position allows).
  Reply With Quote
05/21/14, 09:53 AM   #3
thelegendaryof
 
thelegendaryof's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 161
However one would need to think about the compression/type of data to be send/recv first and foremost i'd say ...
(I'm not really good with that so every input is welcome)

That 's the most promising info I've found:

http://encode.ru/threads/449-Most-ef...ull=1#post9112

As in creating a dictionary of function that are mapped to Strings/ID as short as possible.

HM! Maybe abusing Links will help us working around that Character Limit ... are Links in Notes supported?

Edit: Yes Itemlinks are support that actually pretty great as their Data isn't counted towards the Characterlimit!

Edit 2: Sadly in that case it is , however I think Links are probably the best way to send Addon-Data
without bothering regular Members to much as the Data attached is hidden from the Eye.

Structured like that:

|HFF0000:ADDON_ID:TYPE:FUNCTION:PARAMETER1:PARAMETER2:...|h[MoGMN]|h
Example Pseudocode:

Lua Code:
  1. function SendData(ADDON_ID, TYPE, FUNCID, ...)
  2.     local aid = compress_id(ADDON_ID) -- first letter + lastletter + id in case someone else uses the same name
  3.     local data =  '|HFF0000:'
  4.     data = data..tostring(aid)..':'
  5.     data = data..tostring(TYPE)..':'
  6.     data = data..tostring(FUNCID)
  7.  
  8.     for i,v in ipairs(arg) do
  9.         local arg = compress_arg(v) -- hm not sure how to compress those
  10.         data = data..':'..tostring(arg)
  11.     end
  12.  
  13.     data = data..'|h[MoGMN]|h'
  14. end
  15.  
  16. SendData("HERPERTS_ADDON", 1, 5, "123 GOLD") -- GENERATES: |HFF0000:HN0:1:5:123GOLD|h[MoGMN]|h

Maybe something like this for compressing strings:

http://stackoverflow.com/a/3649531

One could also use that to send Links in Chat to others that have an Addon
and for example Automatically open their Map and point them to the Location.

I'm just not sure if Zenimax likes that and will not just disable that API-Function if they get knowledge of the way it 's used :/ ...

Edit 29058725798:

The Note is actually an Edit-Field that can take as much as 1060 Characters
however like you suspected only 254 of them are actually saved upon
writing it to the Database (tested and confirmed by myself).

Last edited by thelegendaryof : 05/21/14 at 11:09 AM.
  Reply With Quote
05/21/14, 11:51 AM   #4
Tar000un
 
Tar000un's Avatar
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 47
One of the simpliest i see, is to create a dictionnary.

For numerical data, it's possible to rewrite them in base32hex.

But the other problem is see is the multiple access : who write and when ? Assuming two addon want to write the player's guildnote to communicate with a guildmate's addon, an error may occur.

In the other hand, how often is possible to write the guildnote ?
  Reply With Quote
05/21/14, 12:29 PM   #5
thelegendaryof
 
thelegendaryof's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 161
Seems to be time-gated as well - kicks you if it 's writen to often per minute (Error 318)
  Reply With Quote
05/21/14, 02:04 PM   #6
CrazyDutchGuy
 
CrazyDutchGuy's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 89
Please don't abuse objects that are not intended for heavy communication. I agree that we would like an option to have addons communicate with each other, but using guild notes is just not right imo.
  Reply With Quote
05/21/14, 02:14 PM   #7
thelegendaryof
 
thelegendaryof's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 161
Originally Posted by CrazyDutchGuy View Post
Please don't abuse objects that are not intended for heavy communication.
By that logic humanity would still live in caves because there was probably always someone saying that it 's not intended to be used that way like that stone is made to be used lying around not using it as a wheel...

Question is if there is nothing else what else should one do instead of sitting still and doing nothing? waiting? And dont call for realism. Without optimism and just trying something even if it fails and doesnt work nothing would be moving forward ... some people solve problems others come and complain - you have a choice to make what you want to be so better choose wisely.

I personally am rather called a retard after I'm done what I could rather before so.

Btw. can't be abused as it drops you faster then you could think if you try to do that -
question is how to intelligently use it - and for what purpose.

Last edited by thelegendaryof : 05/21/14 at 02:25 PM.
  Reply With Quote
05/21/14, 02:26 PM   #8
CrazyDutchGuy
 
CrazyDutchGuy's Avatar
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 89
The object is not made for the kind of work you want to do with it.

Addon communication between players should just be build in in a way like the chat system works, but then with hidden channels.

It may work somehow for a Guild Calendat, but if you going to use it to sync large amounts of data, then just don't use it. It doesn't buffer, doesn't have locking, forces player to poll the UI constantly, it's just bad to use it, and forces eso to lock down controls even more.
  Reply With Quote
05/21/14, 06:06 PM   #9
thelegendaryof
 
thelegendaryof's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 161
I totaly agree that a proper solution would be a communication API. However they even removed sending Chat-Messages programmatically from addons in addition to limiting the BrowserControl to preset internal pages. That 's only sh*t for legit Addon-Developers as every Mother and their Kid can write an simple AutoIT-Script that just does that chat-spamming and even more (and it 's not even like professional Goldsellers are using the API for that to begin with).

Meaning I wouldn't hold my breath for that for a long time (however wonders might happen - seeing that they didn't even respond in 2 months to the request ESOUI made for releasing the official UI here makes me rather think the opposite).

However sending hidden Chat-Messages would be another way - BUT - if a user doesn't have that Addon it would be even more intruding as they get spammed by messages they don't want to see. At least in the Guild Notice no one is getting any Notification of it.

Technically both can't be spammed as they have a limit just how much you can spam/send before you get kicked.
So of course it would only have a technically AND ethically limited usage - that 's for sure.

Last edited by thelegendaryof : 05/21/14 at 06:17 PM.
  Reply With Quote
05/21/14, 06:39 PM   #10
Halja
 
Halja's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 111
Don't hold your breath on custom chat channels ever coming back. With tomorrow's patch, the deprecated functions like IsInCustomChatChannel, JoinChatChannel, and LeaveChatChannel are removed completely from the API.

Oh, open chat channel message size limit drops to 350 characters too.
--halja
  Reply With Quote
05/21/14, 06:42 PM   #11
thelegendaryof
 
thelegendaryof's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 161
Originally Posted by Halja View Post
Don't hold your breath on custom chat channels ever coming back. With tomorrow's patch, the deprecated functions like IsInCustomChatChannel, JoinChatChannel, and LeaveChatChannel are removed completely from the API.

Oh, open chat channel message size limit drops to 350 characters too.
--halja
Not that I expected otherwise ...

Where do you have your info from Halja? Do you have PTS-Access? Any other changes (especially strips) coming?

Last edited by thelegendaryof : 05/21/14 at 06:47 PM.
  Reply With Quote
05/21/14, 06:53 PM   #12
Halja
 
Halja's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 111
Yea, this major patch coming has had couple small iterations on PTS. ZOS will consolidate the change log to one posting for all tomorrow. They did add things to the API like additional events. The new DeathRecap API is interesting. So, it not all negative on that front.
--halja
  Reply With Quote
05/22/14, 06:21 AM   #13
zgrssd
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 280
Originally Posted by CrazyDutchGuy View Post
Please don't abuse objects that are not intended for heavy communication. I agree that we would like an option to have addons communicate with each other, but using guild notes is just not right imo.
I am a Programmer of many languages (Lua is my 7th). For me there are only concepts. Each language and environment is more or less suiteable for certain concepts.
And I am just trying to figure out the limits for this concept (interclient communication) in this environment (ESO). And maybe push them a bit.

Originally Posted by CrazyDutchGuy View Post
Addon communication between players should just be build in in a way like the chat system works, but then with hidden channels.
Having Channels that the normal user cannot see (and only addons care for) would be ideal*. As the user would not normally see what is comming over there (unless he has an addon that listens to it and informs him), it's useability for spam would be limited based on the number of people who have listening addons (and if you can even send random Strings over it; most of the times I would just send numbers).
The thing is that those messages could easily get out of hand. We only see what is happening in our Local Zone chat (plus maybe say and yell), our group and our guilds. But the load for the IRC Server behind this must be enourmous. Allowing addons to communicate that way might be not feasible within the resource constraints of a MMO. Maybe they reintroduce something like this when they do not need so many resources for bug fixing. We should ask them again 6 Months after launch.

*That is perhaps the same reason Addons still can write member notes - you actually need a addon that registers the Change Event and notifies you of every change before it could even be used for Spamming you. And if you have to install an addon to even have a problem then it is your own fault for installing it.


Actuall Planning work:
Naturally we have to avoid Strings in the G-Note as much as possible. They just need way too much space for thier data.
If we can identify things via a number it would be very easy. We can send arbitrary data over a String based medium using Base64 encoding. It's how every E-Mail attachement and binary data in XML works.
  Reply With Quote
05/22/14, 06:41 AM   #14
zgrssd
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 280
Despite what I said above, we must actually be carefull with the load we produce that way. The terms of Service contain this sentence:
You may not participate, take part in, initiate, or engage in actions that impose an unreasonable or disproportionate load on the infrastructure hosting the Game(s) and/or Services.
That there already is a limit on member note writes implies that staying below it would propably be okay.
  Reply With Quote
05/22/14, 03:05 PM   #15
Seerah
Fishing Trainer
 
Seerah's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Feb 2014
Posts: 648
The main concern for abuse is because ZOS has shown already that they are not opposed to locking things down. If they don't want addon communication, and you find a hole and abuse that system, they may just patch in the hole.
  Reply With Quote
05/23/14, 03:39 AM   #16
zgrssd
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 280
Originally Posted by Seerah View Post
The main concern for abuse is because ZOS has shown already that they are not opposed to locking things down. If they don't want addon communication, and you find a hole and abuse that system, they may just patch in the hole.
I think the mostly limited Mail Sending, Chat Messages and (with 1.1) Guild creation to hinder Gold Spammers. That and propably keep the load of the Mail/Chat/Guild Services manageable.

But you raised some good points. So I just asked Zenimax on the Addon Forum:
http://forums.elderscrollsonline.com...-communciation

We see where it goes from there.
  Reply With Quote
05/23/14, 03:42 AM   #17
thelegendaryof
 
thelegendaryof's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 161
Good luck with getting a response! (not ironically ment)
  Reply With Quote
05/23/14, 05:13 AM   #18
zgrssd
AddOn Author - Click to view addons
Join Date: May 2014
Posts: 280
Originally Posted by thelegendaryof View Post
Good luck with getting a response! (not ironically ment)
Thanks.

Until the answer comes around (and I have time to actually do the work), some more planning. I think starting at the protocoll might be to much into detail. So I try to give a proper overview based on the OSI model:
OSI Layer 1 is the Member Notes. This is our data transmission layer. How stuff works "below" that is not our concern. But a way to detect non-connectivity here (Guild or Member note functions being disabeled temporarily) should be considered.

OSI Layer 2 - not sure we can have one in a multicast environment.

OSI Layer 3: Technically each guild is a seperate network. The same way servers and routers are often connected to multipe Networks via Multiple NIC, the Client might be connected to multiple networks via the 5 guilds it can have.

OSI Layer 4&5: Since this is entirely multicast (while we could make point to point communciation between Addons in specific clients, this would be tiresome) I don't think we need one. At least to begin with. It's worth considering for later.

OSI Layer 6: We have to avoid strings as much as possible, so we cannot just serialise tables with string indexes. How about making this layer all about mapping table to network and back?
I have something in mind for that, just need to bounce it back a bit in my head.

OSI Layer 7: The addon that sends or receives data.
  Reply With Quote
05/23/14, 06:32 AM   #19
Iyanga
AddOn Author - Click to view addons
Join Date: Apr 2014
Posts: 183
Originally Posted by thelegendaryof View Post
Question is if there is nothing else what else should one do instead of sitting still and doing nothing? waiting? And dont call for realism. Without optimism and just trying something even if it fails and doesnt work nothing would be moving forward

No, it can be a move backward, too. ZOS could for example decide to remove member notes completely and therefore hurting all the people who use that feature for legitimate purposes just because you insisted on abusing it.
  Reply With Quote
05/23/14, 08:14 AM   #20
thelegendaryof
 
thelegendaryof's Avatar
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 161
Originally Posted by Iyanga View Post
No, it can be a move backward, too. ZOS could for example decide to remove member notes completely and therefore hurting all the people who use that feature for legitimate purposes just because you insisted on abusing it.
Like I've written above

Originally Posted by thelegendaryof View Post

I'm just not sure if Zenimax likes that and will not just disable that API-Function if they get knowledge of the way it 's used :/ ...
And as you see zgrssd already posted in the official forums asking if it 's allowed or not:

http://forums.elderscrollsonline.com...-communciation

Like said before - it 's all just guess- and theorywork right now ... nothing more.

Also "abusing" something is more likely using something in a negative way without any care if that impacts people directly/indirectly or not. You have to take into consideration in what way something is implemented. In that case it would be more likely a workaround for some missing features that don't impact most people at all (aside from seeing a simple link). (applying the above ethics!)

Last edited by thelegendaryof : 05/23/14 at 10:15 AM.
  Reply With Quote

ESOUI » Developer Discussions » General Authoring Discussion » Addons Communicating Guildwide via Member Notes?

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off