local m=false local n,w=pcall(function()return(UserSettings()):IsUserFeatureEnabled("\085\115\101\114\072\097\110\100\108\101\067\104\097\116\072\111\116\075\101\121\087\105\116\104\067\111\110\116\101\120\116\065\099\116\105\111\110\083\101\114\118\105\099\101")end)if n then m=w end local L=game:GetService("\082\117\110\083\101\114\118\105\099\101")local t=game:GetService("\082\101\112\108\105\099\097\116\101\100\083\116\111\114\097\103\101")local d=game:GetService("\067\104\097\116")local p=game:GetService("\083\116\097\114\116\101\114\071\117\105")local h=game:GetService("\067\111\110\116\101\120\116\065\099\116\105\111\110\083\101\114\118\105\099\101")local Z=t:WaitForChild("\068\101\102\097\117\108\116\067\104\097\116\083\121\115\116\101\109\067\104\097\116\069\118\101\110\116\115")local v=t:WaitForChild("\068\101\102\097\117\108\116\067\104\097\116\083\121\115\116\101\109\067\104\097\116\069\118\101\110\116\115")local f=d:WaitForChild("\067\108\105\101\110\116\067\104\097\116\077\111\100\117\108\101\115")local D=require(f:WaitForChild("\067\104\097\116\067\111\110\115\116\097\110\116\115"))local s=require(f:WaitForChild("\067\104\097\116\083\101\116\116\105\110\103\115"))local O=require((f:WaitForChild("\077\101\115\115\097\103\101\067\114\101\097\116\111\114\077\111\100\117\108\101\115")):WaitForChild("\085\116\105\108"))local Y=nil pcall(function()Y=require((game:GetService("\067\104\097\116")).ClientChatModules.ChatLocalization)end)if Y==nil then Y={Get=function(m,n,w)return w end}end local U=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")local E={OnNewMessage="\082\101\109\111\116\101\069\118\101\110\116",OnMessageDoneFiltering="\082\101\109\111\116\101\069\118\101\110\116";OnNewSystemMessage="\082\101\109\111\116\101\069\118\101\110\116";OnChannelJoined="\082\101\109\111\116\101\069\118\101\110\116";OnChannelLeft="\082\101\109\111\116\101\069\118\101\110\116";OnMuted="\082\101\109\111\116\101\069\118\101\110\116";OnUnmuted="\082\101\109\111\116\101\069\118\101\110\116",OnMainChannelSet="\082\101\109\111\116\101\069\118\101\110\116";SayMessageRequest="\082\101\109\111\116\101\069\118\101\110\116";GetInitDataRequest="\082\101\109\111\116\101\070\117\110\099\116\105\111\110"}local a={}local W=10 function TryRemoveChildWithVerifyingIsCorrectType(m)if E[m.Name]then if m:IsA(E[m.Name])then E[m.Name]=nil a[m.Name]=m W=W-1 end end end for m,n in pairs(v:GetChildren())do TryRemoveChildWithVerifyingIsCorrectType(n)end if W>0 then local m=v.ChildAdded:connect(function(m)TryRemoveChildWithVerifyingIsCorrectType(m)if W<1 then U:Fire()end end)U.Event:wait()m:disconnect()U:Destroy()end local T=game:GetService("\085\115\101\114\073\110\112\117\116\083\101\114\118\105\099\101")local c=game:GetService("\082\117\110\083\101\114\118\105\099\101")local r=game:GetService("\080\108\097\121\101\114\115")local u=r.LocalPlayer while not u do r.ChildAdded:wait()u=r.LocalPlayer end local l=6 if s.ScreenGuiDisplayOrder~=nil then l=s.ScreenGuiDisplayOrder end local N=Instance.new("\083\099\114\101\101\110\071\117\105")N.Name="\067\104\097\116"N.ResetOnSpawn=false N.DisplayOrder=l N.Parent=u:WaitForChild("\080\108\097\121\101\114\071\117\105")local P=require(script:WaitForChild("\077\101\115\115\097\103\101\076\097\098\101\108\067\114\101\097\116\111\114"))local q=require(script:WaitForChild("\077\101\115\115\097\103\101\076\111\103\068\105\115\112\108\097\121"))local K=require(script:WaitForChild("\067\104\097\116\067\104\097\110\110\101\108"))local i=(require(script:WaitForChild("\067\104\097\116\087\105\110\100\111\119"))).new()local B=(require(script:WaitForChild("\067\104\097\110\110\101\108\115\066\097\114"))).new()local Q=q.new()local F=(require(script:WaitForChild("\067\111\109\109\097\110\100\080\114\111\099\101\115\115\111\114"))).new()local X=(require(script:WaitForChild("\067\104\097\116\066\097\114"))).new(F,i)i:CreateGuiObjects(N)i:RegisterChatBar(X)i:RegisterChannelsBar(B)i:RegisterMessageLogDisplay(Q)O:RegisterChatWindow(i)local b=require(script:WaitForChild("\077\101\115\115\097\103\101\083\101\110\100\101\114"))b:RegisterSayMessageFunction(a.SayMessageRequest)if T.TouchEnabled then X:SetTextLabelText(Y:Get("\071\097\109\101\067\104\097\116\095\067\104\097\116\077\097\105\110\095\067\104\097\116\066\097\114\084\101\120\116\084\111\117\099\104","\084\097\112 \104\101\114\101 \116\111 \099\104\097\116"))else X:SetTextLabelText(Y:Get("\071\097\109\101\067\104\097\116\095\067\104\097\116\077\097\105\110\095\067\104\097\116\066\097\114\084\101\120\116","\084\111 \099\104\097\116 \099\108\105\099\107 \104\101\114\101 \111\114 \112\114\101\115\115 \"\047\" \107\101\121"))end local y=script spawn(function()local m=require(y:WaitForChild("\067\117\114\118\101\085\116\105\108"))local n=1/(s.ChatAnimationFPS and 20)local w=tick()while true do local L=tick()local t=m:DeltaTimeToTimescale(L-w)if t~=0 then i:Update(t)end w=L wait(n)end end)function CheckIfPointIsInSquare(m,n,w)local L=false if n.X<=m.X then L=false if m.X<=w.X then L=false if n.Y<=m.Y then L=m.Y<=w.Y end end end return L end local V=0 local e=false local A=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")function DoBackgroundFadeIn(m)V=tick()e=false A:Fire()i:FadeInBackground(m or s.ChatDefaultFadeDuration)if i:GetCurrentChannel()then local m=Q.Scroller m.ScrollingEnabled=true m.ScrollBarThickness=q.ScrollBarThickness end end function DoBackgroundFadeOut(m)V=tick()e=true A:Fire()i:FadeOutBackground(m or s.ChatDefaultFadeDuration)if i:GetCurrentChannel()then local m=Q.Scroller m.ScrollingEnabled=false m.ScrollBarThickness=0 end end local o=0 local g=false function DoTextFadeIn(m)o=tick()g=false A:Fire()i:FadeInText((m or s.ChatDefaultFadeDuration)*0)end function DoTextFadeOut(m)o=tick()g=true A:Fire()i:FadeOutText(m or s.ChatDefaultFadeDuration)end function DoFadeInFromNewInformation()DoTextFadeIn()if s.ChatShouldFadeInFromNewInformation then DoBackgroundFadeIn()end end function InstantFadeIn()DoBackgroundFadeIn(0)DoTextFadeIn(0)end function InstantFadeOut()DoBackgroundFadeOut(0)DoTextFadeOut(0)end local j=nil local H=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")function UpdateFadingForMouseState(m)j=m H:Fire()if X:IsFocused()then return end if m then else DoBackgroundFadeIn()return end DoBackgroundFadeIn()DoTextFadeIn()end local z=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")spawn(function()while true do c.RenderStepped:wait()while not(not j)or not(not X:IsFocused())do if j then H.Event:wait()end if X:IsFocused()then z.Event:wait()end end if not e then if s.ChatWindowBackgroundFadeOutTime<tick()-V then DoBackgroundFadeOut()end elseif not g then if s.ChatWindowTextFadeOutTime<tick()-o then DoTextFadeOut()end else A.Event:wait()end end end)function getClassicChatEnabled()if s.ClassicChatEnabled~=nil then return s.ClassicChatEnabled end return r.ClassicChat end function getBubbleChatEnabled()if s.BubbleChatEnabled~=nil then return s.BubbleChatEnabled end return r.BubbleChat end function bubbleChatOnly()return not getClassicChatEnabled()and getBubbleChatEnabled()end local k={}function UpdateMousePosition(m)if k.Visible then if k.IsCoreGuiEnabled then if not k.TopbarEnabled then if not s.ChatOnWithTopBarOff then return end end else return end else return end if bubbleChatOnly()then return end local n=i.GuiObject.AbsolutePosition local w=CheckIfPointIsInSquare(m,n,n+i.GuiObject.AbsoluteSize)if w~=j then UpdateFadingForMouseState(w)end end T.InputChanged:connect(function(m,n)if m.UserInputType==Enum.UserInputType.MouseMovement then UpdateMousePosition(Vector2.new(m.Position.X,m.Position.Y))end end)T.TouchTap:connect(function(m,n)UpdateMousePosition(m[1])end)T.TouchMoved:connect(function(m,n)UpdateMousePosition(Vector2.new(m.Position.X,m.Position.Y))end)T.Changed:connect(function(m)if m=="\077\111\117\115\101\066\101\104\097\118\105\111\114"and T.MouseBehavior==Enum.MouseBehavior.LockCenter then local m=i.GuiObject.AbsolutePosition if CheckIfPointIsInSquare(N.AbsoluteSize/2,m,m+i.GuiObject.AbsoluteSize)then T.MouseBehavior=Enum.MouseBehavior.Default end end end)UpdateFadingForMouseState(true)UpdateFadingForMouseState(false)local C={Signal=function()local m={}local n=nil local w=nil local L=Instance.new("\066\105\110\100\097\098\108\101\069\118\101\110\116")function m.fire(m,...)n={...}w=select("\035",...)L:Fire()end function m.connect(m,t)if not t then error("\099\111\110\110\101\099\116\040\110\105\108\041",2)end return L.Event:connect(function()t(unpack(n,1,w))end)end function m.wait(m)L.Event:wait()assert(n,"\077\105\115\115\105\110\103 \097\114\103 \100\097\116\097\044 \108\105\107\101\108\121 \100\117\101 \116\111 \058\084\119\101\101\110\083\105\122\101\047\080\111\115\105\116\105\111\110 \099\111\114\114\117\112\116\105\110\103 \116\104\114\101\097\100\114\101\102\115\046")return unpack(n,1,w)end return m end}function SetVisibility(m)i:SetVisible(m)k.VisibilityStateChanged:fire(m)k.Visible=m if k.IsCoreGuiEnabled then if m then else InstantFadeOut()return end else return end InstantFadeIn()end k.TopbarEnabled=true k.MessageCount=0 k.Visible=true k.IsCoreGuiEnabled=true function k.ToggleVisibility(m)SetVisibility(not i:GetVisible())end function k.SetVisible(m,n)if i:GetVisible()~=n then SetVisibility(n)end end function k.FocusChatBar(m)X:CaptureFocus()end function k.EnterWhisperState(m,n)X:EnterWhisperState(n)end function k.GetVisibility(m)return i:GetVisible()end function k.GetMessageCount(m)return m.MessageCount end function k.TopbarEnabledChanged(m,n)m.TopbarEnabled=n m.CoreGuiEnabled:fire((game:GetService("\083\116\097\114\116\101\114\071\117\105")):GetCoreGuiEnabled(Enum.CoreGuiType.Chat))end function k.IsFocused(m,n)return X:IsFocused()end k.ChatBarFocusChanged=C.Signal()k.VisibilityStateChanged=C.Signal()k.MessagesChanged=C.Signal()k.MessagePosted=C.Signal()k.CoreGuiEnabled=C.Signal()k.ChatMakeSystemMessageEvent=C.Signal()k.ChatWindowPositionEvent=C.Signal()k.ChatWindowSizeEvent=C.Signal()k.ChatBarDisabledEvent=C.Signal()function k.fChatWindowPosition(m)return i.GuiObject.Position end function k.fChatWindowSize(m)return i.GuiObject.Size end function k.fChatBarDisabled(m)return not X:GetEnabled()end if m then local m=true h:BindAction("\084\111\103\103\108\101\067\104\097\116",function(n,w,L)if n=="\084\111\103\103\108\101\067\104\097\116"and(w==Enum.UserInputState.Begin and(m and L.UserInputType==Enum.UserInputType.Keyboard))then DoChatBarFocus()end end,true,Enum.KeyCode.Slash)else local m=true function k.SpecialKeyPressed(n,w,L)if w==Enum.SpecialKey.ChatHotkey and m then DoChatBarFocus()end end end k.CoreGuiEnabled:connect(function(m)k.IsCoreGuiEnabled=m m=m and(k.TopbarEnabled or s.ChatOnWithTopBarOff)i:SetCoreGuiEnabled(m)if m then InstantFadeIn()return end X:ReleaseFocus()InstantFadeOut()end)function trimTrailingSpaces(m)local n=#m while true do if 0<n then else break end if m:find("\094\037\115",n)then else break end n=n-1 end return m:sub(1,n)end local I=false k.ChatMakeSystemMessageEvent:connect(function(m)if m.Text and type(m.Text)=="\115\116\114\105\110\103"then while not I do wait()end local n=s.GeneralChannelName local w=i:GetChannel(n)if w then w:AddMessageToChannel({ID=-1,FromSpeaker=nil,SpeakerUserId=0;OriginalChannel=n,IsFiltered=true;MessageLength=string.len(m.Text);MessageLengthUtf8=utf8.len(utf8.nfcnormalize(m.Text));Message=trimTrailingSpaces(m.Text),MessageType=D.MessageTypeSetCore;Time=os.time(),ExtraData=m})B:UpdateMessagePostedInChannel(n)k.MessageCount=k.MessageCount+1 k.MessagesChanged:fire(k.MessageCount)end end end)k.ChatBarDisabledEvent:connect(function(m)if u19 then X:SetEnabled(not m)if m then X:ReleaseFocus()end end end)k.ChatWindowSizeEvent:connect(function(m)i.GuiObject.Size=m end)k.ChatWindowPositionEvent:connect(function(m)i.GuiObject.Position=m end)function DoChatBarFocus()if not i:GetCoreGuiEnabled()then return end if not X:GetEnabled()then return end if not X:IsFocused()then if X:GetVisible()then k:SetVisible(true)InstantFadeIn()X:CaptureFocus()k.ChatBarFocusChanged:fire(true)end end end z.Event:connect(function(m)k.ChatBarFocusChanged:fire(m)end)function DoSwitchCurrentChannel(m)if i:GetChannel(m)then i:SwitchCurrentChannel(m)end end function SendMessageToSelfInTargetChannel(m,n,w)local L=i:GetChannel(n)if L then L:AddMessageToChannel({ID=-1,FromSpeaker=nil;SpeakerUserId=0,OriginalChannel=n;IsFiltered=true;MessageLength=string.len(m),MessageLengthUtf8=utf8.len(utf8.nfcnormalize(m)),Message=trimTrailingSpaces(m),MessageType=D.MessageTypeSystem;Time=os.time();ExtraData=w})end end function chatBarFocused()if not j then DoBackgroundFadeIn()if g then DoTextFadeIn()end end z:Fire(true)end function chatBarFocusLost(m,n)DoBackgroundFadeIn()z:Fire(false)if m then local m=(X:GetTextBox()).Text if X:IsInCustomState()then local n=X:GetCustomMessage()if n then m=n end local w=X:CustomStateProcessCompletedMessage(m)X:ResetCustomState()if w then return end end;(X:GetTextBox()).Text=""if m~=""then k.MessagePosted:fire(m)if not F:ProcessCompletedChatMessage(m,i)then local n=nil if s.DisallowedWhiteSpace then local n=#s.DisallowedWhiteSpace local w=0 while true do if s.DisallowedWhiteSpace[w]=="\t"then m=string.gsub(m,s.DisallowedWhiteSpace[w]," ")else m=string.gsub(m,s.DisallowedWhiteSpace[w],"")end if true then if w<n then else break end elseif n<w then else break end w=w+1 end end n=string.gsub(string.gsub(m,"\n",""),"\091 \093\043"," ")local w=i:GetTargetMessageChannel()if w then b:SendMessage(n,w)return end b:SendMessage(n,nil)end end end end local S={}function setupChatBarConnections()local m=#S local n=0 while true do S[n]:Disconnect()if true then if n<m then else break end elseif m<n then else break end n=n+1 end S={}table.insert(S,(X:GetTextBox()).FocusLost:connect(chatBarFocusLost))table.insert(S,(X:GetTextBox()).Focused:connect(chatBarFocused))end setupChatBarConnections()X.GuiObjectsChanged:connect(setupChatBarConnections)function getEchoMessagesInGeneral()if s.EchoMessagesInGeneralChannel==nil then return true end return s.EchoMessagesInGeneralChannel end a.OnMessageDoneFiltering.OnClientEvent:connect(function(m)if not s.ShowUserOwnFilteredMessage and m.FromSpeaker==u.Name then return end local n=m.OriginalChannel local w=i:GetChannel(n)if w then w:UpdateMessageFiltered(m)end if getEchoMessagesInGeneral()and(s.GeneralChannelName and n~=s.GeneralChannelName)then local n=i:GetChannel(s.GeneralChannelName)if n then n:UpdateMessageFiltered(m)end end end)a.OnNewMessage.OnClientEvent:connect(function(m,n)local w=i:GetChannel(n)if w then w:AddMessageToChannel(m)if m.FromSpeaker~=u.Name then B:UpdateMessagePostedInChannel(n)end if getEchoMessagesInGeneral()and(s.GeneralChannelName and n~=s.GeneralChannelName)then local n=i:GetChannel(s.GeneralChannelName)if n then n:AddMessageToChannel(m)end end k.MessageCount=k.MessageCount+1 k.MessagesChanged:fire(k.MessageCount)DoFadeInFromNewInformation()end end)a.OnNewSystemMessage.OnClientEvent:connect(function(m,n)n=n and"\083\121\115\116\101\109"local w=i:GetChannel(n)if w then w:AddMessageToChannel(m)B:UpdateMessagePostedInChannel(n)k.MessageCount=k.MessageCount+1 k.MessagesChanged:fire(k.MessageCount)DoFadeInFromNewInformation()if getEchoMessagesInGeneral()and(s.GeneralChannelName and n~=s.GeneralChannelName)then local n=i:GetChannel(s.GeneralChannelName)if n then n:AddMessageToChannel(m)return end end else warn(string.format("\074\117\115\116 \114\101\099\101\105\118\101\100 \115\121\115\116\101\109 \109\101\115\115\097\103\101 \102\111\114 \099\104\097\110\110\101\108 \073\'\109 \110\111\116 \105\110 \091\037\115\093",n))end end)function HandleChannelJoined(m,n,w,L,t,d)if i:GetChannel(m)then i:RemoveChannel(m)end if m==s.GeneralChannelName then I=true end if L then X:SetChannelNameColor(m,L)end local p=i:AddChannel(m)if p then if m==s.GeneralChannelName then DoSwitchCurrentChannel(m)end if w then local n=1 if s.MessageHistoryLengthPerChannel<#w then n=#w-s.MessageHistoryLengthPerChannel end local L=#w local d=n-1 while true do p:AddMessageToChannel(w[d])if true then if d<L then else break end elseif L<d then else break end d=d+1 end if getEchoMessagesInGeneral()then if t then if s.GeneralChannelName then if m~=s.GeneralChannelName then local m=i:GetChannel(s.GeneralChannelName)if m then m:AddMessagesToChannelByTimeStamp(w,n)end end end end end end if n~=""then local w={ID=-1,FromSpeaker=nil;SpeakerUserId=0;OriginalChannel=m;IsFiltered=true,MessageLength=string.len(n),MessageLengthUtf8=utf8.len(utf8.nfcnormalize(n)),Message=trimTrailingSpaces(n),MessageType=D.MessageTypeWelcome;Time=os.time();ExtraData=nil}p:AddMessageToChannel(w)if getEchoMessagesInGeneral()then if d then if not s.ShowChannelsBar then if m~=s.GeneralChannelName then local m=i:GetChannel(s.GeneralChannelName)if m then m:AddMessageToChannel(w)end end end end end end DoFadeInFromNewInformation()end end a.OnChannelJoined.OnClientEvent:connect(function(m,n,w,L)HandleChannelJoined(m,n,w,L,false,true)end)a.OnChannelLeft.OnClientEvent:connect(function(m)i:RemoveChannel(m)DoFadeInFromNewInformation()end)a.OnMuted.OnClientEvent:connect(function(m) end)a.OnUnmuted.OnClientEvent:connect(function(m) end)a.OnMainChannelSet.OnClientEvent:connect(function(m)DoSwitchCurrentChannel(m)end);(coroutine.wrap(function()local m=Z:WaitForChild("\067\104\097\110\110\101\108\078\097\109\101\067\111\108\111\114\085\112\100\097\116\101\100",5)if m then m.OnClientEvent:connect(function(m,n)X:SetChannelNameColor(m,n)end)end end))()local J=nil local R=nil local M=nil local x=nil pcall(function()J=p:GetCore("\080\108\097\121\101\114\066\108\111\099\107\101\100\069\118\101\110\116")R=p:GetCore("\080\108\097\121\101\114\077\117\116\101\100\069\118\101\110\116")M=p:GetCore("\080\108\097\121\101\114\085\110\098\108\111\099\107\101\100\069\118\101\110\116")x=p:GetCore("\080\108\097\121\101\114\085\110\109\117\116\101\100\069\118\101\110\116")end)function SendSystemMessageToSelf(m)local n=i:GetCurrentChannel()if n then n:AddMessageToChannel({ID=-1;FromSpeaker=nil;SpeakerUserId=0,OriginalChannel=n.Name,IsFiltered=true,MessageLength=string.len(m),MessageLengthUtf8=utf8.len(utf8.nfcnormalize(m));Message=trimTrailingSpaces(m);MessageType=D.MessageTypeSystem,Time=os.time(),ExtraData=nil})end end function MutePlayer(m)local n=Z:FindFirstChild("\077\117\116\101\080\108\097\121\101\114\082\101\113\117\101\115\116")if n then else return false end return n:InvokeServer(m.Name)end if J then J.Event:connect(function(m)if MutePlayer(m)then if s.PlayerDisplayNamesEnabled then local n=m.DisplayName else v77=m.Name end SendSystemMessageToSelf(Y:Get("\071\097\109\101\067\104\097\116\095\067\104\097\116\077\097\105\110\095\083\112\101\097\107\101\114\072\097\115\066\101\101\110\066\108\111\099\107\101\100",string.format("\083\112\101\097\107\101\114 \'\037\115\' \104\097\115 \098\101\101\110 \098\108\111\099\107\101\100\046",v77),{RBX_NAME=v77}))end end)end if R then R.Event:connect(function(m)if MutePlayer(m)then if s.PlayerDisplayNamesEnabled then local n=m.DisplayName else v78=m.Name end SendSystemMessageToSelf(Y:Get("\071\097\109\101\067\104\097\116\095\067\104\097\116\077\097\105\110\095\083\112\101\097\107\101\114\072\097\115\066\101\101\110\077\117\116\101\100",string.format("\083\112\101\097\107\101\114 \'\037\115\' \104\097\115 \098\101\101\110 \109\117\116\101\100\046",v78),{RBX_NAME=v78}))end end)end function UnmutePlayer(m)local n=Z:FindFirstChild("\085\110\077\117\116\101\080\108\097\121\101\114\082\101\113\117\101\115\116")if n then else return false end return n:InvokeServer(m.Name)end if M then M.Event:connect(function(m)if UnmutePlayer(m)then if s.PlayerDisplayNamesEnabled then local n=m.DisplayName else v80=m.Name end SendSystemMessageToSelf(Y:Get("\071\097\109\101\067\104\097\116\095\067\104\097\116\077\097\105\110\095\083\112\101\097\107\101\114\072\097\115\066\101\101\110\085\110\066\108\111\099\107\101\100",string.format("\083\112\101\097\107\101\114 \'\037\115\' \104\097\115 \098\101\101\110 \117\110\098\108\111\099\107\101\100\046",v80),{RBX_NAME=v80}))end end)end if x then x.Event:connect(function(m)if UnmutePlayer(m)then if s.PlayerDisplayNamesEnabled then local n=m.DisplayName else v81=m.Name end SendSystemMessageToSelf(Y:Get("\071\097\109\101\067\104\097\116\095\067\104\097\116\077\097\105\110\095\083\112\101\097\107\101\114\072\097\115\066\101\101\110\085\110\077\117\116\101\100",string.format("\083\112\101\097\107\101\114 \'\037\115\' \104\097\115 \098\101\101\110 \117\110\109\117\116\101\100\046",v81),{RBX_NAME=v81}))end end)end spawn(function()if u.UserId>0 then pcall(function()local m=p:GetCore("\071\101\116\066\108\111\099\107\101\100\085\115\101\114\073\100\115")if#m>0 then local n=Z:FindFirstChild("\083\101\116\066\108\111\099\107\101\100\085\115\101\114\073\100\115\082\101\113\117\101\115\116")if n then n:FireServer(m)end end end)end end)spawn(function()local m,n=pcall(function()return d:CanUserChatAsync(u.UserId)end)if m then u19=c:IsStudio()and n end end)local G=a.GetInitDataRequest:InvokeServer()for m,n in pairs(G.Channels)do if n[1]==s.GeneralChannelName then HandleChannelJoined(n[1],n[2],n[3],n[4],true,false)end end for m,n in pairs(G.Channels)do if n[1]~=s.GeneralChannelName then HandleChannelJoined(n[1],n[2],n[3],n[4],true,false)end end return k


