-
-
Save anonymous/3b09664b4203a024f55865fdbd1085a0 to your computer and use it in GitHub Desktop.
chat bubbles clamping to top, :IsClampedToScreen() returns false
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function module:IterateChatBubbles(funcToCall) | |
for i = 1, WorldFrame:GetNumChildren() do | |
local v = select(i, WorldFrame:GetChildren()) | |
local b = v.isChatBubble == nil and v:GetBackdrop() | |
if v.isChatBubble ~= false and b and b.bgFile == "Interface\\Tooltips\\ChatBubble-Background" then | |
v.isChatBubble = true | |
print("A", v, v:GetDebugName(), v:IsClampedToScreen()) | |
for i = 1, v:GetNumRegions() do | |
local frame = v | |
local v = select(i, v:GetRegions()) | |
if v.IsClampedToScreen then | |
print("B", v, v:GetDebugName(), v:IsClampedToScreen()) | |
end | |
if v:GetObjectType() == "FontString" then | |
local fontstring = v | |
if type(funcToCall) == "function" then | |
funcToCall(frame, fontstring) | |
else | |
self[funcToCall](self, frame, fontstring) | |
end | |
end | |
end | |
else | |
v.isChatBubble = false | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment