Thread Tools Display Modes
03/15/22, 06:16 AM   #1
ExoY
 
ExoY's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2020
Posts: 88
Disable "earned by" tooltip for AwA

Hey guys,
i am looking for a way to disable the popup tooltip "earned by xxx" when overing over an achievement with the new AwA system. So far I havent had any luck and am hoping somebody here can point me in the right direction

Regards,
ExoY
  Reply With Quote
03/15/22, 07:07 AM   #2
NeuroticPixels
Addon Addict
 
NeuroticPixels's Avatar
Premium Member
Join Date: May 2019
Posts: 211
https://www.esoui.com/downloads/info...ievements.html
  Reply With Quote
03/15/22, 08:19 AM   #3
ExoY
 
ExoY's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2020
Posts: 88
This is not quite accomplishing what i am looking for.

I want to disable the pop-up tooltip that shows who erned an achivement when hovering over it, not the tooltip text within the achivements description.

I just tried out the addon you referred to an the pop up tooltip is still there.


Edit: i just check the vanilla game and it looks like the ingame "earned by" description text with the addons was actually removed by default and replaced by the pop up one. (except when indicated by "recent achivements)

Last edited by ExoY : 03/15/22 at 08:25 AM.
  Reply With Quote
03/15/22, 08:27 AM   #4
Baertram
Super Moderator
 
Baertram's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 4,962
The text "earned by" is this string constant:
"Earned by: <<1>>", -- SI_ACHIEVEMENT_EARNED_FORMATTER

If you search in the code for SI_ACHIEVEMENT_EARNED_FORMATTER you might find the place where it can be removed:
https://github.com/esoui/esoui/blob/...ments.lua#L861

You can overwrite the string constant with an empty string so the text is not shown anymore:
Lua Code:
  1. SafeAddString(SI_ACHIEVEMENT_EARNED_FORMATTER, "", 2)
or re-use ZO_CreateStringId but adding a newer versin 2 should be enough.


Else the tooltip control of achievements are created here:

Could be this control:
https://github.com/esoui/esoui/blob/...ments.xml#L270

ZO_AchievementTooltip

Connected to lua here:
https://github.com/esoui/esoui/blob/...ents.lua#L1480

Object:
ACHIEVEMENTS.tooltip

Function showing it:
https://github.com/esoui/esoui/blob/...ents.lua#L1752
ACHIEVEMENTS:ShowAchievementDetailedTooltip

Lua Code:
  1. ZO_PreHook(ACHIEVEMENTS, "ShowAchievementDetailedTooltip", function(selfAchievements, id, anchor)
  2.   return true --suppress call to original function
  3. end)

#Not tested, hope it works and was the correct one

If this was not intended you could also try to prehook the function and change the data in the function accordingly to your needs:

Lua Code:
  1. function Achievements:ShowAchievementDetailedTooltip(id, anchor)
  2. end
  3. ZO_PreHook(ACHIEVEMENTS, "ShowAchievementDetailedTooltip", function(selfAchievements, id, anchor)
  4.     selfAchievements.tooltip.parentControl:ClearAnchors()
  5.     anchor:Set(selfAchievements.tooltip.parentControl)
  6.  
  7.     --local progress = GetAchievementProgress(id)
  8.     local progress = 0 --chanegd to always use 0
  9.     local timestamp = GetAchievementTimestamp(id)
  10.     selfAchievements.tooltip:Show(id, progress, timestamp)
  11.   return true --suppress call to original function
  12. end)

Last edited by Baertram : 03/15/22 at 08:38 AM.
  Reply With Quote
03/15/22, 08:33 AM   #5
ExoY
 
ExoY's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2020
Posts: 88
Thanks Baertram,

I will check it how but it does look promising.



Edit: ShowAchievementDetailedTooltip wasnt the correct one, but this one ended up doing the trick:

Lua Code:
  1. ZO_PreHook(Achievement, "RefreshTooltip", function()
  2.     return true
  3.   end)

but i didnt check, if it effects any other tooltips within the achievement context.

Last edited by ExoY : 03/15/22 at 08:51 AM.
  Reply With Quote
03/15/22, 01:38 PM   #6
NeuroticPixels
Addon Addict
 
NeuroticPixels's Avatar
Premium Member
Join Date: May 2019
Posts: 211
Maybe this one then?
https://www.esoui.com/downloads/info...nonymizer.html
  Reply With Quote
03/24/22, 08:00 PM   #7
tim99
 
tim99's Avatar
AddOn Author - Click to view addons
Join Date: Jul 2017
Posts: 22
Originally Posted by LoneStar2911 View Post

rofl
  Reply With Quote
03/25/22, 12:39 AM   #8
NeuroticPixels
Addon Addict
 
NeuroticPixels's Avatar
Premium Member
Join Date: May 2019
Posts: 211
Originally Posted by tim99 View Post
rofl
LOL!!!!! I just realized.
Also, I didn't realize they were probably asking so they could implement it into their own addon... that i linked... to them...
Derp.

Last edited by NeuroticPixels : 03/25/22 at 12:41 AM. Reason: Whoops
  Reply With Quote
03/25/22, 03:04 AM   #9
Baertram
Super Moderator
 
Baertram's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 4,962
Circle of life
  Reply With Quote
03/25/22, 03:31 AM   #10
ExoY
 
ExoY's Avatar
AddOn Author - Click to view addons
Join Date: Feb 2020
Posts: 88
Originally Posted by LoneStar2911 View Post
LOL!!!!! I just realized.
Also, I didn't realize they were probably asking so they could implement it into their own addon... that i linked... to them...
Derp.
Yeah
and i only wanted to make the addon if it not already exists

But i thought it was intentional that you posted my addon as a reference for anybody else stumbling upon this thread
  Reply With Quote

ESOUI » Developer Discussions » General Authoring Discussion » Disable "earned by" tooltip for AwA

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