local v1 = false;
local v2, v3 = pcall(function()
	return UserSettings():IsUserFeatureEnabled("UserHandleChatHotKeyWithContextActionService");
end);
if v2 then
	v1 = v3;
end;
local l__RunService__4 = game:GetService("RunService");
local l__ReplicatedStorage__5 = game:GetService("ReplicatedStorage");
local l__Chat__6 = game:GetService("Chat");
local l__StarterGui__7 = game:GetService("StarterGui");
local l__ContextActionService__8 = game:GetService("ContextActionService");
local v9 = l__ReplicatedStorage__5:WaitForChild("DefaultChatSystemChatEvents");
local v10 = l__ReplicatedStorage__5:WaitForChild("DefaultChatSystemChatEvents");
local l__ClientChatModules__11 = l__Chat__6:WaitForChild("ClientChatModules");
local v12 = require(l__ClientChatModules__11:WaitForChild("ChatConstants"));
local v13 = require(l__ClientChatModules__11:WaitForChild("ChatSettings"));
local v14 = require(l__ClientChatModules__11:WaitForChild("MessageCreatorModules"):WaitForChild("Util"));
local u1 = nil;
pcall(function()
	u1 = require(game:GetService("Chat").ClientChatModules.ChatLocalization);
end);
if u1 == nil then
	u1 = {
		Get = function(p1, p2, p3)
			return p3;
		end
	};
