From 950ba412e40624bc564e2354a85bc7f6b48946a9 Mon Sep 17 00:00:00 2001 From: Christopher Tse Date: Sat, 4 Apr 2020 14:56:17 +1100 Subject: [PATCH] Fixed an issue where the chat bubble tail wasn't reset after closing the bubble --- ChatBubblePool.lua | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/ChatBubblePool.lua b/ChatBubblePool.lua index 8756f2b..026dbef 100644 --- a/ChatBubblePool.lua +++ b/ChatBubblePool.lua @@ -65,6 +65,7 @@ local function closeBubble(chatBubble) chatBubble:ClearAllPoints(); chatBubble:ResetNameColor(); chatBubble:SetPoint("TOPLEFT",WorldFrame,"CENTER",-chatBubble.center.x,-chatBubble.center.y); + chatBubble.tail:Reset(); chatBubble.isAvailable = true; end @@ -318,7 +319,12 @@ function ChatBubblePool.getChatBubble() chatBubbleTail.rightOffset = -3; chatBubbleTail.minX = 8; chatBubbleTail.minY = 8; - + chatBubbleTail.Reset = function(self) + self.tex:SetRotation(0); + self:ClearAllPoints(); + self:SetPoint("TOPLEFT",chatBubbleBackground,"BOTTOMLEFT",8,3); + end + newChatBubble.tail = chatBubbleTail; --Functions for outside use newChatBubble.GetName = nameBox.GetText; -- 1.7.9.5