Quantcast Modifying chat message before it is shown by others - WoWInterface
Thread Tools Display Modes
04-01-17, 08:02 PM   #1
Layback_
An Onyxian Warder
Join Date: Feb 2016
Posts: 356
Modifying chat message before it is shown by others

Hi all,

So for this time I am attempting to make an addon that modifies chat message sent by myself before it is being displayed(?) on other player's screen for links like item, quest, etc.

The reason that I am trying to make this is because I am using a different client locale with others and those links that I send is created based on my locale, not theirs.

Clicking the link will display the tooltip on their own locale, but I am willing to avoid this.

I would say modifying chat message isn't that hard, but modifying link's display text within chat message would be a challenge here.

What was worse, I have to modify that display text from one locale to another in this specific case, thus I don't think it is doable.

Any idea, please?
  Reply With Quote
04-01-17, 08:03 PM   #2
Layback_
An Onyxian Warder
Join Date: Feb 2016
Posts: 356
Oops... this should have been posted on "General Authoring Discussion" page, not here.

Sorry haha...
  Reply With Quote
04-01-17, 08:49 PM   #3
Lombra
A Molten Giant
 
Lombra's Avatar
AddOn Author - Click to view addons
Join Date: Nov 2006
Posts: 554
You want to translate links into a language other than that of your own client? That would not be possible, no.
__________________
Grab your sword and fight the Horde!
  Reply With Quote
04-02-17, 12:43 AM   #4
Layback_
An Onyxian Warder
Join Date: Feb 2016
Posts: 356
Yeah, that's what I thought so as you will need an access to each locale's db which I guess is not supported in WoW
(unless you make your own db for that which is...)
  Reply With Quote
04-02-17, 07:13 AM   #5
SDPhantom
A Pyroguard Emberseer
 
SDPhantom's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2006
Posts: 1,920
The server is picky about accepting links, so it isn't a good idea to mess around with them. The best solution to relocalizing links is to do it on the receiving end so this wouldn't be a problem and you can easily convert link data into client-local names.
__________________
ESOUI AddOns | WoWInterface AddOns
"All I want is a pretty girl, a decent meal, and the right to shoot lightning at fools."
-Anders (Dragon Age: Origins - Awakening)
  Reply With Quote
04-02-17, 04:52 PM   #6
Layback_
An Onyxian Warder
Join Date: Feb 2016
Posts: 356
So you mean that if I'd make an addon for this, it should be installed on receiving end's client, not mine?
  Reply With Quote
04-03-17, 12:15 AM   #7
SDPhantom
A Pyroguard Emberseer
 
SDPhantom's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2006
Posts: 1,920
Correct. It also would take care of an issue where not everyone receiving said message would be running the same locale.
__________________
ESOUI AddOns | WoWInterface AddOns
"All I want is a pretty girl, a decent meal, and the right to shoot lightning at fools."
-Anders (Dragon Age: Origins - Awakening)
  Reply With Quote
04-03-17, 07:45 AM   #8
Jarod24
A Theradrim Guardian
AddOn Author - Click to view addons
Join Date: Jul 2012
Posts: 66
Originally Posted by Layback_ View Post
Hi all,
So for this time I am attempting to make an addon that modifies chat message sent by myself before it is being displayed(?) on other player's screen for links like item, quest, etc.

The reason that I am trying to make this is because I am using a different client locale with others and those links that I send is created based on my locale, not theirs.

Clicking the link will display the tooltip on their own locale, but I am willing to avoid this.

I would say modifying chat message isn't that hard, but modifying link's display text within chat message would be a challenge here.

What was worse, I have to modify that display text from one locale to another in this specific case, thus I don't think it is doable.

Any idea, please?


I wrote an addon that did the opposite; translated all incoming hyperlinks (items, achievements etc) into my own locale.
The reason; I run an English client, but other guildmates are running on Italian/German clients and it was confusing as hell when they linked me achievements that were in their language.

I stopped updating it because it was not that popular.
You can still find it here: http://www.wowinterface.com/download...ranslator.html


The addon basically would scan the incoming chat, lookup any hyperlinks if found on it's own and do a replacement if it's string did not match what the client returned on its own.
__________________
Author of IfThen, Links in Chat
  Reply With Quote
04-03-17, 02:29 PM   #9
Layback_
An Onyxian Warder
Join Date: Feb 2016
Posts: 356
Sweet!

Thanks to both SDPhantom and Jarod24 for recommendations
  Reply With Quote

WoWInterface » Developer Discussions » Lua/XML Help » Modifying chat message before it is shown by others

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