end;
local v15 = Instance.new("BindableEvent");
local u2 = {
	OnNewMessage = "RemoteEvent", 
	OnMessageDoneFiltering = "RemoteEvent", 
	OnNewSystemMessage = "RemoteEvent", 
	OnChannelJoined = "RemoteEvent", 
	OnChannelLeft = "RemoteEvent", 
	OnMuted = "RemoteEvent", 
	OnUnmuted = "RemoteEvent", 
	OnMainChannelSet = "RemoteEvent", 
	SayMessageRequest = "RemoteEvent", 
	GetInitDataRequest = "RemoteFunction"
};
local u3 = {};
local u4 = 10;
function TryRemoveChildWithVerifyingIsCorrectType(p4)
	if u2[p4.Name] then
		if p4:IsA(u2[p4.Name]) then
			u2[p4.Name] = nil;
			u3[p4.Name] = p4;
			u4 = u4 - 1;
		end;
	end;
end;
for v16, v17 in pairs(v10:GetChildren()) do
	TryRemoveChildWithVerifyingIsCorrectType(v17);
end;
if u4 > 0 then
	local v18 = v10.ChildAdded:connect(function(p5)
		TryRemoveChildWithVerifyingIsCorrectType(p5);
		if u4 < 1 then
			v15:Fire();
		end;
	end);
	v15.Event:wait();
	v18:disconnect();
	v15:Destroy();
end;
local l__UserInputService__19 = game:GetService("UserInputService");
local l__RunService__20 = game:GetService("RunService");
local l__Players__21 = game:GetService("Players");
local v22 = l__Players__21.LocalPlayer;
while not v22 do
	l__Players__21.ChildAdded:wait();
	v22 = l__Players__21.LocalPlayer;
end;
local v23 = 6;
if v13.ScreenGuiDisplayOrder ~= nil then
	v23 = v13.ScreenGuiDisplayOrder;
end;
local v24 = Instance.new("ScreenGui");
v24.Name = "Chat";
v24.ResetOnSpawn = false;
v24.DisplayOrder = v23;
v24.Parent = v22:WaitForChild("PlayerGui");
local v25 = require(script:WaitForChild("MessageLabelCreator"));
local v26 = require(script:WaitForChild("MessageLogDisplay"));
local v27 = require(script:WaitForChild("ChatChannel"));
local v28 = require(script:WaitForChild("ChatWindow")).new();
local v29 = require(script:WaitForChild("ChannelsBar")).new();
local v30 = v26.new();
local v31 = require(script:WaitForChild("CommandProcessor")).new();
local v32 = require(script:WaitForChild("ChatBar")).new(v31, v28);
v28:CreateGuiObjects(v24);
v28:RegisterChatBar(v32);
v28:RegisterChannelsBar(v29);
v28:RegisterMessageLogDisplay(v30);
v14:RegisterChatWindow(v28);
local v33 = require(script:WaitForChild("MessageSender"));
v33:RegisterSayMessageFunction(u3.SayMessageRequest);
if l__UserInputService__19.TouchEnabled then
	v32:SetTextLabelText(u1:Get("GameChat_ChatMain_ChatBarTextTouch", "Tap here to chat"));
else
	v32:SetTextLabelText(u1:Get("GameChat_ChatMain_ChatBarText", "To chat click here or press \"/\" key"));
end;
local l__script__5 = script;
spawn(function()
	local v34 = require(l__script__5:WaitForChild("CurveUtil"));
	local v35 = 1 / (v13.ChatAnimationFPS and 20);
	local v36 = tick();
	while true do
		local v37 = tick();
		local v38 = v34:DeltaTimeToTimescale(v37 - v36);
		if v38 ~= 0 then
			v28:Update(v38);
		end;
		v36 = v37;
		wait(v35);	
	end;
end);
function CheckIfPointIsInSquare(p6, p7, p8)
	local v39 = false;
	if p7.X <= p6.X then
		v39 = false;
		if p6.X <= p8.X then
			v39 = false;
			if p7.Y <= p6.Y then
				v39 = p6.Y <= p8.Y;
			end;
		end;
	end;
	return v39;
end;
local u6 = 0;
local u7 = false;
local u8 = Instance.new("BindableEvent");
function DoBackgroundFadeIn(p9)
	u6 = tick();
	u7 = false;
	u8:Fire();
	v28:FadeInBackground(p9 or v13.ChatDefaultFadeDuration);
	if v28:GetCurrentChannel() then
		local l__Scroller__40 = v30.Scroller;
		l__Scroller__40.ScrollingEnabled = true;
		l__Scroller__40.ScrollBarThickness = v26.ScrollBarThickness;
	end;
end;
function DoBackgroundFadeOut(p10)
	u6 = tick();
	u7 = true;
	u8:Fire();
	v28:FadeOutBackground(p10 or v13.ChatDefaultFadeDuration);
	if v28:GetCurrentChannel() then
		local l__Scroller__41 = v30.Scroller;
		l__Scroller__41.ScrollingEnabled = false;
		l__Scroller__41.ScrollBarThickness = 0;
	end;
end;
local u9 = 0;
local u10 = false;
function DoTextFadeIn(p11)
	u9 = tick();
	u10 = false;
	u8:Fire();
	v28:FadeInText((p11 or v13.ChatDefaultFadeDuration) * 0);
end;
function DoTextFadeOut(p12)
	u9 = tick();
	u10 = true;
	u8:Fire();
	v28:FadeOutText(p12 or v13.ChatDefaultFadeDuration);
end;
function DoFadeInFromNewInformation()
	DoTextFadeIn();
	if v13.ChatShouldFadeInFromNewInformation then
		DoBackgroundFadeIn();
	end;
end;
function InstantFadeIn()
	DoBackgroundFadeIn(0);
	DoTextFadeIn(0);
end;
function InstantFadeOut()
	DoBackgroundFadeOut(0);
	DoTextFadeOut(0);
end;
local u11 = nil;
local u12 = Instance.new("BindableEvent");
function UpdateFadingForMouseState(p13)
	u11 = p13;
	u12:Fire();
	if v32:IsFocused() then
		return;
	end;
	if p13 then

	else
		DoBackgroundFadeIn();
		return;
	end;
	DoBackgroundFadeIn();
	DoTextFadeIn();
end;
local u13 = Instance.new("BindableEvent");
spawn(function()
	while true do
		l__RunService__20.RenderStepped:wait();
		while not (not u11) or not (not v32:IsFocused()) do
			if u11 then
				u12.Event:wait();
			end;
			if v32:IsFocused() then
				u13.Event:wait();
			end;		
		end;
		if not u7 then
			if v13.ChatWindowBackgroundFadeOutTime < tick() - u6 then
				DoBackgroundFadeOut();
			end;
		elseif not u10 then
			if v13.ChatWindowTextFadeOutTime < tick() - u9 then
				DoTextFadeOut();
			end;
		else
			u8.Event:wait();
		end;	
	end;
end);
function getClassicChatEnabled()
	if v13.ClassicChatEnabled ~= nil then
		return v13.ClassicChatEnabled;
	end;
	return l__Players__21.ClassicChat;
end;
function getBubbleChatEnabled()
	if v13.BubbleChatEnabled ~= nil then
		return v13.BubbleChatEnabled;
	end;
	return l__Players__21.BubbleChat;
end;
function bubbleChatOnly()
	return not getClassicChatEnabled() and getBubbleChatEnabled();
end;
local u14 = {};
function UpdateMousePosition(p14)
	if u14.Visible then
		if u14.IsCoreGuiEnabled then
			if not u14.TopbarEnabled then
				if not v13.ChatOnWithTopBarOff then
					return;
				end;
			end;
		else
			return;
		end;
	else
		return;
	end;
	if bubbleChatOnly() then
		return;
	end;
	local l__AbsolutePosition__42 = v28.GuiObject.AbsolutePosition;
	local v43 = CheckIfPointIsInSquare(p14, l__AbsolutePosition__42, l__AbsolutePosition__42 + v28.GuiObject.AbsoluteSize);
	if v43 ~= u11 then
		UpdateFadingForMouseState(v43);
	end;
end;
l__UserInputService__19.InputChanged:connect(function(p15, p16)
	if p15.UserInputType == Enum.UserInputType.MouseMovement then
		UpdateMousePosition((Vector2.new(p15.Position.X, p15.Position.Y)));
	end;
end);
l__UserInputService__19.TouchTap:connect(function(p17, p18)
	UpdateMousePosition(p17[1]);
end);
l__UserInputService__19.TouchMoved:connect(function(p19, p20)
	UpdateMousePosition((Vector2.new(p19.Position.X, p19.Position.Y)));
end);
l__UserInputService__19.Changed:connect(function(p21)
	if p21 == "MouseBehavior" and l__UserInputService__19.MouseBehavior == Enum.MouseBehavior.LockCenter then
		local l__AbsolutePosition__44 = v28.GuiObject.AbsolutePosition;
		if CheckIfPointIsInSquare(v24.AbsoluteSize / 2, l__AbsolutePosition__44, l__AbsolutePosition__44 + v28.GuiObject.AbsoluteSize) then
			l__UserInputService__19.MouseBehavior = Enum.MouseBehavior.Default;
		end;
	end;
end);
UpdateFadingForMouseState(true);
UpdateFadingForMouseState(false);
local v45 = {
	Signal = function()
		local v46 = {};
		local u15 = nil;
		local u16 = nil;
		local u17 = Instance.new("BindableEvent");
		function v46.fire(p22, ...)
			u15 = { ... };
			u16 = select("#", ...);
			u17:Fire();
		end;
		function v46.connect(p23, p24)
			if not p24 then
				error("connect(nil)", 2);
			end;
			return u17.Event:connect(function()
				p24(unpack(u15, 1, u16));
			end);
		end;
		function v46.wait(p25)
			u17.Event:wait();
			assert(u15, "Missing arg data, likely due to :TweenSize/Position corrupting threadrefs.");
			return unpack(u15, 1, u16);
		end;
		return v46;
	end
};
function SetVisibility(p26)
	v28:SetVisible(p26);
	u14.VisibilityStateChanged:fire(p26);
	u14.Visible = p26;
	if u14.IsCoreGuiEnabled then
		if p26 then

		else
			InstantFadeOut();
			return;
		end;
	else
		return;
	end;
	InstantFadeIn();
end;
u14.TopbarEnabled = true;
u14.MessageCount = 0;
u14.Visible = true;
u14.IsCoreGuiEnabled = true;
function u14.ToggleVisibility(p27)
	SetVisibility(not v28:GetVisible());
end;
function u14.SetVisible(p28, p29)
	if v28:GetVisible() ~= p29 then
		SetVisibility(p29);
	end;
end;
function u14.FocusChatBar(p30)
	v32:CaptureFocus();
end;
function u14.EnterWhisperState(p31, p32)
	v32:EnterWhisperState(p32);
end;
function u14.GetVisibility(p33)
	return v28:GetVisible();
end;
function u14.GetMessageCount(p34)
	return p34.MessageCount;
end;
function u14.TopbarEnabledChanged(p35, p36)
	p35.TopbarEnabled = p36;
	p35.CoreGuiEnabled:fire(game:GetService("StarterGui"):GetCoreGuiEnabled(Enum.CoreGuiType.Chat));
end;
function u14.IsFocused(p37, p38)
	return v32:IsFocused();
end;
u14.ChatBarFocusChanged = v45.Signal();
u14.VisibilityStateChanged = v45.Signal();
u14.MessagesChanged = v45.Signal();
u14.MessagePosted = v45.Signal();
u14.CoreGuiEnabled = v45.Signal();
u14.ChatMakeSystemMessageEvent = v45.Signal();
u14.ChatWindowPositionEvent = v45.Signal();
u14.ChatWindowSizeEvent = v45.Signal();
u14.ChatBarDisabledEvent = v45.Signal();
function u14.fChatWindowPosition(p39)
	return v28.GuiObject.Position;
end;
function u14.fChatWindowSize(p40)
	return v28.GuiObject.Size;
end;
function u14.fChatBarDisabled(p41)
	return not v32:GetEnabled();
end;
if v1 then
	local u18 = true;
	l__ContextActionService__8:BindAction("ToggleChat", function(p42, p43, p44)
		if p42 == "ToggleChat" and p43 == Enum.UserInputState.Begin and u18 and p44.UserInputType == Enum.UserInputType.Keyboard then
			DoChatBarFocus();
		end;
	end, true, Enum.KeyCode.Slash);
else
	local u19 = true;
	function u14.SpecialKeyPressed(p45, p46, p47)
		if p46 == Enum.SpecialKey.ChatHotkey and u19 then
			DoChatBarFocus();
		end;
	end;
end;
u14.CoreGuiEnabled:connect(function(p48)
	u14.IsCoreGuiEnabled = p48;
	p48 = p48 and (u14.TopbarEnabled or v13.ChatOnWithTopBarOff);
	v28:SetCoreGuiEnabled(p48);
	if p48 then
		InstantFadeIn();
		return;
	end;
	v32:ReleaseFocus();
	InstantFadeOut();
end);
function trimTrailingSpaces(p49)
	local v47 = #p49;
	while true do
		if 0 < v47 then

		else
			break;
		end;
		if p49:find("^%s", v47) then

		else
			break;
		end;
		v47 = v47 - 1;	
	end;
	return p49:sub(1, v47);
end;
local u20 = false;
u14.ChatMakeSystemMessageEvent:connect(function(p50)
	if p50.Text and type(p50.Text) == "string" then
		while not u20 do
			wait();		
		end;
		local l__GeneralChannelName__48 = v13.GeneralChannelName;
		local v49 = v28:GetChannel(l__GeneralChannelName__48);
		if v49 then
			v49:AddMessageToChannel({
				ID = -1, 
				FromSpeaker = nil, 
				SpeakerUserId = 0, 
				OriginalChannel = l__GeneralChannelName__48, 
				IsFiltered = true, 
				MessageLength = string.len(p50.Text), 
				MessageLengthUtf8 = utf8.len(utf8.nfcnormalize(p50.Text)), 
				Message = trimTrailingSpaces(p50.Text), 
				MessageType = v12.MessageTypeSetCore, 
				Time = os.time(), 
				ExtraData = p50
			});
			v29:UpdateMessagePostedInChannel(l__GeneralChannelName__48);
			u14.MessageCount = u14.MessageCount + 1;
			u14.MessagesChanged:fire(u14.MessageCount);
		end;
	end;
end);
u14.ChatBarDisabledEvent:connect(function(p51)
	if u19 then
		v32:SetEnabled(not p51);
		if p51 then
			v32:ReleaseFocus();
		end;
	end;
end);
u14.ChatWindowSizeEvent:connect(function(p52)
	v28.GuiObject.Size = p52;
end);
u14.ChatWindowPositionEvent:connect(function(p53)
	v28.GuiObject.Position = p53;
end);
function DoChatBarFocus()
	if not v28:GetCoreGuiEnabled() then
		return;
	end;
	if not v32:GetEnabled() then
		return;
	end;
	if not v32:IsFocused() then
		if v32:GetVisible() then
			u14:SetVisible(true);
			InstantFadeIn();
			v32:CaptureFocus();
			u14.ChatBarFocusChanged:fire(true);
		end;
	end;
end;
u13.Event:connect(function(p54)
	u14.ChatBarFocusChanged:fire(p54);
end);
function DoSwitchCurrentChannel(p55)
	if v28:GetChannel(p55) then
		v28:SwitchCurrentChannel(p55);
	end;
end;
function SendMessageToSelfInTargetChannel(p56, p57, p58)
	local v50 = v28:GetChannel(p57);
	if v50 then
		v50:AddMessageToChannel({
			ID = -1, 
			FromSpeaker = nil, 
			SpeakerUserId = 0, 
			OriginalChannel = p57, 
			IsFiltered = true, 
			MessageLength = string.len(p56), 
			MessageLengthUtf8 = utf8.len(utf8.nfcnormalize(p56)), 
			Message = trimTrailingSpaces(p56), 
			MessageType = v12.MessageTypeSystem, 
			Time = os.time(), 
			ExtraData = p58
		});
	end;
end;
function chatBarFocused()
	if not u11 then
		DoBackgroundFadeIn();
		if u10 then
			DoTextFadeIn();
		end;
	end;
	u13:Fire(true);
end;
function chatBarFocusLost(p59, p60)
	DoBackgroundFadeIn();
	u13:Fire(false);
	if p59 then
		local v51 = v32:GetTextBox().Text;
		if v32:IsInCustomState() then
			local v52 = v32:GetCustomMessage();
			if v52 then
				v51 = v52;
			end;
			local v53 = v32:CustomStateProcessCompletedMessage(v51);
			v32:ResetCustomState();
			if v53 then
				return;
			end;
		end;
		v32:GetTextBox().Text = "";
		if v51 ~= "" then
			u14.MessagePosted:fire(v51);
			if not v31:ProcessCompletedChatMessage(v51, v28) then
				local v54 = nil;
				if v13.DisallowedWhiteSpace then
					local v55 = #v13.DisallowedWhiteSpace;
					local v56 = 1 - 1;
					while true do
						if v13.DisallowedWhiteSpace[v56] == "\t" then
							v51 = string.gsub(v51, v13.DisallowedWhiteSpace[v56], " ");
						else
							v51 = string.gsub(v51, v13.DisallowedWhiteSpace[v56], "");
						end;
						if 0 <= 1 then
							if v56 < v55 then

							else
								break;
							end;
						elseif v55 < v56 then

						else
							break;
						end;
						v56 = v56 + 1;					
					end;
				end;
				v54 = string.gsub(string.gsub(v51, "\n", ""), "[ ]+", " ");
				local v57 = v28:GetTargetMessageChannel();
				if v57 then
					v33:SendMessage(v54, v57);
					return;
				end;
				v33:SendMessage(v54, nil);
			end;
		end;
	end;
end;
local u21 = {};
function setupChatBarConnections()
	local v58 = #u21;
	local v59 = 1 - 1;
	while true do
		u21[v59]:Disconnect();
		if 0 <= 1 then
			if v59 < v58 then

			else
				break;
			end;
		elseif v58 < v59 then

		else
			break;
		end;
		v59 = v59 + 1;	
	end;
	u21 = {};
	table.insert(u21, (v32:GetTextBox().FocusLost:connect(chatBarFocusLost)));
	table.insert(u21, (v32:GetTextBox().Focused:connect(chatBarFocused)));
end;
setupChatBarConnections();
v32.GuiObjectsChanged:connect(setupChatBarConnections);
function getEchoMessagesInGeneral()
	if v13.EchoMessagesInGeneralChannel == nil then
		return true;
	end;
	return v13.EchoMessagesInGeneralChannel;
end;
u3.OnMessageDoneFiltering.OnClientEvent:connect(function(p61)
	if not v13.ShowUserOwnFilteredMessage and p61.FromSpeaker == v22.Name then
		return;
	end;
	local l__OriginalChannel__60 = p61.OriginalChannel;
	local v61 = v28:GetChannel(l__OriginalChannel__60);
	if v61 then
		v61:UpdateMessageFiltered(p61);
	end;
	if getEchoMessagesInGeneral() and v13.GeneralChannelName and l__OriginalChannel__60 ~= v13.GeneralChannelName then
		local v62 = v28:GetChannel(v13.GeneralChannelName);
		if v62 then
			v62:UpdateMessageFiltered(p61);
		end;
	end;
end);
u3.OnNewMessage.OnClientEvent:connect(function(p62, p63)
	local v63 = v28:GetChannel(p63);
	if v63 then
		v63:AddMessageToChannel(p62);
		if p62.FromSpeaker ~= v22.Name then
			v29:UpdateMessagePostedInChannel(p63);
		end;
		if getEchoMessagesInGeneral() and v13.GeneralChannelName and p63 ~= v13.GeneralChannelName then
			local v64 = v28:GetChannel(v13.GeneralChannelName);
			if v64 then
				v64:AddMessageToChannel(p62);
			end;
		end;
		u14.MessageCount = u14.MessageCount + 1;
		u14.MessagesChanged:fire(u14.MessageCount);
		DoFadeInFromNewInformation();
	end;
end);
u3.OnNewSystemMessage.OnClientEvent:connect(function(p64, p65)
	p65 = p65 and "System";
	local v65 = v28:GetChannel(p65);
	if v65 then
		v65:AddMessageToChannel(p64);
		v29:UpdateMessagePostedInChannel(p65);
		u14.MessageCount = u14.MessageCount + 1;
		u14.MessagesChanged:fire(u14.MessageCount);
		DoFadeInFromNewInformation();
		if getEchoMessagesInGeneral() and v13.GeneralChannelName and p65 ~= v13.GeneralChannelName then
			local v66 = v28:GetChannel(v13.GeneralChannelName);
			if v66 then
				v66:AddMessageToChannel(p64);
				return;
			end;
		end;
	else
		warn(string.format("Just received system message for channel I'm not in [%s]", p65));
	end;
end);
function HandleChannelJoined(p66, p67, p68, p69, p70, p71)
	if v28:GetChannel(p66) then
		v28:RemoveChannel(p66);
	end;
	if p66 == v13.GeneralChannelName then
		u20 = true;
	end;
	if p69 then
		v32:SetChannelNameColor(p66, p69);
	end;
	local v67 = v28:AddChannel(p66);
	if v67 then
		if p66 == v13.GeneralChannelName then
			DoSwitchCurrentChannel(p66);
		end;
		if p68 then
			local v68 = 1;
			if v13.MessageHistoryLengthPerChannel < #p68 then
				v68 = #p68 - v13.MessageHistoryLengthPerChannel;
			end;
			local v69 = #p68;
			local v70 = v68 - 1;
			while true do
				v67:AddMessageToChannel(p68[v70]);
				if 0 <= 1 then
					if v70 < v69 then

					else
						break;
					end;
				elseif v69 < v70 then

				else
					break;
				end;
				v70 = v70 + 1;			
			end;
			if getEchoMessagesInGeneral() then
				if p70 then
					if v13.GeneralChannelName then
						if p66 ~= v13.GeneralChannelName then
							local v71 = v28:GetChannel(v13.GeneralChannelName);
							if v71 then
								v71:AddMessagesToChannelByTimeStamp(p68, v68);
							end;
						end;
					end;
				end;
			end;
		end;
		if p67 ~= "" then
			local v72 = {
				ID = -1, 
				FromSpeaker = nil, 
				SpeakerUserId = 0, 
				OriginalChannel = p66, 
				IsFiltered = true, 
				MessageLength = string.len(p67), 
				MessageLengthUtf8 = utf8.len(utf8.nfcnormalize(p67)), 
				Message = trimTrailingSpaces(p67), 
				MessageType = v12.MessageTypeWelcome, 
				Time = os.time(), 
				ExtraData = nil
			};
			v67:AddMessageToChannel(v72);
			if getEchoMessagesInGeneral() then
				if p71 then
					if not v13.ShowChannelsBar then
						if p66 ~= v13.GeneralChannelName then
							local v73 = v28:GetChannel(v13.GeneralChannelName);
							if v73 then
								v73:AddMessageToChannel(v72);
							end;
						end;
					end;
				end;
			end;
		end;
		DoFadeInFromNewInformation();
	end;
end;
u3.OnChannelJoined.OnClientEvent:connect(function(p72, p73, p74, p75)
	HandleChannelJoined(p72, p73, p74, p75, false, true);
end);
u3.OnChannelLeft.OnClientEvent:connect(function(p76)
	v28:RemoveChannel(p76);
	DoFadeInFromNewInformation();
end);
u3.OnMuted.OnClientEvent:connect(function(p77)

end);
u3.OnUnmuted.OnClientEvent:connect(function(p78)

end);
u3.OnMainChannelSet.OnClientEvent:connect(function(p79)
	DoSwitchCurrentChannel(p79);
end);
coroutine.wrap(function()
	local l__ChannelNameColorUpdated__74 = v9:WaitForChild("ChannelNameColorUpdated", 5);
	if l__ChannelNameColorUpdated__74 then
		l__ChannelNameColorUpdated__74.OnClientEvent:connect(function(p80, p81)
			v32:SetChannelNameColor(p80, p81);
		end);
	end;
end)();
local u22 = nil;
local u23 = nil;
local u24 = nil;
local u25 = nil;
pcall(function()
	u22 = l__StarterGui__7:GetCore("PlayerBlockedEvent");
	u23 = l__StarterGui__7:GetCore("PlayerMutedEvent");
	u24 = l__StarterGui__7:GetCore("PlayerUnblockedEvent");
	u25 = l__StarterGui__7:GetCore("PlayerUnmutedEvent");
end);
function SendSystemMessageToSelf(p82)
	local v75 = v28:GetCurrentChannel();
	if v75 then
		v75:AddMessageToChannel({
			ID = -1, 
			FromSpeaker = nil, 
			SpeakerUserId = 0, 
			OriginalChannel = v75.Name, 
			IsFiltered = true, 
			MessageLength = string.len(p82), 
			MessageLengthUtf8 = utf8.len(utf8.nfcnormalize(p82)), 
			Message = trimTrailingSpaces(p82), 
			MessageType = v12.MessageTypeSystem, 
			Time = os.time(), 
			ExtraData = nil
		});
	end;
end;
function MutePlayer(p83)
	local l__MutePlayerRequest__76 = v9:FindFirstChild("MutePlayerRequest");
	if l__MutePlayerRequest__76 then

	else
		return false;
	end;
	return l__MutePlayerRequest__76:InvokeServer(p83.Name);
end;
if u22 then
	u22.Event:connect(function(p84)
		if MutePlayer(p84) then
			if v13.PlayerDisplayNamesEnabled then
				local v77 = p84.DisplayName;
			else
				v77 = p84.Name;
			end;
			SendSystemMessageToSelf(u1:Get("GameChat_ChatMain_SpeakerHasBeenBlocked", string.format("Speaker '%s' has been blocked.", v77), {
				RBX_NAME = v77
			}));
		end;
	end);
end;
if u23 then
	u23.Event:connect(function(p85)
		if MutePlayer(p85) then
			if v13.PlayerDisplayNamesEnabled then
				local v78 = p85.DisplayName;
			else
				v78 = p85.Name;
			end;
			SendSystemMessageToSelf(u1:Get("GameChat_ChatMain_SpeakerHasBeenMuted", string.format("Speaker '%s' has been muted.", v78), {
				RBX_NAME = v78
			}));
		end;
	end);
end;
function UnmutePlayer(p86)
	local l__UnMutePlayerRequest__79 = v9:FindFirstChild("UnMutePlayerRequest");
	if l__UnMutePlayerRequest__79 then

	else
		return false;
	end;
	return l__UnMutePlayerRequest__79:InvokeServer(p86.Name);
end;
if u24 then
	u24.Event:connect(function(p87)
		if UnmutePlayer(p87) then
			if v13.PlayerDisplayNamesEnabled then
				local v80 = p87.DisplayName;
			else
				v80 = p87.Name;
			end;
			SendSystemMessageToSelf(u1:Get("GameChat_ChatMain_SpeakerHasBeenUnBlocked", string.format("Speaker '%s' has been unblocked.", v80), {
				RBX_NAME = v80
			}));
		end;
	end);
end;
if u25 then
	u25.Event:connect(function(p88)
		if UnmutePlayer(p88) then
			if v13.PlayerDisplayNamesEnabled then
				local v81 = p88.DisplayName;
			else
				v81 = p88.Name;
			end;
			SendSystemMessageToSelf(u1:Get("GameChat_ChatMain_SpeakerHasBeenUnMuted", string.format("Speaker '%s' has been unmuted.", v81), {
				RBX_NAME = v81
			}));
		end;
	end);
end;
spawn(function()
	if v22.UserId > 0 then
		pcall(function()
			local v82 = l__StarterGui__7:GetCore("GetBlockedUserIds");
			if #v82 > 0 then
				local l__SetBlockedUserIdsRequest__83 = v9:FindFirstChild("SetBlockedUserIdsRequest");
				if l__SetBlockedUserIdsRequest__83 then
					l__SetBlockedUserIdsRequest__83:FireServer(v82);
				end;
			end;
		end);
	end;
end);
spawn(function()
	local v84, v85 = pcall(function()
		return l__Chat__6:CanUserChatAsync(v22.UserId);
	end);
	if v84 then
		u19 = l__RunService__20:IsStudio() and v85;
	end;
end);
local v86 = u3.GetInitDataRequest:InvokeServer();
for v87, v88 in pairs(v86.Channels) do
	if v88[1] == v13.GeneralChannelName then
		HandleChannelJoined(v88[1], v88[2], v88[3], v88[4], true, false);
	end;
end;
for v89, v90 in pairs(v86.Channels) do
	if v90[1] ~= v13.GeneralChannelName then
		HandleChannelJoined(v90[1], v90[2], v90[3], v90[4], true, false);
	end;
end;
return u14;
