686

Untitled

686
Nov 7th, 2021
88
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 152.12 KB | None | 0 0
  1. chat service:
  2. -- Script GUID: {0d165940-e1dc-4850-b877-33cb51d9bcb7}
  3. -- Decompiled with the Synapse X Luau decompiler.
  4.  
  5. local v1 = {};
  6. local l__RunService__2 = game:GetService("RunService");
  7. local l__Chat__3 = game:GetService("Chat");
  8. local l__ClientChatModules__4 = l__Chat__3:WaitForChild("ClientChatModules");
  9. local l__Parent__5 = script.Parent;
  10. local l__ClientChatModules__6 = l__Chat__3:WaitForChild("ClientChatModules");
  11. local v7 = {
  12. ChatColor = require(l__ClientChatModules__6:WaitForChild("ChatSettings")).ErrorMessageTextColor or Color3.fromRGB(245, 50, 50)
  13. };
  14. local v8 = require(l__ClientChatModules__6:WaitForChild("ChatConstants"));
  15. local v9 = require(l__Parent__5:WaitForChild("ChatChannel"));
  16. local v10 = require(l__Parent__5:WaitForChild("Speaker"));
  17. local v11 = require(l__Parent__5:WaitForChild("Util"));
  18. local u1 = nil;
  19. pcall(function()
  20. u1 = require(game:GetService("Chat").ClientChatModules.ChatLocalization);
  21. end);
  22. u1 = u1 or {};
  23. if not u1.FormatMessageToSend or not u1.LocalizeFormattedMessage then
  24. function u1.FormatMessageToSend(p1, p2, p3)
  25. return p3;
  26. end;
  27. end;
  28. local v12 = {};
  29. v12.__index = v12;
  30. function v12.AddChannel(p4, p5, p6)
  31. if p4.ChatChannels[p5:lower()] then
  32. error(string.format("Channel %q alrady exists.", p5));
  33. end;
  34. local v13 = v9.new(p4, p5);
  35. p4.ChatChannels[p5:lower()] = v13;
  36. v13:RegisterProcessCommandsFunction("default_commands", function(p7, p8)
  37. if p8:lower() ~= "/leave" then
  38. return false;
  39. end;
  40. local v14 = p4:GetChannel(p5);
  41. local v15 = p4:GetSpeaker(p7);
  42. if v14 and v15 then
  43. if v14.Leavable then
  44. v15:LeaveChannel(p5);
  45. v15:SendSystemMessage(u1:FormatMessageToSend("GameChat_ChatService_YouHaveLeftChannel", string.format("You have left channel '%s'", p5), "RBX_NAME", p5), "System");
  46. else
  47. v15:SendSystemMessage(u1:FormatMessageToSend("GameChat_ChatService_CannotLeaveChannel", "You cannot leave this channel."), p5);
  48. end;
  49. end;
  50. return true;
  51. end, v8.HighPriority);
  52. local v16, v17 = pcall(function()
  53. p4.eChannelAdded:Fire(p5);
  54. end);
  55. if not v16 and v17 then
  56. print("Error addding channel: " .. v17);
  57. end;
  58. if p6 ~= nil then
  59. v13.AutoJoin = p6;
  60. if p6 then
  61. for v18, v19 in pairs(p4.Speakers) do
  62. v19:JoinChannel(p5);
  63. end;
  64. end;
  65. end;
  66. return v13;
  67. end;
  68. function v12.RemoveChannel(p9, p10)
  69. local v20 = nil;
  70. if p9.ChatChannels[p10:lower()] then
  71. local l__Name__21 = p9.ChatChannels[p10:lower()].Name;
  72. p9.ChatChannels[p10:lower()]:InternalDestroy();
  73. p9.ChatChannels[p10:lower()] = nil;
  74. local v22 = nil;
  75. v22, v20 = pcall(function()
  76. p9.eChannelRemoved:Fire(l__Name__21);
  77. end);
  78. if not (not v22) or not v20 then
  79. return;
  80. end;
  81. else
  82. warn(string.format("Channel %q does not exist.", p10));
  83. return;
  84. end;
  85. print("Error removing channel: " .. v20);
  86. end;
  87. function v12.GetChannel(p11, p12)
  88. return p11.ChatChannels[p12:lower()];
  89. end;
  90. function v12.AddSpeaker(p13, p14)
  91. if p13.Speakers[p14:lower()] then
  92. error("Speaker \"" .. p14 .. "\" already exists!");
  93. end;
  94. local v23 = v10.new(p13, p14);
  95. p13.Speakers[p14:lower()] = v23;
  96. local v24, v25 = pcall(function()
  97. p13.eSpeakerAdded:Fire(p14);
  98. end);
  99. if not v24 and v25 then
  100. print("Error adding speaker: " .. v25);
  101. end;
  102. return v23;
  103. end;
  104. function v12.InternalUnmuteSpeaker(p15, p16)
  105. for v26, v27 in pairs(p15.ChatChannels) do
  106. if v27:IsSpeakerMuted(p16) then
  107. v27:UnmuteSpeaker(p16);
  108. end;
  109. end;
  110. end;
  111. function v12.RemoveSpeaker(p17, p18)
  112. local v28 = nil;
  113. if p17.Speakers[p18:lower()] then
  114. local l__Name__29 = p17.Speakers[p18:lower()].Name;
  115. p17:InternalUnmuteSpeaker(l__Name__29);
  116. p17.Speakers[p18:lower()]:InternalDestroy();
  117. p17.Speakers[p18:lower()] = nil;
  118. local v30 = nil;
  119. v30, v28 = pcall(function()
  120. p17.eSpeakerRemoved:Fire(l__Name__29);
  121. end);
  122. if not (not v30) or not v28 then
  123. return;
  124. end;
  125. else
  126. warn("Speaker \"" .. p18 .. "\" does not exist!");
  127. return;
  128. end;
  129. print("Error removing speaker: " .. v28);
  130. end;
  131. function v12.GetSpeaker(p19, p20)
  132. return p19.Speakers[p20:lower()];
  133. end;
  134. function v12.GetSpeakerByUserOrDisplayName(p21, p22)
  135. local v31 = p21.Speakers[p22:lower()];
  136. if v31 then
  137. return v31;
  138. end;
  139. for v32, v33 in pairs(p21.Speakers) do
  140. local v34 = v33:GetPlayer();
  141. if v34 and v34.DisplayName:lower() == p22:lower() then
  142. return v33;
  143. end;
  144. end;
  145. end;
  146. function v12.GetChannelList(p23)
  147. local v35 = {};
  148. for v36, v37 in pairs(p23.ChatChannels) do
  149. if not v37.Private then
  150. table.insert(v35, v37.Name);
  151. end;
  152. end;
  153. return v35;
  154. end;
  155. function v12.GetAutoJoinChannelList(p24)
  156. local v38 = {};
  157. for v39, v40 in pairs(p24.ChatChannels) do
  158. if v40.AutoJoin then
  159. table.insert(v38, v40);
  160. end;
  161. end;
  162. return v38;
  163. end;
  164. function v12.GetSpeakerList(p25)
  165. local v41 = {};
  166. for v42, v43 in pairs(p25.Speakers) do
  167. table.insert(v41, v43.Name);
  168. end;
  169. return v41;
  170. end;
  171. function v12.SendGlobalSystemMessage(p26, p27)
  172. for v44, v45 in pairs(p26.Speakers) do
  173. v45:SendSystemMessage(p27, nil);
  174. end;
  175. end;
  176. function v12.RegisterFilterMessageFunction(p28, p29, p30, p31)
  177. if p28.FilterMessageFunctions:HasFunction(p29) then
  178. error(string.format("FilterMessageFunction '%s' already exists", p29));
  179. end;
  180. p28.FilterMessageFunctions:AddFunction(p29, p30, p31);
  181. end;
  182. function v12.FilterMessageFunctionExists(p32, p33)
  183. return p32.FilterMessageFunctions:HasFunction(p33);
  184. end;
  185. function v12.UnregisterFilterMessageFunction(p34, p35)
  186. if not p34.FilterMessageFunctions:HasFunction(p35) then
  187. error(string.format("FilterMessageFunction '%s' does not exists", p35));
  188. end;
  189. p34.FilterMessageFunctions:RemoveFunction(p35);
  190. end;
  191. function v12.RegisterProcessCommandsFunction(p36, p37, p38, p39)
  192. if p36.ProcessCommandsFunctions:HasFunction(p37) then
  193. error(string.format("ProcessCommandsFunction '%s' already exists", p37));
  194. end;
  195. p36.ProcessCommandsFunctions:AddFunction(p37, p38, p39);
  196. end;
  197. function v12.ProcessCommandsFunctionExists(p40, p41)
  198. return p40.ProcessCommandsFunctions:HasFunction(p41);
  199. end;
  200. function v12.UnregisterProcessCommandsFunction(p42, p43)
  201. if not p42.ProcessCommandsFunctions:HasFunction(p43) then
  202. error(string.format("ProcessCommandsFunction '%s' does not exist", p43));
  203. end;
  204. p42.ProcessCommandsFunctions:RemoveFunction(p43);
  205. end;
  206. local u2 = 0;
  207. local u3 = 0;
  208. local u4 = 0;
  209. function v12.InternalNotifyFilterIssue(p44)
  210. if tick() - u2 > 60 then
  211. u3 = 0;
  212. end;
  213. u3 = u3 + 1;
  214. u2 = tick();
  215. if u3 >= 3 and tick() - u4 > 60 then
  216. u4 = tick();
  217. local v46 = p44:GetChannel("System");
  218. if v46 then
  219. v46:SendSystemMessage(u1:FormatMessageToSend("GameChat_ChatService_ChatFilterIssues", "The chat filter is currently experiencing issues and messages may be slow to appear."), v7);
  220. end;
  221. end;
  222. end;
  223. local function u5(p45)
  224. return string.len((string.gsub(p45, " ", ""))) == 0;
  225. end;
  226. local u6 = { 0.05, 0.1, 0.2 };
  227. local u7 = {};
  228. function v12.InternalApplyRobloxFilter(p46, p47, p48, p49)
  229. if not l__RunService__2:IsServer() or not (not l__RunService__2:IsStudio()) then
  230. if not u7[p48] then
  231. u7[p48] = true;
  232. wait();
  233. end;
  234. return p48;
  235. end;
  236. local v47 = p46:GetSpeaker(p47);
  237. local v48 = p49 and p46:GetSpeaker(p49);
  238. if v47 == nil then
  239. return nil;
  240. end;
  241. local v49 = v47:GetPlayer();
  242. local v50 = v48 and v48:GetPlayer();
  243. if v49 == nil then
  244. return p48;
  245. end;
  246. if u5(p48) then
  247. return p48;
  248. end;
  249. local v51 = tick();
  250. local v52 = 0;
  251. while true do
  252. local v53 = nil;
  253. local v54 = nil;
  254. v54, v53 = pcall(function()
  255. if v50 then
  256. return l__Chat__3:FilterStringAsync(p48, v49, v50);
  257. end;
  258. return l__Chat__3:FilterStringForBroadcast(p48, v49);
  259. end);
  260. if v54 then
  261. return v53;
  262. end;
  263. warn("Error filtering message:", v53);
  264. v52 = v52 + 1;
  265. if v52 > 3 then
  266. break;
  267. end;
  268. if tick() - v51 > 60 then
  269. break;
  270. end;
  271. local v55 = u6[math.min(#u6, v52)];
  272. wait(v55 + (math.random() * 2 - 1) * v55);
  273. end;
  274. p46:InternalNotifyFilterIssue();
  275. return nil;
  276. end;
  277. function v12.InternalApplyRobloxFilterNewAPI(p50, p51, p52, p53)
  278. local v56 = nil;
  279. if not l__RunService__2:IsServer() or not (not l__RunService__2:IsStudio()) then
  280. wait();
  281. return true, false, p52;
  282. end;
  283. local v57 = p50:GetSpeaker(p51);
  284. if v57 == nil then
  285. return false, nil, nil;
  286. end;
  287. local v58 = v57:GetPlayer();
  288. if v58 == nil then
  289. return true, false, p52;
  290. end;
  291. if u5(p52) then
  292. return true, false, p52;
  293. end;
  294. local v59 = nil;
  295. v59, v56 = pcall(function()
  296. return game:GetService("TextService"):FilterStringAsync(p52, v58.UserId, p53);
  297. end);
  298. if v59 then
  299. return true, true, v56;
  300. end;
  301. warn("Error filtering message:", p52, v56);
  302. p50:InternalNotifyFilterIssue();
  303. return false, nil, nil;
  304. end;
  305. function v12.InternalDoMessageFilter(p54, p55, p56, p57)
  306. for v60, v61, v62 in p54.FilterMessageFunctions:GetIterator(), nil do
  307. local v63, v64 = pcall(function()
  308. v61(p55, p56, p57);
  309. end);
  310. if not v63 then
  311. warn(string.format("DoMessageFilter Function '%s' failed for reason: %s", v60, v64));
  312. end;
  313. end;
  314. end;
  315. function v12.InternalDoProcessCommands(p58, p59, p60, p61)
  316. local v65 = p58.ProcessCommandsFunctions:GetIterator();
  317. local v66 = nil;
  318. local v67 = nil;
  319. while true do
  320. local v68 = nil;
  321. local v69, v70, v71 = v65(v66, v67);
  322. if not v69 then
  323. break;
  324. end;
  325. v67 = v69;
  326. local v72 = nil;
  327. v72, v68 = pcall(function()
  328. local v73 = v70(p59, p60, p61);
  329. if type(v73) ~= "boolean" then
  330. error("Process command functions must return a bool");
  331. end;
  332. return v73;
  333. end);
  334. if not v72 then
  335. warn(string.format("DoProcessCommands Function '%s' failed for reason: %s", v69, v68));
  336. elseif v68 then
  337. return true;
  338. end;
  339. end;
  340. return false;
  341. end;
  342. function v12.InternalGetUniqueMessageId(p62)
  343. local l__MessageIdCounter__74 = p62.MessageIdCounter;
  344. p62.MessageIdCounter = l__MessageIdCounter__74 + 1;
  345. return l__MessageIdCounter__74;
  346. end;
  347. function v12.InternalAddSpeakerWithPlayerObject(p63, p64, p65, p66)
  348. if p63.Speakers[p64:lower()] then
  349. error("Speaker \"" .. p64 .. "\" already exists!");
  350. end;
  351. local v75 = v10.new(p63, p64);
  352. v75:InternalAssignPlayerObject(p65);
  353. p63.Speakers[p64:lower()] = v75;
  354. if p66 then
  355. local v76, v77 = pcall(function()
  356. p63.eSpeakerAdded:Fire(p64);
  357. end);
  358. if not v76 and v77 then
  359. print("Error adding speaker: " .. v77);
  360. end;
  361. end;
  362. return v75;
  363. end;
  364. function v12.InternalFireSpeakerAdded(p67, p68)
  365. local v78, v79 = pcall(function()
  366. p67.eSpeakerAdded:Fire(p68);
  367. end);
  368. if not v78 and v79 then
  369. print("Error firing speaker added: " .. v79);
  370. end;
  371. end;
  372. function v1.new()
  373. local v80 = setmetatable({}, v12);
  374. v80.MessageIdCounter = 0;
  375. v80.ChatChannels = {};
  376. v80.Speakers = {};
  377. v80.FilterMessageFunctions = v11:NewSortedFunctionContainer();
  378. v80.ProcessCommandsFunctions = v11:NewSortedFunctionContainer();
  379. v80.eChannelAdded = Instance.new("BindableEvent");
  380. v80.eChannelRemoved = Instance.new("BindableEvent");
  381. v80.eSpeakerAdded = Instance.new("BindableEvent");
  382. v80.eSpeakerRemoved = Instance.new("BindableEvent");
  383. v80.ChannelAdded = v80.eChannelAdded.Event;
  384. v80.ChannelRemoved = v80.eChannelRemoved.Event;
  385. v80.SpeakerAdded = v80.eSpeakerAdded.Event;
  386. v80.SpeakerRemoved = v80.eSpeakerRemoved.Event;
  387. v80.ChatServiceMajorVersion = 0;
  388. v80.ChatServiceMinorVersion = 5;
  389. return v80;
  390. end;
  391. return v1.new();
  392. Chat Channel:
  393. -- Script GUID: {42b41888-1bdd-47cb-9f12-c569ee186020}
  394. -- Decompiled with the Synapse X Luau decompiler.
  395.  
  396. local v1, v2 = pcall(function()
  397. return UserSettings():IsUserFeatureEnabled("UserShouldMuteUnfilteredMessage");
  398. end);
  399. local v3 = {};
  400. local l__Chat__4 = game:GetService("Chat");
  401. local l__RunService__5 = game:GetService("RunService");
  402. local l__ClientChatModules__6 = l__Chat__4:WaitForChild("ClientChatModules");
  403. local v7 = require(l__ClientChatModules__6:WaitForChild("ChatSettings"));
  404. local v8 = require(l__ClientChatModules__6:WaitForChild("ChatConstants"));
  405. local v9 = require(script.Parent:WaitForChild("Util"));
  406. local u1 = nil;
  407. pcall(function()
  408. u1 = require(game:GetService("Chat").ClientChatModules.ChatLocalization);
  409. end);
  410. u1 = u1 or {};
  411. if not u1.FormatMessageToSend or not u1.LocalizeFormattedMessage then
  412. function u1.FormatMessageToSend(p1, p2, p3)
  413. return p3;
  414. end;
  415. end;
  416. local v10 = {};
  417. v10.__index = v10;
  418. function v10.SendSystemMessage(p4, p5, p6)
  419. local u2 = p4:InternalCreateMessageObject(p5, nil, true, p6);
  420. local v11, v12 = pcall(function()
  421. p4.eMessagePosted:Fire(u2);
  422. end);
  423. if not v11 and v12 then
  424. print("Error posting message: " .. v12);
  425. end;
  426. p4:InternalAddMessageToHistoryLog(u2);
  427. for v13, v14 in pairs(p4.Speakers) do
  428. v14:InternalSendSystemMessage(u2, p4.Name);
  429. end;
  430. return u2;
  431. end;
  432. function v10.SendSystemMessageToSpeaker(p7, p8, p9, p10)
  433. local v15 = p7.Speakers[p9];
  434. if v15 then
  435. v15:InternalSendSystemMessage(p7:InternalCreateMessageObject(p8, nil, true, p10), p7.Name);
  436. return;
  437. end;
  438. if l__RunService__5:IsStudio() then
  439. warn(string.format("Speaker '%s' is not in channel '%s' and cannot be sent a system message", p9, p7.Name));
  440. end;
  441. end;
  442. function v10.SendMessageObjToFilters(p11, p12, p13, p14)
  443. p13.Message = p12;
  444. p11:InternalDoMessageFilter(p14.Name, p13, p11.Name);
  445. p11.ChatService:InternalDoMessageFilter(p14.Name, p13, p11.Name);
  446. p13.Message = p13.Message;
  447. return p13.Message;
  448. end;
  449. function v10.CanCommunicateByUserId(p15, p16, p17)
  450. if l__RunService__5:IsStudio() then
  451. return true;
  452. end;
  453. if p16 == 0 or p17 == 0 then
  454. return true;
  455. end;
  456. local v16, v17 = pcall(function()
  457. return l__Chat__4:CanUsersChatAsync(p16, p17);
  458. end);
  459. return v16 or v17;
  460. end;
  461. function v10.CanCommunicate(p18, p19, p20)
  462. local v18 = nil;
  463. local v19 = p19:GetPlayer();
  464. v18 = p20:GetPlayer();
  465. if not v19 or not v18 then
  466. return true;
  467. end;
  468. return p18:CanCommunicateByUserId(v19.UserId, v18.UserId);
  469. end;
  470. function v10.SendMessageToSpeaker(p21, p22, p23, p24, p25)
  471. local v20 = p21.Speakers[p23];
  472. local v21 = p21.ChatService:GetSpeaker(p24);
  473. if v20 and v21 then
  474. if v20:IsSpeakerMuted(p24) then
  475. return;
  476. end;
  477. if not p21:CanCommunicate(v20, v21) then
  478. return;
  479. end;
  480. local v22 = p21:InternalCreateMessageObject(p22, p24, p23 == p24, p25);
  481. p22 = p21:SendMessageObjToFilters(p22, v22, p24);
  482. v20:InternalSendMessage(v22, p21.Name);
  483. local v23, v24, v25 = p21.ChatService:InternalApplyRobloxFilterNewAPI(v22.FromSpeaker, p22, p21.Private and Enum.TextFilterContext.PrivateChat or Enum.TextFilterContext.PublicChat);
  484. if v23 then
  485. v22.FilterResult = v25;
  486. v22.IsFilterResult = v24;
  487. v22.IsFiltered = true;
  488. v20:InternalSendFilteredMessageWithFilterResult(v22, p21.Name);
  489. return;
  490. end;
  491. elseif l__RunService__5:IsStudio() then
  492. warn(string.format("Speaker '%s' is not in channel '%s' and cannot be sent a message", p23, p21.Name));
  493. end;
  494. end;
  495. function v10.KickSpeaker(p26, p27, p28)
  496. local v26 = nil;
  497. local v27 = p26.ChatService:GetSpeaker(p27);
  498. if not v27 then
  499. error("Speaker \"" .. p27 .. "\" does not exist!");
  500. end;
  501. v26 = v27:GetNameForDisplay();
  502. if p28 then
  503. local v28 = string.format("You were kicked from '%s' for the following reason(s): %s", p26.Name, p28);
  504. local v29 = string.format("%s was kicked for the following reason(s): %s", v26, p28);
  505. else
  506. v28 = string.format("You were kicked from '%s'", p26.Name);
  507. v29 = string.format("%s was kicked", v26);
  508. end;
  509. p26:SendSystemMessageToSpeaker(v28, p27);
  510. v27:LeaveChannel(p26.Name);
  511. p26:SendSystemMessage(v29);
  512. end;
  513. function v10.MuteSpeaker(p29, p30, p31, p32)
  514. local v30 = p29.ChatService:GetSpeaker(p30);
  515. if not v30 then
  516. error("Speaker \"" .. p30 .. "\" does not exist!");
  517. end;
  518. if p32 == 0 or p32 == nil then
  519. local v31 = 0;
  520. else
  521. v31 = os.time() + p32;
  522. end;
  523. p29.Mutes[p30:lower()] = v31;
  524. if p31 then
  525. p29:SendSystemMessage(string.format("%s was muted for the following reason(s): %s", v30:GetNameForDisplay(), p31));
  526. end;
  527. local v32, v33 = pcall(function()
  528. p29.eSpeakerMuted:Fire(p30, p31, p32);
  529. end);
  530. if not v32 and v33 then
  531. print("Error mutting speaker: " .. v33);
  532. end;
  533. local v34 = p29.ChatService:GetSpeaker(p30);
  534. if v34 then
  535. local v35, v36 = pcall(function()
  536. v34.eMuted:Fire(p29.Name, p31, p32);
  537. end);
  538. if not v35 and v36 then
  539. print("Error mutting speaker: " .. v36);
  540. end;
  541. end;
  542. end;
  543. function v10.UnmuteSpeaker(p33, p34)
  544. if not p33.ChatService:GetSpeaker(p34) then
  545. error("Speaker \"" .. p34 .. "\" does not exist!");
  546. end;
  547. p33.Mutes[p34:lower()] = nil;
  548. local v37, v38 = pcall(function()
  549. p33.eSpeakerUnmuted:Fire(p34);
  550. end);
  551. if not v37 and v38 then
  552. print("Error unmuting speaker: " .. v38);
  553. end;
  554. local v39 = p33.ChatService:GetSpeaker(p34);
  555. if v39 then
  556. local v40, v41 = pcall(function()
  557. v39.eUnmuted:Fire(p33.Name);
  558. end);
  559. if not v40 and v41 then
  560. print("Error unmuting speaker: " .. v41);
  561. end;
  562. end;
  563. end;
  564. function v10.IsSpeakerMuted(p35, p36)
  565. return p35.Mutes[p36:lower()] ~= nil;
  566. end;
  567. function v10.GetSpeakerList(p37)
  568. local v42 = {};
  569. for v43, v44 in pairs(p37.Speakers) do
  570. table.insert(v42, v44.Name);
  571. end;
  572. return v42;
  573. end;
  574. function v10.RegisterFilterMessageFunction(p38, p39, p40, p41)
  575. if p38.FilterMessageFunctions:HasFunction(p39) then
  576. error(string.format("FilterMessageFunction '%s' already exists", p39));
  577. end;
  578. p38.FilterMessageFunctions:AddFunction(p39, p40, p41);
  579. end;
  580. function v10.FilterMessageFunctionExists(p42, p43)
  581. return p42.FilterMessageFunctions:HasFunction(p43);
  582. end;
  583. function v10.UnregisterFilterMessageFunction(p44, p45)
  584. if not p44.FilterMessageFunctions:HasFunction(p45) then
  585. error(string.format("FilterMessageFunction '%s' does not exists", p45));
  586. end;
  587. p44.FilterMessageFunctions:RemoveFunction(p45);
  588. end;
  589. function v10.RegisterProcessCommandsFunction(p46, p47, p48, p49)
  590. if p46.ProcessCommandsFunctions:HasFunction(p47) then
  591. error(string.format("ProcessCommandsFunction '%s' already exists", p47));
  592. end;
  593. p46.ProcessCommandsFunctions:AddFunction(p47, p48, p49);
  594. end;
  595. function v10.ProcessCommandsFunctionExists(p50, p51)
  596. return p50.ProcessCommandsFunctions:HasFunction(p51);
  597. end;
  598. function v10.UnregisterProcessCommandsFunction(p52, p53)
  599. if not p52.ProcessCommandsFunctions:HasFunction(p53) then
  600. error(string.format("ProcessCommandsFunction '%s' does not exist", p53));
  601. end;
  602. p52.ProcessCommandsFunctions:RemoveFunction(p53);
  603. end;
  604. local function u3(p54)
  605. local v45 = {};
  606. for v46, v47 in pairs(p54) do
  607. v45[v46] = v47;
  608. end;
  609. return v45;
  610. end;
  611. function v10.GetHistoryLog(p55)
  612. return u3(p55.ChatHistory);
  613. end;
  614. function v10.GetHistoryLogForSpeaker(p56, p57)
  615. local v48 = -1;
  616. local v49 = p57:GetPlayer();
  617. if v49 then
  618. v48 = v49.UserId;
  619. end;
  620. local v50 = {};
  621. for v51 = 1, #p56.ChatHistory do
  622. if p56:CanCommunicateByUserId(v48, p56.ChatHistory[v51].SpeakerUserId) then
  623. local v52 = u3(p56.ChatHistory[v51]);
  624. if v52.MessageType == v8.MessageTypeDefault or v52.MessageType == v8.MessageTypeMeCommand then
  625. local v53 = nil;
  626. v53 = v52.FilterResult;
  627. if v52.IsFilterResult then
  628. if v49 then
  629. v52.Message = v53:GetChatForUserAsync(v49.UserId);
  630. else
  631. v52.Message = v53:GetNonChatStringForBroadcastAsync();
  632. end;
  633. else
  634. v52.Message = v53;
  635. end;
  636. end;
  637. table.insert(v50, v52);
  638. end;
  639. end;
  640. return v50;
  641. end;
  642. function v10.InternalDestroy(p58)
  643. for v54, v55 in pairs(p58.Speakers) do
  644. v55:LeaveChannel(p58.Name);
  645. end;
  646. p58.eDestroyed:Fire();
  647. p58.eDestroyed:Destroy();
  648. p58.eMessagePosted:Destroy();
  649. p58.eSpeakerJoined:Destroy();
  650. p58.eSpeakerLeft:Destroy();
  651. p58.eSpeakerMuted:Destroy();
  652. p58.eSpeakerUnmuted:Destroy();
  653. end;
  654. function v10.InternalDoMessageFilter(p59, p60, p61, p62)
  655. for v56, v57, v58 in p59.FilterMessageFunctions:GetIterator(), nil do
  656. local v59, v60 = pcall(function()
  657. v57(p60, p61, p62);
  658. end);
  659. if not v59 then
  660. warn(string.format("DoMessageFilter Function '%s' failed for reason: %s", v56, v60));
  661. end;
  662. end;
  663. end;
  664. function v10.InternalDoProcessCommands(p63, p64, p65, p66)
  665. local v61 = p63.ProcessCommandsFunctions:GetIterator();
  666. local v62 = nil;
  667. local v63 = nil;
  668. while true do
  669. local v64 = nil;
  670. local v65, v66, v67 = v61(v62, v63);
  671. if not v65 then
  672. break;
  673. end;
  674. v63 = v65;
  675. local v68 = nil;
  676. v68, v64 = pcall(function()
  677. local v69 = v66(p64, p65, p66);
  678. if type(v69) ~= "boolean" then
  679. error("Process command functions must return a bool");
  680. end;
  681. return v69;
  682. end);
  683. if not v68 then
  684. warn(string.format("DoProcessCommands Function '%s' failed for reason: %s", v65, v64));
  685. elseif v64 then
  686. return true;
  687. end;
  688. end;
  689. return false;
  690. end;
  691. local u4 = v1 or v2;
  692. function v10.InternalPostMessage(p67, p68, p69, p70)
  693. if p67:InternalDoProcessCommands(p68.Name, p69, p67.Name) then
  694. return false;
  695. end;
  696. if p67.Mutes[p68.Name:lower()] ~= nil then
  697. local v70 = p67.Mutes[p68.Name:lower()];
  698. if not (v70 > 0) or not (v70 < os.time()) then
  699. p67:SendSystemMessageToSpeaker(u1:FormatMessageToSend("GameChat_ChatChannel_MutedInChannel", "You are muted and cannot talk in this channel"), p68.Name);
  700. return false;
  701. end;
  702. p67:UnmuteSpeaker(p68.Name);
  703. end;
  704. local v71 = p67:InternalCreateMessageObject(p69, p68.Name, false, p70);
  705. v71.Message = p69;
  706. local u5 = nil;
  707. local u6 = v71;
  708. pcall(function()
  709. u5 = l__Chat__4:InvokeChatCallback(Enum.ChatCallbackType.OnServerReceivingMessage, u6);
  710. end);
  711. u6.Message = nil;
  712. if u5 then
  713. if u5.ShouldDeliver == false then
  714. return false;
  715. end;
  716. u6 = u5;
  717. end;
  718. p69 = p67:SendMessageObjToFilters(p69, u6, p68);
  719. local v72 = {};
  720. for v73, v74 in pairs(p67.Speakers) do
  721. if not v74:IsSpeakerMuted(p68.Name) and p67:CanCommunicate(p68, v74) then
  722. table.insert(v72, v74.Name);
  723. if v74.Name == p68.Name then
  724. local v75 = u3(u6);
  725. if u4 then
  726. v75.Message = string.rep("_", u6.MessageLength);
  727. else
  728. v75.Message = p69;
  729. end;
  730. v75.IsFiltered = true;
  731. v74:InternalSendMessage(v75, p67.Name);
  732. else
  733. v74:InternalSendMessage(u6, p67.Name);
  734. end;
  735. end;
  736. end;
  737. local v76, v77 = pcall(function()
  738. p67.eMessagePosted:Fire(u6);
  739. end);
  740. if not v76 and v77 then
  741. print("Error posting message: " .. v77);
  742. end;
  743. local v78, v79, v80 = p67.ChatService:InternalApplyRobloxFilterNewAPI(u6.FromSpeaker, p69, p67.Private and Enum.TextFilterContext.PrivateChat or Enum.TextFilterContext.PublicChat);
  744. if not v78 then
  745. return false;
  746. end;
  747. u6.FilterResult = v80;
  748. u6.IsFilterResult = v79;
  749. u6.IsFiltered = true;
  750. p67:InternalAddMessageToHistoryLog(u6);
  751. for v81, v82 in pairs(v72) do
  752. local v83 = p67.Speakers[v82];
  753. if v83 then
  754. v83:InternalSendFilteredMessageWithFilterResult(u6, p67.Name);
  755. end;
  756. end;
  757. local v84 = {};
  758. for v85, v86 in pairs(p67.Speakers) do
  759. if not v86:IsSpeakerMuted(p68.Name) and p67:CanCommunicate(p68, v86) then
  760. local v87 = false;
  761. for v88, v89 in pairs(v72) do
  762. if v86.Name == v89 then
  763. v87 = true;
  764. break;
  765. end;
  766. end;
  767. if not v87 then
  768. table.insert(v84, v86.Name);
  769. end;
  770. end;
  771. end;
  772. for v90, v91 in pairs(v84) do
  773. local v92 = p67.Speakers[v91];
  774. if v92 then
  775. v92:InternalSendFilteredMessageWithFilterResult(u6, p67.Name);
  776. end;
  777. end;
  778. return v71;
  779. end;
  780. function v10.InternalAddSpeaker(p71, p72)
  781. if p71.Speakers[p72.Name] then
  782. warn("Speaker \"" .. p72.name .. "\" is already in the channel!");
  783. return;
  784. end;
  785. p71.Speakers[p72.Name] = p72;
  786. local v93, v94 = pcall(function()
  787. p71.eSpeakerJoined:Fire(p72.Name);
  788. end);
  789. if not v93 and v94 then
  790. print("Error removing channel: " .. v94);
  791. end;
  792. end;
  793. function v10.InternalRemoveSpeaker(p73, p74)
  794. if not p73.Speakers[p74.Name] then
  795. warn("Speaker \"" .. p74.name .. "\" is not in the channel!");
  796. return;
  797. end;
  798. p73.Speakers[p74.Name] = nil;
  799. local v95, v96 = pcall(function()
  800. p73.eSpeakerLeft:Fire(p74.Name);
  801. end);
  802. if not v95 and v96 then
  803. print("Error removing speaker: " .. v96);
  804. end;
  805. end;
  806. function v10.InternalRemoveExcessMessagesFromLog(p75)
  807. local l__table_remove__97 = table.remove;
  808. while p75.MaxHistory < #p75.ChatHistory do
  809. l__table_remove__97(p75.ChatHistory, 1);
  810. end;
  811. end;
  812. function v10.InternalAddMessageToHistoryLog(p76, p77)
  813. table.insert(p76.ChatHistory, p77);
  814. p76:InternalRemoveExcessMessagesFromLog();
  815. end;
  816. function v10.GetMessageType(p78, p79, p80)
  817. if p80 == nil then
  818. return v8.MessageTypeSystem;
  819. end;
  820. return v8.MessageTypeDefault;
  821. end;
  822. function v10.InternalCreateMessageObject(p81, p82, p83, p84, p85)
  823. local v98 = -1;
  824. local v99 = nil;
  825. local v100 = nil;
  826. if p83 then
  827. v100 = p81.ChatService:GetSpeaker(p83);
  828. if v100 then
  829. local v101 = v100:GetPlayer();
  830. if v101 then
  831. v98 = v101.UserId;
  832. if v7.PlayerDisplayNamesEnabled then
  833. v99 = v100:GetNameForDisplay();
  834. end;
  835. else
  836. v98 = 0;
  837. end;
  838. end;
  839. end;
  840. local v102 = {
  841. ID = p81.ChatService:InternalGetUniqueMessageId(),
  842. FromSpeaker = p83,
  843. SpeakerDisplayName = v99,
  844. SpeakerUserId = v98,
  845. OriginalChannel = p81.Name,
  846. MessageLength = string.len(p82),
  847. MessageType = p81:GetMessageType(p82, p83),
  848. IsFiltered = p84,
  849. Message = p84 and p82 or nil,
  850. Time = os.time(),
  851. ExtraData = {}
  852. };
  853. if v100 then
  854. for v103, v104 in pairs(v100.ExtraData) do
  855. v102.ExtraData[v103] = v104;
  856. end;
  857. end;
  858. if p85 then
  859. for v105, v106 in pairs(p85) do
  860. v102.ExtraData[v105] = v106;
  861. end;
  862. end;
  863. return v102;
  864. end;
  865. function v10.SetChannelNameColor(p86, p87)
  866. p86.ChannelNameColor = p87;
  867. for v107, v108 in pairs(p86.Speakers) do
  868. v108:UpdateChannelNameColor(p86.Name, p87);
  869. end;
  870. end;
  871. function v10.GetWelcomeMessageForSpeaker(p88, p89)
  872. if p88.GetWelcomeMessageFunction then
  873. local v109 = p88.GetWelcomeMessageFunction(p89);
  874. if v109 then
  875. return v109;
  876. end;
  877. end;
  878. return p88.WelcomeMessage;
  879. end;
  880. function v10.RegisterGetWelcomeMessageFunction(p90, p91)
  881. if type(p91) ~= "function" then
  882. error("RegisterGetWelcomeMessageFunction must be called with a function.");
  883. end;
  884. p90.GetWelcomeMessageFunction = p91;
  885. end;
  886. function v10.UnRegisterGetWelcomeMessageFunction(p92)
  887. p92.GetWelcomeMessageFunction = nil;
  888. end;
  889. function v3.new(p93, p94, p95, p96)
  890. local v110 = setmetatable({}, v10);
  891. v110.ChatService = p93;
  892. v110.Name = p94;
  893. v110.WelcomeMessage = p95 and "";
  894. v110.GetWelcomeMessageFunction = nil;
  895. v110.ChannelNameColor = p96;
  896. v110.Joinable = true;
  897. v110.Leavable = true;
  898. v110.AutoJoin = false;
  899. v110.Private = false;
  900. v110.Speakers = {};
  901. v110.Mutes = {};
  902. v110.MaxHistory = 200;
  903. v110.HistoryIndex = 0;
  904. v110.ChatHistory = {};
  905. v110.FilterMessageFunctions = v9:NewSortedFunctionContainer();
  906. v110.ProcessCommandsFunctions = v9:NewSortedFunctionContainer();
  907. v110.eDestroyed = Instance.new("BindableEvent");
  908. v110.eMessagePosted = Instance.new("BindableEvent");
  909. v110.eSpeakerJoined = Instance.new("BindableEvent");
  910. v110.eSpeakerLeft = Instance.new("BindableEvent");
  911. v110.eSpeakerMuted = Instance.new("BindableEvent");
  912. v110.eSpeakerUnmuted = Instance.new("BindableEvent");
  913. v110.MessagePosted = v110.eMessagePosted.Event;
  914. v110.SpeakerJoined = v110.eSpeakerJoined.Event;
  915. v110.SpeakerLeft = v110.eSpeakerLeft.Event;
  916. v110.SpeakerMuted = v110.eSpeakerMuted.Event;
  917. v110.SpeakerUnmuted = v110.eSpeakerUnmuted.Event;
  918. v110.Destroyed = v110.eDestroyed.Event;
  919. return v110;
  920. end;
  921. return v3;
  922. Speaker:
  923. -- Script GUID: {3e1ba9f7-b5a9-446a-92c6-560d73b615b1}
  924. -- Decompiled with the Synapse X Luau decompiler.
  925.  
  926. local v1 = {};
  927. local l__Parent__2 = script.Parent;
  928. local u1 = {};
  929. local u2 = {
  930. eDestroyed = true,
  931. eSaidMessage = true,
  932. eReceivedMessage = true,
  933. eReceivedUnfilteredMessage = true,
  934. eMessageDoneFiltering = true,
  935. eReceivedSystemMessage = true,
  936. eChannelJoined = true,
  937. eChannelLeft = true,
  938. eMuted = true,
  939. eUnmuted = true,
  940. eExtraDataUpdated = true,
  941. eMainChannelSet = true,
  942. eChannelNameColorUpdated = true
  943. };
  944. local u3 = {
  945. Destroyed = "eDestroyed",
  946. SaidMessage = "eSaidMessage",
  947. ReceivedMessage = "eReceivedMessage",
  948. ReceivedUnfilteredMessage = "eReceivedUnfilteredMessage",
  949. RecievedUnfilteredMessage = "eReceivedUnfilteredMessage",
  950. MessageDoneFiltering = "eMessageDoneFiltering",
  951. ReceivedSystemMessage = "eReceivedSystemMessage",
  952. ChannelJoined = "eChannelJoined",
  953. ChannelLeft = "eChannelLeft",
  954. Muted = "eMuted",
  955. Unmuted = "eUnmuted",
  956. ExtraDataUpdated = "eExtraDataUpdated",
  957. MainChannelSet = "eMainChannelSet",
  958. ChannelNameColorUpdated = "eChannelNameColorUpdated"
  959. };
  960. function u1.__index(p1, p2)
  961. local v3 = rawget(u1, p2);
  962. if v3 then
  963. return v3;
  964. end;
  965. if u2[p2] and not rawget(p1, p2) then
  966. rawset(p1, p2, Instance.new("BindableEvent"));
  967. end;
  968. local v4 = u3[p2];
  969. if v4 and not rawget(p1, p2) then
  970. if not rawget(p1, v4) then
  971. rawset(p1, v4, Instance.new("BindableEvent"));
  972. end;
  973. rawset(p1, p2, rawget(p1, v4).Event);
  974. end;
  975. return rawget(p1, p2);
  976. end;
  977. function u1.LazyFire(p3, p4, ...)
  978. local v5 = rawget(p3, p4);
  979. if v5 then
  980. v5:Fire(...);
  981. end;
  982. end;
  983. function u1.SayMessage(p5, p6, p7, p8)
  984. if p5.ChatService:InternalDoProcessCommands(p5.Name, p6, p7) then
  985. return;
  986. end;
  987. if not p7 then
  988. return;
  989. end;
  990. local v6 = p5.Channels[p7:lower()];
  991. if not v6 then
  992. return;
  993. end;
  994. local v7 = v6:InternalPostMessage(p5, p6, p8);
  995. if v7 then
  996. pcall(function()
  997. p5:LazyFire("eSaidMessage", v7, p7);
  998. end);
  999. end;
  1000. return v7;
  1001. end;
  1002. function u1.JoinChannel(p9, p10)
  1003. if p9.Channels[p10:lower()] then
  1004. warn("Speaker is already in channel \"" .. p10 .. "\"");
  1005. return;
  1006. end;
  1007. local v8 = p9.ChatService:GetChannel(p10);
  1008. if not v8 then
  1009. error("Channel \"" .. p10 .. "\" does not exist!");
  1010. end;
  1011. p9.Channels[p10:lower()] = v8;
  1012. v8:InternalAddSpeaker(p9);
  1013. local v9, v10 = pcall(function()
  1014. p9.eChannelJoined:Fire(v8.Name, v8:GetWelcomeMessageForSpeaker(p9));
  1015. end);
  1016. if not v9 and v10 then
  1017. print("Error joining channel: " .. v10);
  1018. end;
  1019. end;
  1020. function u1.LeaveChannel(p11, p12)
  1021. if not p11.Channels[p12:lower()] then
  1022. warn("Speaker is not in channel \"" .. p12 .. "\"");
  1023. return;
  1024. end;
  1025. local v11 = p11.Channels[p12:lower()];
  1026. p11.Channels[p12:lower()] = nil;
  1027. v11:InternalRemoveSpeaker(p11);
  1028. local v12, v13 = pcall(function()
  1029. p11:LazyFire("eChannelLeft", v11.Name);
  1030. if p11.PlayerObj then
  1031. p11.EventFolder.OnChannelLeft:FireClient(p11.PlayerObj, v11.Name);
  1032. end;
  1033. end);
  1034. if not v12 and v13 then
  1035. print("Error leaving channel: " .. v13);
  1036. end;
  1037. end;
  1038. function u1.IsInChannel(p13, p14)
  1039. return p13.Channels[p14:lower()] ~= nil;
  1040. end;
  1041. function u1.GetChannelList(p15)
  1042. local v14 = {};
  1043. for v15, v16 in pairs(p15.Channels) do
  1044. table.insert(v14, v16.Name);
  1045. end;
  1046. return v14;
  1047. end;
  1048. function u1.SendMessage(p16, p17, p18, p19, p20)
  1049. local v17 = p16.Channels[p18:lower()];
  1050. if not v17 then
  1051. warn(string.format("Speaker '%s' is not in channel '%s' and cannot receive a message in it.", p16.Name, p18));
  1052. return;
  1053. end;
  1054. v17:SendMessageToSpeaker(p17, p16.Name, p19, p20);
  1055. end;
  1056. function u1.SendSystemMessage(p21, p22, p23, p24)
  1057. local v18 = p21.Channels[p23:lower()];
  1058. if not v18 then
  1059. warn(string.format("Speaker '%s' is not in channel '%s' and cannot receive a system message in it.", p21.Name, p23));
  1060. return;
  1061. end;
  1062. v18:SendSystemMessageToSpeaker(p22, p21.Name, p24);
  1063. end;
  1064. function u1.GetPlayer(p25)
  1065. return p25.PlayerObj;
  1066. end;
  1067. local u4 = require(game:GetService("Chat"):WaitForChild("ClientChatModules"):WaitForChild("ChatSettings"));
  1068. function u1.GetNameForDisplay(p26)
  1069. if not u4.PlayerDisplayNamesEnabled then
  1070. return p26.Name;
  1071. end;
  1072. local v19 = p26:GetPlayer();
  1073. if v19 then
  1074. return v19.DisplayName;
  1075. end;
  1076. return p26.Name;
  1077. end;
  1078. function u1.SetExtraData(p27, p28, p29)
  1079. p27.ExtraData[p28] = p29;
  1080. p27:LazyFire("eExtraDataUpdated", p28, p29);
  1081. end;
  1082. function u1.GetExtraData(p30, p31)
  1083. return p30.ExtraData[p31];
  1084. end;
  1085. function u1.SetMainChannel(p32, p33)
  1086. local v20, v21 = pcall(function()
  1087. p32:LazyFire("eMainChannelSet", p33);
  1088. if p32.PlayerObj then
  1089. p32.EventFolder.OnMainChannelSet:FireClient(p32.PlayerObj, p33);
  1090. end;
  1091. end);
  1092. if not v20 and v21 then
  1093. print("Error setting main channel: " .. v21);
  1094. end;
  1095. end;
  1096. function u1.AddMutedSpeaker(p34, p35)
  1097. p34.MutedSpeakers[p35:lower()] = true;
  1098. end;
  1099. function u1.RemoveMutedSpeaker(p36, p37)
  1100. p36.MutedSpeakers[p37:lower()] = false;
  1101. end;
  1102. function u1.IsSpeakerMuted(p38, p39)
  1103. return p38.MutedSpeakers[p39:lower()];
  1104. end;
  1105. function u1.InternalDestroy(p40)
  1106. for v22, v23 in pairs(p40.Channels) do
  1107. v23:InternalRemoveSpeaker(p40);
  1108. end;
  1109. p40.eDestroyed:Fire();
  1110. p40.EventFolder = nil;
  1111. p40.eDestroyed:Destroy();
  1112. p40.eSaidMessage:Destroy();
  1113. p40.eReceivedMessage:Destroy();
  1114. p40.eReceivedUnfilteredMessage:Destroy();
  1115. p40.eMessageDoneFiltering:Destroy();
  1116. p40.eReceivedSystemMessage:Destroy();
  1117. p40.eChannelJoined:Destroy();
  1118. p40.eChannelLeft:Destroy();
  1119. p40.eMuted:Destroy();
  1120. p40.eUnmuted:Destroy();
  1121. p40.eExtraDataUpdated:Destroy();
  1122. p40.eMainChannelSet:Destroy();
  1123. p40.eChannelNameColorUpdated:Destroy();
  1124. end;
  1125. function u1.InternalAssignPlayerObject(p41, p42)
  1126. p41.PlayerObj = p42;
  1127. end;
  1128. function u1.InternalAssignEventFolder(p43, p44)
  1129. p43.EventFolder = p44;
  1130. end;
  1131. function u1.InternalSendMessage(p45, p46, p47)
  1132. local v24, v25 = pcall(function()
  1133. p45:LazyFire("eReceivedUnfilteredMessage", p46, p47);
  1134. if p45.PlayerObj then
  1135. p45.EventFolder.OnNewMessage:FireClient(p45.PlayerObj, p46, p47);
  1136. end;
  1137. end);
  1138. if not v24 and v25 then
  1139. print("Error sending internal message: " .. v25);
  1140. end;
  1141. end;
  1142. function u1.InternalSendFilteredMessage(p48, p49, p50)
  1143. local v26, v27 = pcall(function()
  1144. p48:LazyFire("eReceivedMessage", p49, p50);
  1145. p48:LazyFire("eMessageDoneFiltering", p49, p50);
  1146. if p48.PlayerObj then
  1147. p48.EventFolder.OnMessageDoneFiltering:FireClient(p48.PlayerObj, p49, p50);
  1148. end;
  1149. end);
  1150. if not v26 and v27 then
  1151. print("Error sending internal filtered message: " .. v27);
  1152. end;
  1153. end;
  1154. local function u5(p51)
  1155. local v28 = {};
  1156. for v29, v30 in pairs(p51) do
  1157. v28[v29] = v30;
  1158. end;
  1159. return v28;
  1160. end;
  1161. function u1.InternalSendFilteredMessageWithFilterResult(p52, p53, p54)
  1162. local v31 = u5(p53);
  1163. local u6 = p52:GetPlayer();
  1164. local u7 = "";
  1165. local l__FilterResult__8 = v31.FilterResult;
  1166. pcall(function()
  1167. if not v31.IsFilterResult then
  1168. u7 = l__FilterResult__8;
  1169. return;
  1170. end;
  1171. if not u6 then
  1172. u7 = l__FilterResult__8:GetNonChatStringForBroadcastAsync();
  1173. return;
  1174. end;
  1175. u7 = l__FilterResult__8:GetChatForUserAsync(u6.UserId);
  1176. end);
  1177. if #u7 > 0 then
  1178. v31.Message = u7;
  1179. v31.FilterResult = nil;
  1180. p52:InternalSendFilteredMessage(v31, p54);
  1181. end;
  1182. end;
  1183. function u1.InternalSendSystemMessage(p55, p56, p57)
  1184. local v32, v33 = pcall(function()
  1185. p55:LazyFire("eReceivedSystemMessage", p56, p57);
  1186. if p55.PlayerObj then
  1187. p55.EventFolder.OnNewSystemMessage:FireClient(p55.PlayerObj, p56, p57);
  1188. end;
  1189. end);
  1190. if not v32 and v33 then
  1191. print("Error sending internal system message: " .. v33);
  1192. end;
  1193. end;
  1194. function u1.UpdateChannelNameColor(p58, p59, p60)
  1195. p58:LazyFire("eChannelNameColorUpdated", p59, p60);
  1196. if p58.PlayerObj then
  1197. p58.EventFolder.ChannelNameColorUpdated:FireClient(p58.PlayerObj, p59, p60);
  1198. end;
  1199. end;
  1200. function v1.new(p61, p62)
  1201. local v34 = setmetatable({}, u1);
  1202. v34.ChatService = p61;
  1203. v34.PlayerObj = nil;
  1204. v34.Name = p62;
  1205. v34.ExtraData = {};
  1206. v34.Channels = {};
  1207. v34.MutedSpeakers = {};
  1208. v34.EventFolder = nil;
  1209. return v34;
  1210. end;
  1211. return v1;
  1212. Util:
  1213. -- Script GUID: {9ff55bc2-4bc2-4be9-8513-cf743e7bb0af}
  1214. -- Decompiled with the Synapse X Luau decompiler.
  1215.  
  1216. local v1 = require(game:GetService("Chat"):WaitForChild("ClientChatModules"):WaitForChild("ChatConstants")).StandardPriority;
  1217. if v1 == nil then
  1218. v1 = 10;
  1219. end;
  1220. local v2 = {};
  1221. v2.__index = v2;
  1222. local v3 = {};
  1223. local v4 = {};
  1224. v4.__index = v4;
  1225. function v4.RebuildProcessCommandsPriorities(p1)
  1226. p1.RegisteredPriorites = {};
  1227. local v5, v6, v7 = pairs(p1.FunctionMap);
  1228. while true do
  1229. local v8, v9 = v5(v6, v7);
  1230. if not v8 then
  1231. break;
  1232. end;
  1233. local v10 = true;
  1234. local v11, v12, v13 = pairs(v9);
  1235. local v14, v15 = v11(v12, v13);
  1236. if v14 then
  1237. v10 = false;
  1238. end;
  1239. if not v10 then
  1240. table.insert(p1.RegisteredPriorites, v8);
  1241. end;
  1242. end;
  1243. table.sort(p1.RegisteredPriorites, function(p2, p3)
  1244. return p3 < p2;
  1245. end);
  1246. end;
  1247. function v4.HasFunction(p4, p5)
  1248. if p4.RegisteredFunctions[p5] == nil then
  1249. return false;
  1250. end;
  1251. return true;
  1252. end;
  1253. function v4.RemoveFunction(p6, p7)
  1254. p6.RegisteredFunctions[p7] = nil;
  1255. p6.FunctionMap[p6.RegisteredFunctions[p7]][p7] = nil;
  1256. p6:RebuildProcessCommandsPriorities();
  1257. end;
  1258. function v4.AddFunction(p8, p9, p10, p11)
  1259. if p11 == nil then
  1260. p11 = v1;
  1261. end;
  1262. if p8.RegisteredFunctions[p9] then
  1263. error(p9 .. " is already in use!");
  1264. end;
  1265. p8.RegisteredFunctions[p9] = p11;
  1266. if p8.FunctionMap[p11] == nil then
  1267. p8.FunctionMap[p11] = {};
  1268. end;
  1269. p8.FunctionMap[p11][p9] = p10;
  1270. p8:RebuildProcessCommandsPriorities();
  1271. end;
  1272. function v4.GetIterator(p12)
  1273. local u1 = 1;
  1274. local u2 = nil;
  1275. local u3 = nil;
  1276. return function()
  1277. local v16 = nil;
  1278. while true do
  1279. if #p12.RegisteredPriorites < u1 then
  1280. return;
  1281. end;
  1282. v16 = p12.RegisteredPriorites[u1];
  1283. local v17, v18 = next(p12.FunctionMap[v16], u2);
  1284. u2 = v17;
  1285. u3 = v18;
  1286. if u2 ~= nil then
  1287. break;
  1288. end;
  1289. u1 = u1 + 1;
  1290. end;
  1291. return u2, u3, v16;
  1292. end;
  1293. end;
  1294. local u4 = v4;
  1295. function v3.new()
  1296. local v19 = setmetatable({}, u4);
  1297. v19.RegisteredFunctions = {};
  1298. v19.RegisteredPriorites = {};
  1299. v19.FunctionMap = {};
  1300. return v19;
  1301. end;
  1302. u4 = function(p13)
  1303. return v3.new();
  1304. end;
  1305. v2.NewSortedFunctionContainer = u4;
  1306. return v2;
  1307. Bubble Chat:
  1308. -- Script GUID: {14113adf-d54c-423f-8636-d12299bc895d}
  1309. -- Decompiled with the Synapse X Luau decompiler.
  1310.  
  1311. local l__Players__1 = game:GetService("Players");
  1312. local l__ReplicatedStorage__2 = game:GetService("ReplicatedStorage");
  1313. local l__Chat__3 = game:GetService("Chat");
  1314. local l__TextService__4 = game:GetService("TextService");
  1315. local v5 = l__Players__1.LocalPlayer;
  1316. while v5 == nil do
  1317. l__Players__1.ChildAdded:wait();
  1318. v5 = l__Players__1.LocalPlayer;
  1319. end;
  1320. local l__PlayerGui__6 = v5:WaitForChild("PlayerGui");
  1321. local v7, v8 = pcall(function()
  1322. return UserSettings():IsUserFeatureEnabled("UserShouldLocalizeGameChatBubble");
  1323. end);
  1324. local v9, v10 = pcall(function()
  1325. return UserSettings():IsUserFeatureEnabled("UserChatNewMessageLengthCheck2");
  1326. end);
  1327. local v11 = v9 or v10;
  1328. local function v12(p1)
  1329. return utf8.len(utf8.nfcnormalize(p1));
  1330. end;
  1331. if v11 then
  1332. local v13 = 128 - v12("...") - 1;
  1333. else
  1334. v13 = 128 - string.len("...") - 1;
  1335. end;
  1336. local v14 = Instance.new("ScreenGui");
  1337. v14.Name = "BubbleChat";
  1338. v14.ResetOnSpawn = false;
  1339. v14.Parent = l__PlayerGui__6;
  1340. local function u1()
  1341. local v15 = {
  1342. data = {}
  1343. };
  1344. local v16 = Instance.new("BindableEvent");
  1345. v15.Emptied = v16.Event;
  1346. function v15.Size(p2)
  1347. return #v15.data;
  1348. end;
  1349. function v15.Empty(p3)
  1350. return v15:Size() <= 0;
  1351. end;
  1352. function v15.PopFront(p4)
  1353. table.remove(v15.data, 1);
  1354. if v15:Empty() then
  1355. v16:Fire();
  1356. end;
  1357. end;
  1358. function v15.Front(p5)
  1359. return v15.data[1];
  1360. end;
  1361. function v15.Get(p6, p7)
  1362. return v15.data[p7];
  1363. end;
  1364. function v15.PushBack(p8, p9)
  1365. table.insert(v15.data, p9);
  1366. end;
  1367. function v15.GetData(p10)
  1368. return v15.data;
  1369. end;
  1370. return v15;
  1371. end;
  1372. local function u2()
  1373. return {
  1374. Fifo = u1(),
  1375. BillboardGui = nil
  1376. };
  1377. end;
  1378. local function u3(p11, p12, p13)
  1379. if v11 then
  1380. return p12 + (p13 - p12) * math.min(v12(p11) / 75, 1);
  1381. end;
  1382. return p12 + (p13 - p12) * math.min(string.len(p11) / 75, 1);
  1383. end;
  1384. local function u4(p14, p15, p16)
  1385. local v17 = {
  1386. ComputeBubbleLifetime = function(p17, p18, p19)
  1387. if p19 then
  1388. return u3(p18, 8, 15);
  1389. end;
  1390. return u3(p18, 12, 20);
  1391. end,
  1392. Origin = nil,
  1393. RenderBubble = nil,
  1394. Message = p14
  1395. };
  1396. v17.BubbleDieDelay = v17:ComputeBubbleLifetime(p14, p16);
  1397. v17.BubbleColor = p15;
  1398. v17.IsLocalPlayer = p16;
  1399. return v17;
  1400. end;
  1401. local u5 = {
  1402. WHITE = "dub",
  1403. BLUE = "blu",
  1404. GREEN = "gre",
  1405. RED = "red"
  1406. };
  1407. function createChatBubbleMain(p20, p21)
  1408. local v18 = Instance.new("ImageLabel");
  1409. v18.Name = "ChatBubble";
  1410. v18.ScaleType = Enum.ScaleType.Slice;
  1411. v18.SliceCenter = p21;
  1412. v18.Image = "rbxasset://textures/" .. tostring(p20) .. ".png";
  1413. v18.BackgroundTransparency = 1;
  1414. v18.BorderSizePixel = 0;
  1415. v18.Size = UDim2.new(1, 0, 1, 0);
  1416. v18.Position = UDim2.new(0, 0, 0, 0);
  1417. return v18;
  1418. end;
  1419. function createChatBubbleTail(p22, p23)
  1420. local v19 = Instance.new("ImageLabel");
  1421. v19.Name = "ChatBubbleTail";
  1422. v19.Image = "rbxasset://textures/ui/dialog_tail.png";
  1423. v19.BackgroundTransparency = 1;
  1424. v19.BorderSizePixel = 0;
  1425. v19.Position = p22;
  1426. v19.Size = p23;
  1427. return v19;
  1428. end;
  1429. function createChatBubbleWithTail(p24, p25, p26, p27)
  1430. local v20 = createChatBubbleMain(p24, p27);
  1431. createChatBubbleTail(p25, p26).Parent = v20;
  1432. return v20;
  1433. end;
  1434. function createScaledChatBubbleWithTail(p28, p29, p30, p31)
  1435. local v21 = createChatBubbleMain(p28, p31);
  1436. local v22 = Instance.new("Frame");
  1437. v22.Name = "ChatBubbleTailFrame";
  1438. v22.BackgroundTransparency = 1;
  1439. v22.SizeConstraint = Enum.SizeConstraint.RelativeXX;
  1440. v22.Position = UDim2.new(0.5, 0, 1, 0);
  1441. v22.Size = UDim2.new(p29, 0, p29, 0);
  1442. v22.Parent = v21;
  1443. createChatBubbleTail(p30, UDim2.new(1, 0, 0.5, 0)).Parent = v22;
  1444. return v21;
  1445. end;
  1446. function createChatImposter(p32, p33, p34)
  1447. local v23 = Instance.new("ImageLabel");
  1448. v23.Name = "DialogPlaceholder";
  1449. v23.Image = "rbxasset://textures/" .. tostring(p32) .. ".png";
  1450. v23.BackgroundTransparency = 1;
  1451. v23.BorderSizePixel = 0;
  1452. v23.Position = UDim2.new(0, 0, -1.25, 0);
  1453. v23.Size = UDim2.new(1, 0, 1, 0);
  1454. local v24 = Instance.new("ImageLabel");
  1455. v24.Name = "DotDotDot";
  1456. v24.Image = "rbxasset://textures/" .. tostring(p33) .. ".png";
  1457. v24.BackgroundTransparency = 1;
  1458. v24.BorderSizePixel = 0;
  1459. v24.Position = UDim2.new(0.001, 0, p34, 0);
  1460. v24.Size = UDim2.new(1, 0, 0.7, 0);
  1461. v24.Parent = v23;
  1462. return v23;
  1463. end;
  1464. local u6 = {
  1465. ChatBubble = {},
  1466. ChatBubbleWithTail = {},
  1467. ScalingChatBubbleWithTail = {},
  1468. CharacterSortedMsg = (function()
  1469. local v25 = {
  1470. data = {}
  1471. };
  1472. local u7 = 0;
  1473. function v25.Size(p35)
  1474. return u7;
  1475. end;
  1476. function v25.Erase(p36, p37)
  1477. if v25.data[p37] then
  1478. u7 = u7 - 1;
  1479. end;
  1480. v25.data[p37] = nil;
  1481. end;
  1482. function v25.Set(p38, p39, p40)
  1483. v25.data[p39] = p40;
  1484. if p40 then
  1485. u7 = u7 + 1;
  1486. end;
  1487. end;
  1488. function v25.Get(p41, p42)
  1489. if not p42 then
  1490. return;
  1491. end;
  1492. if not v25.data[p42] then
  1493. v25.data[p42] = u2();
  1494. local u8 = nil;
  1495. u8 = v25.data[p42].Fifo.Emptied:connect(function()
  1496. u8:disconnect();
  1497. v25:Erase(p42);
  1498. end);
  1499. end;
  1500. return v25.data[p42];
  1501. end;
  1502. function v25.GetData(p43)
  1503. return v25.data;
  1504. end;
  1505. return v25;
  1506. end)()
  1507. };
  1508. local function v26(p44, p45, p46, p47, p48)
  1509. u6.ChatBubble[p44] = createChatBubbleMain(p45, p48);
  1510. if p47 then
  1511. local v27 = -1;
  1512. else
  1513. v27 = 0;
  1514. end;
  1515. u6.ChatBubbleWithTail[p44] = createChatBubbleWithTail(p45, UDim2.new(0.5, -14, 1, v27), UDim2.new(0, 30, 0, 14), p48);
  1516. if p47 then
  1517. local v28 = -1;
  1518. else
  1519. v28 = 0;
  1520. end;
  1521. u6.ScalingChatBubbleWithTail[p44] = createScaledChatBubbleWithTail(p45, 0.5, UDim2.new(-0.5, 0, 0, v28), p48);
  1522. end;
  1523. v26(u5.WHITE, "ui/dialog_white", "ui/chatBubble_white_notify_bkg", false, Rect.new(5, 5, 15, 15));
  1524. v26(u5.BLUE, "ui/dialog_blue", "ui/chatBubble_blue_notify_bkg", true, Rect.new(7, 7, 33, 33));
  1525. v26(u5.RED, "ui/dialog_red", "ui/chatBubble_red_notify_bkg", true, Rect.new(7, 7, 33, 33));
  1526. v26(u5.GREEN, "ui/dialog_green", "ui/chatBubble_green_notify_bkg", true, Rect.new(7, 7, 33, 33));
  1527. function u6.SanitizeChatLine(p49, p50)
  1528. if not v11 then
  1529. if v13 < string.len(p50) then
  1530. return string.sub(p50, 1, v13 + string.len("..."));
  1531. else
  1532. return p50;
  1533. end;
  1534. end;
  1535. if not (v13 < v12(p50)) then
  1536. return p50;
  1537. end;
  1538. return string.sub(p50, 1, utf8.offset(p50, v13 + v12("...") + 1) - 1);
  1539. end;
  1540. local function u9(p51)
  1541. local v29 = Instance.new("BillboardGui");
  1542. v29.Adornee = p51;
  1543. v29.Size = UDim2.new(0, 400, 0, 250);
  1544. v29.StudsOffset = Vector3.new(0, 1.5, 2);
  1545. v29.Parent = v14;
  1546. local v30 = Instance.new("Frame");
  1547. v30.Name = "BillboardFrame";
  1548. v30.Size = UDim2.new(1, 0, 1, 0);
  1549. v30.Position = UDim2.new(0, 0, -0.5, 0);
  1550. v30.BackgroundTransparency = 1;
  1551. v30.Parent = v29;
  1552. local u10 = nil;
  1553. u10 = v30.ChildRemoved:connect(function()
  1554. if #v30:GetChildren() <= 1 then
  1555. u10:disconnect();
  1556. v29:Destroy();
  1557. end;
  1558. end);
  1559. u6:CreateSmallTalkBubble(u5.WHITE).Parent = v30;
  1560. return v29;
  1561. end;
  1562. function u6.CreateBillboardGuiHelper(p52, p53, p54)
  1563. if p53 and not u6.CharacterSortedMsg:Get(p53).BillboardGui then
  1564. if not p54 and p53:IsA("BasePart") then
  1565. u6.CharacterSortedMsg:Get(p53).BillboardGui = u9(p53);
  1566. return;
  1567. end;
  1568. if p53:IsA("Model") then
  1569. local l__Head__31 = p53:FindFirstChild("Head");
  1570. if l__Head__31 and l__Head__31:IsA("BasePart") then
  1571. u6.CharacterSortedMsg:Get(p53).BillboardGui = u9(l__Head__31);
  1572. end;
  1573. end;
  1574. end;
  1575. end;
  1576. local function u11(p55)
  1577. if not p55 or not l__Players__1.LocalPlayer.Character then
  1578. return;
  1579. end;
  1580. return p55:IsDescendantOf(l__Players__1.LocalPlayer.Character);
  1581. end;
  1582. function u6.SetBillboardLODNear(p56, p57)
  1583. local v32 = u11(p57.Adornee);
  1584. p57.Size = UDim2.new(0, 400, 0, 250);
  1585. if v32 then
  1586. local v33 = 1.5;
  1587. else
  1588. v33 = 2.5;
  1589. end;
  1590. if v32 then
  1591. local v34 = 2;
  1592. else
  1593. v34 = 0.1;
  1594. end;
  1595. p57.StudsOffset = Vector3.new(0, v33, v34);
  1596. p57.Enabled = true;
  1597. local v35 = p57.BillboardFrame:GetChildren();
  1598. for v36 = 1, #v35 do
  1599. v35[v36].Visible = true;
  1600. end;
  1601. p57.BillboardFrame.SmallTalkBubble.Visible = false;
  1602. end;
  1603. function u6.SetBillboardLODDistant(p58, p59)
  1604. p59.Size = UDim2.new(4, 0, 3, 0);
  1605. if u11(p59.Adornee) then
  1606. local v37 = 2;
  1607. else
  1608. v37 = 0.1;
  1609. end;
  1610. p59.StudsOffset = Vector3.new(0, 3, v37);
  1611. p59.Enabled = true;
  1612. local v38 = p59.BillboardFrame:GetChildren();
  1613. for v39 = 1, #v38 do
  1614. v38[v39].Visible = false;
  1615. end;
  1616. p59.BillboardFrame.SmallTalkBubble.Visible = true;
  1617. end;
  1618. function u6.SetBillboardLODVeryFar(p60, p61)
  1619. p61.Enabled = false;
  1620. end;
  1621. local function u12(p62)
  1622. if not p62 then
  1623. return 100000;
  1624. end;
  1625. return (p62.Position - game.Workspace.CurrentCamera.CoordinateFrame.p).magnitude;
  1626. end;
  1627. function u6.SetBillboardGuiLOD(p63, p64, p65)
  1628. if not p65 then
  1629. return;
  1630. end;
  1631. if p65:IsA("Model") then
  1632. local l__Head__40 = p65:FindFirstChild("Head");
  1633. if not l__Head__40 then
  1634. p65 = p65.PrimaryPart;
  1635. else
  1636. p65 = l__Head__40;
  1637. end;
  1638. end;
  1639. local v41 = u12(p65);
  1640. if v41 < 65 then
  1641. u6:SetBillboardLODNear(p64);
  1642. return;
  1643. end;
  1644. if v41 >= 65 and v41 < 100 then
  1645. u6:SetBillboardLODDistant(p64);
  1646. return;
  1647. end;
  1648. u6:SetBillboardLODVeryFar(p64);
  1649. end;
  1650. function u6.CameraCFrameChanged(p66)
  1651. for v42, v43 in pairs(u6.CharacterSortedMsg:GetData()) do
  1652. local l__BillboardGui__44 = v43.BillboardGui;
  1653. if l__BillboardGui__44 then
  1654. u6:SetBillboardGuiLOD(l__BillboardGui__44, v42);
  1655. end;
  1656. end;
  1657. end;
  1658. local l__Enum_Font_SourceSans__13 = Enum.Font.SourceSans;
  1659. local l__Enum_FontSize_Size24__14 = Enum.FontSize.Size24;
  1660. function u6.CreateBubbleText(p67, p68, p69)
  1661. local v45 = Instance.new("TextLabel");
  1662. v45.Name = "BubbleText";
  1663. v45.BackgroundTransparency = 1;
  1664. v45.Position = UDim2.new(0, 15, 0, 0);
  1665. v45.Size = UDim2.new(1, -30, 1, 0);
  1666. v45.Font = l__Enum_Font_SourceSans__13;
  1667. v45.ClipsDescendants = true;
  1668. v45.TextWrapped = true;
  1669. v45.FontSize = l__Enum_FontSize_Size24__14;
  1670. v45.Text = p68;
  1671. v45.Visible = false;
  1672. v45.AutoLocalize = p69;
  1673. return v45;
  1674. end;
  1675. function u6.CreateSmallTalkBubble(p70, p71)
  1676. local v46 = u6.ScalingChatBubbleWithTail[p71]:Clone();
  1677. v46.Name = "SmallTalkBubble";
  1678. v46.AnchorPoint = Vector2.new(0, 0.5);
  1679. v46.Position = UDim2.new(0, 0, 0.5, 0);
  1680. v46.Visible = false;
  1681. local v47 = u6:CreateBubbleText("...");
  1682. v47.TextScaled = true;
  1683. v47.TextWrapped = false;
  1684. v47.Visible = true;
  1685. v47.Parent = v46;
  1686. return v46;
  1687. end;
  1688. function u6.UpdateChatLinesForOrigin(p72, p73, p74)
  1689. local l__Fifo__48 = u6.CharacterSortedMsg:Get(p73).Fifo;
  1690. local v49 = l__Fifo__48:Size();
  1691. local v50 = l__Fifo__48:GetData();
  1692. if #v50 <= 1 then
  1693. return;
  1694. end;
  1695. for v51 = #v50 - 1, 1, -1 do
  1696. local l__RenderBubble__52 = v50[v51].RenderBubble;
  1697. if not l__RenderBubble__52 then
  1698. return;
  1699. end;
  1700. if v49 - v51 + 1 > 1 then
  1701. local l__ChatBubbleTail__53 = l__RenderBubble__52:FindFirstChild("ChatBubbleTail");
  1702. if l__ChatBubbleTail__53 then
  1703. l__ChatBubbleTail__53:Destroy();
  1704. end;
  1705. local l__BubbleText__54 = l__RenderBubble__52:FindFirstChild("BubbleText");
  1706. if l__BubbleText__54 then
  1707. l__BubbleText__54.TextTransparency = 0.5;
  1708. end;
  1709. end;
  1710. l__RenderBubble__52:TweenPosition(UDim2.new(l__RenderBubble__52.Position.X.Scale, l__RenderBubble__52.Position.X.Offset, 1, p74 - l__RenderBubble__52.Size.Y.Offset - 14), Enum.EasingDirection.Out, Enum.EasingStyle.Bounce, 0.1, true);
  1711. p74 = p74 - l__RenderBubble__52.Size.Y.Offset - 14;
  1712. end;
  1713. end;
  1714. function u6.DestroyBubble(p75, p76, p77)
  1715. if not p76 then
  1716. return;
  1717. end;
  1718. if p76:Empty() then
  1719. return;
  1720. end;
  1721. local l__RenderBubble__55 = p76:Front().RenderBubble;
  1722. if l__RenderBubble__55 then
  1723. local u15 = l__RenderBubble__55;
  1724. spawn(function()
  1725. while p76:Front().RenderBubble ~= p77 do
  1726. wait();
  1727. end;
  1728. u15 = p76:Front().RenderBubble;
  1729. local l__BubbleText__56 = u15:FindFirstChild("BubbleText");
  1730. local l__ChatBubbleTail__57 = u15:FindFirstChild("ChatBubbleTail");
  1731. while u15 and u15.ImageTransparency < 1 do
  1732. local v58 = wait();
  1733. if u15 then
  1734. local v59 = v58 * 1.5;
  1735. u15.ImageTransparency = u15.ImageTransparency + v59;
  1736. if l__BubbleText__56 then
  1737. l__BubbleText__56.TextTransparency = l__BubbleText__56.TextTransparency + v59;
  1738. end;
  1739. if l__ChatBubbleTail__57 then
  1740. l__ChatBubbleTail__57.ImageTransparency = l__ChatBubbleTail__57.ImageTransparency + v59;
  1741. end;
  1742. end;
  1743. end;
  1744. if u15 then
  1745. u15:Destroy();
  1746. p76:PopFront();
  1747. end;
  1748. end);
  1749. return;
  1750. end;
  1751. p76:PopFront();
  1752. end;
  1753. function u6.CreateChatLineRender(p78, p79, p80, p81, p82, p83)
  1754. if not p79 then
  1755. return;
  1756. end;
  1757. if not u6.CharacterSortedMsg:Get(p79).BillboardGui then
  1758. u6:CreateBillboardGuiHelper(p79, p81);
  1759. end;
  1760. local l__BillboardGui__60 = u6.CharacterSortedMsg:Get(p79).BillboardGui;
  1761. if l__BillboardGui__60 then
  1762. local v61 = u6.ChatBubbleWithTail[p80.BubbleColor]:Clone();
  1763. v61.Visible = false;
  1764. local v62 = u6:CreateBubbleText(p80.Message, p83);
  1765. v62.Parent = v61;
  1766. v61.Parent = l__BillboardGui__60.BillboardFrame;
  1767. p80.RenderBubble = v61;
  1768. local v63 = l__TextService__4:GetTextSize(v62.Text, 24, l__Enum_Font_SourceSans__13, Vector2.new(400, 250));
  1769. local v64 = math.max((v63.X + 30) / 400, 0.1);
  1770. v61.Size = UDim2.new(0, 0, 0, 0);
  1771. v61.Position = UDim2.new(0.5, 0, 1, 0);
  1772. local v65 = v63.Y / 24 * 34;
  1773. v61:TweenSizeAndPosition(UDim2.new(v64, 0, 0, v65), UDim2.new((1 - v64) / 2, 0, 1, -v65), Enum.EasingDirection.Out, Enum.EasingStyle.Elastic, 0.1, true, function()
  1774. v62.Visible = true;
  1775. end);
  1776. u6:SetBillboardGuiLOD(l__BillboardGui__60, p80.Origin);
  1777. u6:UpdateChatLinesForOrigin(p80.Origin, -v65);
  1778. delay(p80.BubbleDieDelay, function()
  1779. u6:DestroyBubble(p82, v61);
  1780. end);
  1781. end;
  1782. end;
  1783. local function u16(p84, p85, p86)
  1784. local v66 = u4(p85, u5.WHITE, p86);
  1785. if p84 then
  1786. v66.User = p84.Name;
  1787. v66.Origin = p84.Character;
  1788. end;
  1789. return v66;
  1790. end;
  1791. function u6.OnPlayerChatMessage(p87, p88, p89, p90)
  1792. if not u6:BubbleChatEnabled() then
  1793. return;
  1794. end;
  1795. local l__LocalPlayer__67 = l__Players__1.LocalPlayer;
  1796. local v68 = false;
  1797. if l__LocalPlayer__67 ~= nil then
  1798. v68 = p88 ~= l__LocalPlayer__67;
  1799. end;
  1800. local v69 = u16(p88, u6:SanitizeChatLine(p89), not v68);
  1801. if p88 and v69.Origin then
  1802. local l__Fifo__70 = u6.CharacterSortedMsg:Get(v69.Origin).Fifo;
  1803. l__Fifo__70:PushBack(v69);
  1804. u6:CreateChatLineRender(p88.Character, v69, true, l__Fifo__70, false);
  1805. end;
  1806. end;
  1807. local function u17(p91, p92, p93, p94)
  1808. local v71 = u4(p92, p94, p93);
  1809. v71.Origin = p91;
  1810. return v71;
  1811. end;
  1812. local u18 = v7 or v8;
  1813. function u6.OnGameChatMessage(p95, p96, p97, p98)
  1814. local l__LocalPlayer__72 = l__Players__1.LocalPlayer;
  1815. local v73 = false;
  1816. if l__LocalPlayer__72 ~= nil then
  1817. v73 = l__LocalPlayer__72.Character ~= p96;
  1818. end;
  1819. local v74 = u5.WHITE;
  1820. if p98 == Enum.ChatColor.Blue then
  1821. v74 = u5.BLUE;
  1822. elseif p98 == Enum.ChatColor.Green then
  1823. v74 = u5.GREEN;
  1824. elseif p98 == Enum.ChatColor.Red then
  1825. v74 = u5.RED;
  1826. end;
  1827. local v75 = u17(p96, u6:SanitizeChatLine(p97), not v73, v74);
  1828. u6.CharacterSortedMsg:Get(v75.Origin).Fifo:PushBack(v75);
  1829. if u18 then
  1830. u6:CreateChatLineRender(p96, v75, false, u6.CharacterSortedMsg:Get(v75.Origin).Fifo, true);
  1831. return;
  1832. end;
  1833. u6:CreateChatLineRender(p96, v75, false, u6.CharacterSortedMsg:Get(v75.Origin).Fifo, false);
  1834. end;
  1835. function u6.BubbleChatEnabled(p99)
  1836. local l__ClientChatModules__76 = l__Chat__3:FindFirstChild("ClientChatModules");
  1837. if l__ClientChatModules__76 then
  1838. local l__ChatSettings__77 = l__ClientChatModules__76:FindFirstChild("ChatSettings");
  1839. if l__ChatSettings__77 then
  1840. local v78 = require(l__ChatSettings__77);
  1841. if v78.BubbleChatEnabled ~= nil then
  1842. return v78.BubbleChatEnabled;
  1843. end;
  1844. end;
  1845. end;
  1846. return l__Players__1.BubbleChat;
  1847. end;
  1848. function u6.ShowOwnFilteredMessage(p100)
  1849. local v79 = nil;
  1850. local l__ClientChatModules__80 = l__Chat__3:FindFirstChild("ClientChatModules");
  1851. if l__ClientChatModules__80 then
  1852. v79 = l__ClientChatModules__80:FindFirstChild("ChatSettings");
  1853. if not v79 then
  1854. return false;
  1855. end;
  1856. else
  1857. return false;
  1858. end;
  1859. return require(v79).ShowUserOwnFilteredMessage;
  1860. end;
  1861. function findPlayer(p101)
  1862. local v81, v82, v83 = pairs(l__Players__1:GetPlayers());
  1863. while true do
  1864. local v84, v85 = v81(v82, v83);
  1865. if v84 then
  1866.  
  1867. else
  1868. break;
  1869. end;
  1870. v83 = v84;
  1871. if v85.Name == p101 then
  1872. return v85;
  1873. end;
  1874. end;
  1875. end;
  1876. l__Chat__3.Chatted:connect(function(p102, p103, p104)
  1877. u6:OnGameChatMessage(p102, p103, p104);
  1878. end);
  1879. local v86 = nil;
  1880. if game.Workspace.CurrentCamera then
  1881. v86 = game.Workspace.CurrentCamera:GetPropertyChangedSignal("CFrame"):connect(function(p105)
  1882. u6:CameraCFrameChanged();
  1883. end);
  1884. end;
  1885. local u19 = v86;
  1886. game.Workspace.Changed:connect(function(p106)
  1887. if p106 == "CurrentCamera" then
  1888. if u19 then
  1889. u19:disconnect();
  1890. end;
  1891. if game.Workspace.CurrentCamera then
  1892. u19 = game.Workspace.CurrentCamera:GetPropertyChangedSignal("CFrame"):connect(function(p107)
  1893. u6:CameraCFrameChanged();
  1894. end);
  1895. end;
  1896. end;
  1897. end);
  1898. local u20 = nil;
  1899. function getAllowedMessageTypes()
  1900. if u20 then
  1901. return u20;
  1902. end;
  1903. local l__ClientChatModules__87 = l__Chat__3:FindFirstChild("ClientChatModules");
  1904. if l__ClientChatModules__87 then
  1905.  
  1906. else
  1907. return { "Message", "Whisper" };
  1908. end;
  1909. local l__ChatSettings__88 = l__ClientChatModules__87:FindFirstChild("ChatSettings");
  1910. if l__ChatSettings__88 then
  1911. local v89 = require(l__ChatSettings__88);
  1912. if v89.BubbleChatMessageTypes then
  1913. u20 = v89.BubbleChatMessageTypes;
  1914. return u20;
  1915. end;
  1916. end;
  1917. local l__ChatConstants__90 = l__ClientChatModules__87:FindFirstChild("ChatConstants");
  1918. if l__ChatConstants__90 then
  1919. local v91 = require(l__ChatConstants__90);
  1920. u20 = { v91.MessageTypeDefault, v91.MessageTypeWhisper };
  1921. end;
  1922. return u20;
  1923. end;
  1924. function checkAllowedMessageType(p108)
  1925. local v92 = getAllowedMessageTypes();
  1926. local v93 = #v92;
  1927. local v94 = 1 - 1;
  1928. while true do
  1929. if v92[v94] == p108.MessageType then
  1930. return true;
  1931. end;
  1932. if 0 <= 1 then
  1933. if v94 < v93 then
  1934.  
  1935. else
  1936. break;
  1937. end;
  1938. elseif v93 < v94 then
  1939.  
  1940. else
  1941. break;
  1942. end;
  1943. v94 = v94 + 1;
  1944. end;
  1945. return false;
  1946. end;
  1947. local v95 = l__ReplicatedStorage__2:WaitForChild("DefaultChatSystemChatEvents");
  1948. local l__OnMessageDoneFiltering__96 = v95:WaitForChild("OnMessageDoneFiltering");
  1949. v95:WaitForChild("OnNewMessage").OnClientEvent:connect(function(p109, p110)
  1950. if not checkAllowedMessageType(p109) then
  1951. return;
  1952. end;
  1953. local v97 = findPlayer(p109.FromSpeaker);
  1954. if not v97 then
  1955. return;
  1956. end;
  1957. if (not p109.IsFiltered or p109.FromSpeaker == v5.Name) and (p109.FromSpeaker ~= v5.Name or u6:ShowOwnFilteredMessage()) then
  1958. return;
  1959. end;
  1960. u6:OnPlayerChatMessage(v97, p109.Message, nil);
  1961. end);
  1962. l__OnMessageDoneFiltering__96.OnClientEvent:connect(function(p111, p112)
  1963. if not checkAllowedMessageType(p111) then
  1964. return;
  1965. end;
  1966. local v98 = findPlayer(p111.FromSpeaker);
  1967. if not v98 then
  1968. return;
  1969. end;
  1970. if p111.FromSpeaker == v5.Name and not u6:ShowOwnFilteredMessage() then
  1971. return;
  1972. end;
  1973. u6:OnPlayerChatMessage(v98, p111.Message, nil);
  1974. end);
  1975. Chatscript:
  1976. -- Script GUID: {68482062-39e6-4c6a-8611-8f9b7f475305}
  1977. -- Decompiled with the Synapse X Luau decompiler.
  1978.  
  1979. local v1 = false;
  1980. local v2, v3 = pcall(function()
  1981. return UserSettings():IsUserFeatureEnabled("UserHandleChatHotKeyWithContextActionService");
  1982. end);
  1983. if v2 then
  1984. v1 = v3;
  1985. end;
  1986. local l__ReplicatedStorage__4 = game:GetService("ReplicatedStorage");
  1987. local u1 = require(game:GetService("Chat"):WaitForChild("ClientChatModules"):WaitForChild("ChatSettings"));
  1988. local l__StarterGui__2 = game:GetService("StarterGui");
  1989. function SetCoreGuiChatConnections(p1)
  1990. local v5 = 0;
  1991. while true do
  1992. if v5 < 10 then
  1993.  
  1994. else
  1995. break;
  1996. end;
  1997. v5 = v5 + 1;
  1998. local v6, v7 = pcall(function()
  1999. l__StarterGui__2:SetCore("CoreGuiChatConnections", p1);
  2000. end);
  2001. if not v6 then
  2002.  
  2003. else
  2004. break;
  2005. end;
  2006. if not v6 then
  2007. if v5 == 10 then
  2008. error("Error calling SetCore CoreGuiChatConnections: " .. v7);
  2009. end;
  2010. end;
  2011. wait();
  2012. end;
  2013. end;
  2014. function checkBothChatTypesDisabled()
  2015. if u1.BubbleChatEnabled ~= nil then
  2016. if u1.ClassicChatEnabled ~= nil then
  2017.  
  2018. else
  2019. return false;
  2020. end;
  2021. else
  2022. return false;
  2023. end;
  2024. return not (u1.BubbleChatEnabled or u1.ClassicChatEnabled);
  2025. end;
  2026. if not game:GetService("GuiService"):IsTenFootInterface() and not game:GetService("UserInputService").VREnabled then
  2027. if not checkBothChatTypesDisabled() then
  2028. (function()
  2029. local v8 = {
  2030. ChatWindow = {},
  2031. SetCore = {},
  2032. GetCore = {}
  2033. };
  2034. v8.ChatWindow.ChatTypes = {};
  2035. v8.ChatWindow.ChatTypes.BubbleChatEnabled = u1.BubbleChatEnabled;
  2036. v8.ChatWindow.ChatTypes.ClassicChatEnabled = u1.ClassicChatEnabled;
  2037. local u3 = require(script:WaitForChild("ChatMain"));
  2038. local function v9(p2)
  2039. local v10 = Instance.new("BindableEvent");
  2040. v10.Name = p2;
  2041. v8.ChatWindow[p2] = v10;
  2042. v10.Event:connect(function(...)
  2043. u3[p2](u3, ...);
  2044. end);
  2045. end;
  2046. local function v11(p3)
  2047. local v12 = Instance.new("BindableFunction");
  2048. v12.Name = p3;
  2049. v8.ChatWindow[p3] = v12;
  2050. function v12.OnInvoke(...)
  2051. return u3[p3](u3, ...);
  2052. end;
  2053. end;
  2054. local function v13(p4)
  2055. local v14 = Instance.new("BindableEvent");
  2056. v14.Name = p4;
  2057. v8.ChatWindow[p4] = v14;
  2058. u3[p4]:connect(function(...)
  2059. v14:Fire(...);
  2060. end);
  2061. end;
  2062. local function v15(p5)
  2063. local v16 = Instance.new("BindableEvent");
  2064. v16.Name = p5;
  2065. v8.SetCore[p5] = v16;
  2066. v16.Event:connect(function(...)
  2067. u3[p5 .. "Event"]:fire(...);
  2068. end);
  2069. end;
  2070. local function v17(p6)
  2071. local v18 = Instance.new("BindableFunction");
  2072. v18.Name = p6;
  2073. v8.GetCore[p6] = v18;
  2074. function v18.OnInvoke(...)
  2075. return u3["f" .. p6](...);
  2076. end;
  2077. end;
  2078. v9("ToggleVisibility");
  2079. v9("SetVisible");
  2080. v9("FocusChatBar");
  2081. v9("EnterWhisperState");
  2082. v11("GetVisibility");
  2083. v11("GetMessageCount");
  2084. v9("TopbarEnabledChanged");
  2085. v11("IsFocused");
  2086. v13("ChatBarFocusChanged");
  2087. v13("VisibilityStateChanged");
  2088. v13("MessagesChanged");
  2089. v13("MessagePosted");
  2090. (function(p7)
  2091. local v19 = Instance.new("BindableEvent");
  2092. v19.Name = p7;
  2093. v8.ChatWindow[p7] = v19;
  2094. v19.Event:connect(function(...)
  2095. u3[p7]:fire(...);
  2096. end);
  2097. end)("CoreGuiEnabled");
  2098. v15("ChatMakeSystemMessage");
  2099. v15("ChatWindowPosition");
  2100. v15("ChatWindowSize");
  2101. v17("ChatWindowPosition");
  2102. v17("ChatWindowSize");
  2103. v15("ChatBarDisabled");
  2104. v17("ChatBarDisabled");
  2105. if not v1 then
  2106. v9("SpecialKeyPressed");
  2107. end;
  2108. SetCoreGuiChatConnections(v8);
  2109. end)();
  2110. else
  2111. local v20 = {
  2112. ChatWindow = {}
  2113. };
  2114. v20.ChatWindow.ChatTypes = {};
  2115. v20.ChatWindow.ChatTypes.BubbleChatEnabled = false;
  2116. v20.ChatWindow.ChatTypes.ClassicChatEnabled = false;
  2117. SetCoreGuiChatConnections(v20);
  2118. end;
  2119. else
  2120. l__ReplicatedStorage__4:WaitForChild("DefaultChatSystemChatEvents").GetInitDataRequest:InvokeServer();
  2121. end;
  2122. chatmain:
  2123. -- Script GUID: {eb76fd28-332f-4b23-b216-15bb200ad356}
  2124. --[[VARIABLE DEFINITION ANOMALY DETECTED, DECOMPILATION OUTPUT POTENTIALLY INCORRECT]]--
  2125. -- Decompiled with the Synapse X Luau decompiler.
  2126.  
  2127. local v1 = false;
  2128. local v2, v3 = pcall(function()
  2129. return UserSettings():IsUserFeatureEnabled("UserFixChatWindowHoverOver");
  2130. end);
  2131. if v2 then
  2132. v1 = v3;
  2133. end;
  2134. local v4 = false;
  2135. local v5, v6 = pcall(function()
  2136. return UserSettings():IsUserFeatureEnabled("UserFixMouseCapture");
  2137. end);
  2138. if v5 then
  2139. v4 = v6;
  2140. end;
  2141. local v7 = false;
  2142. local v8, v9 = pcall(function()
  2143. return UserSettings():IsUserFeatureEnabled("UserHandleChatHotKeyWithContextActionService");
  2144. end);
  2145. if v8 then
  2146. v7 = v9;
  2147. end;
  2148. local l__RunService__10 = game:GetService("RunService");
  2149. local l__ReplicatedStorage__11 = game:GetService("ReplicatedStorage");
  2150. local l__Chat__12 = game:GetService("Chat");
  2151. local l__StarterGui__13 = game:GetService("StarterGui");
  2152. local l__ContextActionService__14 = game:GetService("ContextActionService");
  2153. local v15 = l__ReplicatedStorage__11:WaitForChild("DefaultChatSystemChatEvents");
  2154. local v16 = l__ReplicatedStorage__11:WaitForChild("DefaultChatSystemChatEvents");
  2155. local l__ClientChatModules__17 = l__Chat__12:WaitForChild("ClientChatModules");
  2156. local v18 = require(l__ClientChatModules__17:WaitForChild("ChatConstants"));
  2157. local v19 = require(l__ClientChatModules__17:WaitForChild("ChatSettings"));
  2158. local v20 = require(l__ClientChatModules__17:WaitForChild("MessageCreatorModules"):WaitForChild("Util"));
  2159. local u1 = nil;
  2160. pcall(function()
  2161. u1 = require(game:GetService("Chat").ClientChatModules.ChatLocalization);
  2162. end);
  2163. if u1 == nil then
  2164. u1 = {
  2165. Get = function(p1, p2, p3)
  2166. return p3;
  2167. end
  2168. };
  2169. end;
  2170. local v21, v22 = pcall(function()
  2171. return UserSettings():IsUserFeatureEnabled("UserChatNewMessageLengthCheck2");
  2172. end);
  2173. local v23 = Instance.new("BindableEvent");
  2174. local u2 = {
  2175. OnNewMessage = "RemoteEvent",
  2176. OnMessageDoneFiltering = "RemoteEvent",
  2177. OnNewSystemMessage = "RemoteEvent",
  2178. OnChannelJoined = "RemoteEvent",
  2179. OnChannelLeft = "RemoteEvent",
  2180. OnMuted = "RemoteEvent",
  2181. OnUnmuted = "RemoteEvent",
  2182. OnMainChannelSet = "RemoteEvent",
  2183. SayMessageRequest = "RemoteEvent",
  2184. GetInitDataRequest = "RemoteFunction"
  2185. };
  2186. local u3 = {};
  2187. local u4 = 10;
  2188. function TryRemoveChildWithVerifyingIsCorrectType(p4)
  2189. if u2[p4.Name] then
  2190. if p4:IsA(u2[p4.Name]) then
  2191. u2[p4.Name] = nil;
  2192. u3[p4.Name] = p4;
  2193. u4 = u4 - 1;
  2194. end;
  2195. end;
  2196. end;
  2197. for v24, v25 in pairs(v16:GetChildren()) do
  2198. TryRemoveChildWithVerifyingIsCorrectType(v25);
  2199. end;
  2200. if u4 > 0 then
  2201. local v26 = v16.ChildAdded:connect(function(p5)
  2202. TryRemoveChildWithVerifyingIsCorrectType(p5);
  2203. if u4 < 1 then
  2204. v23:Fire();
  2205. end;
  2206. end);
  2207. v23.Event:wait();
  2208. v26:disconnect();
  2209. v23:Destroy();
  2210. end;
  2211. local l__UserInputService__27 = game:GetService("UserInputService");
  2212. local l__RunService__28 = game:GetService("RunService");
  2213. local l__Players__29 = game:GetService("Players");
  2214. local v30 = l__Players__29.LocalPlayer;
  2215. while not v30 do
  2216. l__Players__29.ChildAdded:wait();
  2217. v30 = l__Players__29.LocalPlayer;
  2218. end;
  2219. local v31 = 6;
  2220. if v19.ScreenGuiDisplayOrder ~= nil then
  2221. v31 = v19.ScreenGuiDisplayOrder;
  2222. end;
  2223. local v32 = Instance.new("ScreenGui");
  2224. v32.Name = "Chat";
  2225. v32.ResetOnSpawn = false;
  2226. v32.DisplayOrder = v31;
  2227. v32.Parent = v30:WaitForChild("PlayerGui");
  2228. local v33 = require(script:WaitForChild("MessageLabelCreator"));
  2229. local v34 = require(script:WaitForChild("MessageLogDisplay"));
  2230. local v35 = require(script:WaitForChild("ChatChannel"));
  2231. local v36 = require(script:WaitForChild("ChatWindow")).new();
  2232. local v37 = require(script:WaitForChild("ChannelsBar")).new();
  2233. local v38 = v34.new();
  2234. local v39 = require(script:WaitForChild("CommandProcessor")).new();
  2235. local v40 = require(script:WaitForChild("ChatBar")).new(v39, v36);
  2236. v36:CreateGuiObjects(v32);
  2237. v36:RegisterChatBar(v40);
  2238. v36:RegisterChannelsBar(v37);
  2239. v36:RegisterMessageLogDisplay(v38);
  2240. v20:RegisterChatWindow(v36);
  2241. local v41 = require(script:WaitForChild("MessageSender"));
  2242. v41:RegisterSayMessageFunction(u3.SayMessageRequest);
  2243. if l__UserInputService__27.TouchEnabled then
  2244. v40:SetTextLabelText(u1:Get("GameChat_ChatMain_ChatBarTextTouch", "Tap here to chat"));
  2245. else
  2246. v40:SetTextLabelText(u1:Get("GameChat_ChatMain_ChatBarText", "To chat click here or press \"/\" key"));
  2247. end;
  2248. local l__script__5 = script;
  2249. spawn(function()
  2250. local v42 = require(l__script__5:WaitForChild("CurveUtil"));
  2251. local v43 = 1 / (v19.ChatAnimationFPS and 20);
  2252. local v44 = tick();
  2253. while true do
  2254. local v45 = tick();
  2255. local v46 = v42:DeltaTimeToTimescale(v45 - v44);
  2256. if v46 ~= 0 then
  2257. v36:Update(v46);
  2258. end;
  2259. v44 = v45;
  2260. wait(v43);
  2261. end;
  2262. end);
  2263. function CheckIfPointIsInSquare(p6, p7, p8)
  2264. local v47 = false;
  2265. if p7.X <= p6.X then
  2266. v47 = false;
  2267. if p6.X <= p8.X then
  2268. v47 = false;
  2269. if p7.Y <= p6.Y then
  2270. v47 = p6.Y <= p8.Y;
  2271. end;
  2272. end;
  2273. end;
  2274. return v47;
  2275. end;
  2276. local u6 = 0;
  2277. local u7 = false;
  2278. local u8 = Instance.new("BindableEvent");
  2279. function DoBackgroundFadeIn(p9)
  2280. u6 = tick();
  2281. u7 = false;
  2282. u8:Fire();
  2283. v36:FadeInBackground(p9 or v19.ChatDefaultFadeDuration);
  2284. if v36:GetCurrentChannel() then
  2285. local l__Scroller__48 = v38.Scroller;
  2286. l__Scroller__48.ScrollingEnabled = true;
  2287. l__Scroller__48.ScrollBarThickness = v34.ScrollBarThickness;
  2288. end;
  2289. end;
  2290. function DoBackgroundFadeOut(p10)
  2291. u6 = tick();
  2292. u7 = true;
  2293. u8:Fire();
  2294. v36:FadeOutBackground(p10 or v19.ChatDefaultFadeDuration);
  2295. if v36:GetCurrentChannel() then
  2296. local l__Scroller__49 = v38.Scroller;
  2297. l__Scroller__49.ScrollingEnabled = false;
  2298. l__Scroller__49.ScrollBarThickness = 0;
  2299. end;
  2300. end;
  2301. local u9 = 0;
  2302. local u10 = false;
  2303. function DoTextFadeIn(p11)
  2304. u9 = tick();
  2305. u10 = false;
  2306. u8:Fire();
  2307. v36:FadeInText((p11 or v19.ChatDefaultFadeDuration) * 0);
  2308. end;
  2309. function DoTextFadeOut(p12)
  2310. u9 = tick();
  2311. u10 = true;
  2312. u8:Fire();
  2313. v36:FadeOutText(p12 or v19.ChatDefaultFadeDuration);
  2314. end;
  2315. function DoFadeInFromNewInformation()
  2316. DoTextFadeIn();
  2317. if v19.ChatShouldFadeInFromNewInformation then
  2318. DoBackgroundFadeIn();
  2319. end;
  2320. end;
  2321. function InstantFadeIn()
  2322. DoBackgroundFadeIn(0);
  2323. DoTextFadeIn(0);
  2324. end;
  2325. function InstantFadeOut()
  2326. DoBackgroundFadeOut(0);
  2327. DoTextFadeOut(0);
  2328. end;
  2329. local u11 = nil;
  2330. local u12 = Instance.new("BindableEvent");
  2331. function UpdateFadingForMouseState(p13)
  2332. u11 = p13;
  2333. u12:Fire();
  2334. if v40:IsFocused() then
  2335. return;
  2336. end;
  2337. if p13 then
  2338.  
  2339. else
  2340. DoBackgroundFadeIn();
  2341. return;
  2342. end;
  2343. DoBackgroundFadeIn();
  2344. DoTextFadeIn();
  2345. end;
  2346. local u13 = Instance.new("BindableEvent");
  2347. spawn(function()
  2348. while true do
  2349. l__RunService__28.RenderStepped:wait();
  2350. while not (not u11) or not (not v40:IsFocused()) do
  2351. if u11 then
  2352. u12.Event:wait();
  2353. end;
  2354. if v40:IsFocused() then
  2355. u13.Event:wait();
  2356. end;
  2357. end;
  2358. if not u7 then
  2359. if v19.ChatWindowBackgroundFadeOutTime < tick() - u6 then
  2360. DoBackgroundFadeOut();
  2361. end;
  2362. elseif not u10 then
  2363. if v19.ChatWindowTextFadeOutTime < tick() - u9 then
  2364. DoTextFadeOut();
  2365. end;
  2366. else
  2367. u8.Event:wait();
  2368. end;
  2369. end;
  2370. end);
  2371. function getClassicChatEnabled()
  2372. if v19.ClassicChatEnabled ~= nil then
  2373. return v19.ClassicChatEnabled;
  2374. end;
  2375. return l__Players__29.ClassicChat;
  2376. end;
  2377. function getBubbleChatEnabled()
  2378. if v19.BubbleChatEnabled ~= nil then
  2379. return v19.BubbleChatEnabled;
  2380. end;
  2381. return l__Players__29.BubbleChat;
  2382. end;
  2383. function bubbleChatOnly()
  2384. return not getClassicChatEnabled() and getBubbleChatEnabled();
  2385. end;
  2386. local u14 = {};
  2387. function UpdateMousePosition(p14, p15)
  2388. if u14.Visible then
  2389. if u14.IsCoreGuiEnabled then
  2390. if not u14.TopbarEnabled then
  2391. if not v19.ChatOnWithTopBarOff then
  2392. return;
  2393. end;
  2394. end;
  2395. else
  2396. return;
  2397. end;
  2398. else
  2399. return;
  2400. end;
  2401. if bubbleChatOnly() then
  2402. return;
  2403. end;
  2404. local l__AbsolutePosition__50 = v36.GuiObject.AbsolutePosition;
  2405. local v51 = CheckIfPointIsInSquare(p14, l__AbsolutePosition__50, l__AbsolutePosition__50 + v36.GuiObject.AbsoluteSize);
  2406. if v1 then
  2407. if p15 then
  2408. if v51 == true then
  2409. return;
  2410. end;
  2411. end;
  2412. end;
  2413. if v51 ~= u11 then
  2414. UpdateFadingForMouseState(v51);
  2415. end;
  2416. end;
  2417. l__UserInputService__27.InputChanged:connect(function(p16, p17)
  2418. if p16.UserInputType == Enum.UserInputType.MouseMovement then
  2419. UpdateMousePosition(Vector2.new(p16.Position.X, p16.Position.Y), p17);
  2420. end;
  2421. end);
  2422. l__UserInputService__27.TouchTap:connect(function(p18, p19)
  2423. UpdateMousePosition(p18[1], false);
  2424. end);
  2425. l__UserInputService__27.TouchMoved:connect(function(p20, p21)
  2426. UpdateMousePosition(Vector2.new(p20.Position.X, p20.Position.Y), false);
  2427. end);
  2428. if not v4 then
  2429. l__UserInputService__27.Changed:connect(function(p22)
  2430. if p22 == "MouseBehavior" and l__UserInputService__27.MouseBehavior == Enum.MouseBehavior.LockCenter then
  2431. local l__AbsolutePosition__52 = v36.GuiObject.AbsolutePosition;
  2432. if CheckIfPointIsInSquare(v32.AbsoluteSize / 2, l__AbsolutePosition__52, l__AbsolutePosition__52 + v36.GuiObject.AbsoluteSize) then
  2433. l__UserInputService__27.MouseBehavior = Enum.MouseBehavior.Default;
  2434. end;
  2435. end;
  2436. end);
  2437. end;
  2438. UpdateFadingForMouseState(true);
  2439. UpdateFadingForMouseState(false);
  2440. local v53 = {
  2441. Signal = function()
  2442. local v54 = {};
  2443. local u15 = nil;
  2444. local u16 = nil;
  2445. local u17 = Instance.new("BindableEvent");
  2446. function v54.fire(p23, ...)
  2447. u15 = { ... };
  2448. u16 = select("#", ...);
  2449. u17:Fire();
  2450. end;
  2451. function v54.connect(p24, p25)
  2452. if not p25 then
  2453. error("connect(nil)", 2);
  2454. end;
  2455. return u17.Event:connect(function()
  2456. p25(unpack(u15, 1, u16));
  2457. end);
  2458. end;
  2459. function v54.wait(p26)
  2460. u17.Event:wait();
  2461. assert(u15, "Missing arg data, likely due to :TweenSize/Position corrupting threadrefs.");
  2462. return unpack(u15, 1, u16);
  2463. end;
  2464. return v54;
  2465. end
  2466. };
  2467. function SetVisibility(p27)
  2468. v36:SetVisible(p27);
  2469. u14.VisibilityStateChanged:fire(p27);
  2470. u14.Visible = p27;
  2471. if u14.IsCoreGuiEnabled then
  2472. if p27 then
  2473.  
  2474. else
  2475. InstantFadeOut();
  2476. return;
  2477. end;
  2478. else
  2479. return;
  2480. end;
  2481. InstantFadeIn();
  2482. end;
  2483. u14.TopbarEnabled = true;
  2484. u14.MessageCount = 0;
  2485. u14.Visible = true;
  2486. u14.IsCoreGuiEnabled = true;
  2487. function u14.ToggleVisibility(p28)
  2488. SetVisibility(not v36:GetVisible());
  2489. end;
  2490. function u14.SetVisible(p29, p30)
  2491. if v36:GetVisible() ~= p30 then
  2492. SetVisibility(p30);
  2493. end;
  2494. end;
  2495. function u14.FocusChatBar(p31)
  2496. v40:CaptureFocus();
  2497. end;
  2498. function u14.EnterWhisperState(p32, p33)
  2499. v40:EnterWhisperState(p33);
  2500. end;
  2501. function u14.GetVisibility(p34)
  2502. return v36:GetVisible();
  2503. end;
  2504. function u14.GetMessageCount(p35)
  2505. return p35.MessageCount;
  2506. end;
  2507. function u14.TopbarEnabledChanged(p36, p37)
  2508. p36.TopbarEnabled = p37;
  2509. p36.CoreGuiEnabled:fire(game:GetService("StarterGui"):GetCoreGuiEnabled(Enum.CoreGuiType.Chat));
  2510. end;
  2511. function u14.IsFocused(p38, p39)
  2512. return v40:IsFocused();
  2513. end;
  2514. u14.ChatBarFocusChanged = v53.Signal();
  2515. u14.VisibilityStateChanged = v53.Signal();
  2516. u14.MessagesChanged = v53.Signal();
  2517. u14.MessagePosted = v53.Signal();
  2518. u14.CoreGuiEnabled = v53.Signal();
  2519. u14.ChatMakeSystemMessageEvent = v53.Signal();
  2520. u14.ChatWindowPositionEvent = v53.Signal();
  2521. u14.ChatWindowSizeEvent = v53.Signal();
  2522. u14.ChatBarDisabledEvent = v53.Signal();
  2523. function u14.fChatWindowPosition(p40)
  2524. return v36.GuiObject.Position;
  2525. end;
  2526. function u14.fChatWindowSize(p41)
  2527. return v36.GuiObject.Size;
  2528. end;
  2529. function u14.fChatBarDisabled(p42)
  2530. return not v40:GetEnabled();
  2531. end;
  2532. if v7 then
  2533. local u18 = true;
  2534. l__ContextActionService__14:BindAction("ToggleChat", function(p43, p44, p45)
  2535. if p43 == "ToggleChat" and p44 == Enum.UserInputState.Begin and u18 and p45.UserInputType == Enum.UserInputType.Keyboard then
  2536. DoChatBarFocus();
  2537. end;
  2538. end, true, Enum.KeyCode.Slash);
  2539. else
  2540. local u19 = true;
  2541. function u14.SpecialKeyPressed(p46, p47, p48)
  2542. if p47 == Enum.SpecialKey.ChatHotkey and u19 then
  2543. DoChatBarFocus();
  2544. end;
  2545. end;
  2546. end;
  2547. u14.CoreGuiEnabled:connect(function(p49)
  2548. u14.IsCoreGuiEnabled = p49;
  2549. p49 = p49 and (u14.TopbarEnabled or v19.ChatOnWithTopBarOff);
  2550. v36:SetCoreGuiEnabled(p49);
  2551. if p49 then
  2552. InstantFadeIn();
  2553. return;
  2554. end;
  2555. v40:ReleaseFocus();
  2556. InstantFadeOut();
  2557. end);
  2558. function trimTrailingSpaces(p50)
  2559. local v55 = #p50;
  2560. while true do
  2561. if 0 < v55 then
  2562.  
  2563. else
  2564. break;
  2565. end;
  2566. if p50:find("^%s", v55) then
  2567.  
  2568. else
  2569. break;
  2570. end;
  2571. v55 = v55 - 1;
  2572. end;
  2573. return p50:sub(1, v55);
  2574. end;
  2575. local u20 = false;
  2576. u14.ChatMakeSystemMessageEvent:connect(function(p51)
  2577. if p51.Text and type(p51.Text) == "string" then
  2578. while not u20 do
  2579. wait();
  2580. end;
  2581. local l__GeneralChannelName__56 = v19.GeneralChannelName;
  2582. local v57 = v36:GetChannel(l__GeneralChannelName__56);
  2583. if v57 then
  2584. v57:AddMessageToChannel({
  2585. ID = -1,
  2586. FromSpeaker = nil,
  2587. SpeakerUserId = 0,
  2588. OriginalChannel = l__GeneralChannelName__56,
  2589. IsFiltered = true,
  2590. MessageLength = string.len(p51.Text),
  2591. Message = trimTrailingSpaces(p51.Text),
  2592. MessageType = v18.MessageTypeSetCore,
  2593. Time = os.time(),
  2594. ExtraData = p51
  2595. });
  2596. v37:UpdateMessagePostedInChannel(l__GeneralChannelName__56);
  2597. u14.MessageCount = u14.MessageCount + 1;
  2598. u14.MessagesChanged:fire(u14.MessageCount);
  2599. end;
  2600. end;
  2601. end);
  2602. u14.ChatBarDisabledEvent:connect(function(p52)
  2603. if u19 then
  2604. v40:SetEnabled(not p52);
  2605. if p52 then
  2606. v40:ReleaseFocus();
  2607. end;
  2608. end;
  2609. end);
  2610. u14.ChatWindowSizeEvent:connect(function(p53)
  2611. v36.GuiObject.Size = p53;
  2612. end);
  2613. u14.ChatWindowPositionEvent:connect(function(p54)
  2614. v36.GuiObject.Position = p54;
  2615. end);
  2616. function DoChatBarFocus()
  2617. if not v36:GetCoreGuiEnabled() then
  2618. return;
  2619. end;
  2620. if not v40:GetEnabled() then
  2621. return;
  2622. end;
  2623. if not v40:IsFocused() then
  2624. if v40:GetVisible() then
  2625. u14:SetVisible(true);
  2626. InstantFadeIn();
  2627. v40:CaptureFocus();
  2628. u14.ChatBarFocusChanged:fire(true);
  2629. end;
  2630. end;
  2631. end;
  2632. u13.Event:connect(function(p55)
  2633. u14.ChatBarFocusChanged:fire(p55);
  2634. end);
  2635. function DoSwitchCurrentChannel(p56)
  2636. if v36:GetChannel(p56) then
  2637. v36:SwitchCurrentChannel(p56);
  2638. end;
  2639. end;
  2640. function SendMessageToSelfInTargetChannel(p57, p58, p59)
  2641. local v58 = v36:GetChannel(p58);
  2642. if v58 then
  2643. v58:AddMessageToChannel({
  2644. ID = -1,
  2645. FromSpeaker = nil,
  2646. SpeakerUserId = 0,
  2647. OriginalChannel = p58,
  2648. IsFiltered = true,
  2649. MessageLength = string.len(p57),
  2650. Message = trimTrailingSpaces(p57),
  2651. MessageType = v18.MessageTypeSystem,
  2652. Time = os.time(),
  2653. ExtraData = p59
  2654. });
  2655. end;
  2656. end;
  2657. function chatBarFocused()
  2658. if not u11 then
  2659. DoBackgroundFadeIn();
  2660. if u10 then
  2661. DoTextFadeIn();
  2662. end;
  2663. end;
  2664. u13:Fire(true);
  2665. end;
  2666. local u21 = v21 or v22;
  2667. function chatBarFocusLost(p60, p61)
  2668. DoBackgroundFadeIn();
  2669. u13:Fire(false);
  2670. if p60 then
  2671. local v59 = v40:GetTextBox().Text;
  2672. if v40:IsInCustomState() then
  2673. local v60 = v40:GetCustomMessage();
  2674. if v60 then
  2675. v59 = v60;
  2676. end;
  2677. local v61 = v40:CustomStateProcessCompletedMessage(v59);
  2678. v40:ResetCustomState();
  2679. if v61 then
  2680. return;
  2681. end;
  2682. end;
  2683. if not u21 then
  2684. v59 = string.sub(v59, 1, v19.MaximumMessageLength);
  2685. end;
  2686. v40:GetTextBox().Text = "";
  2687. if v59 ~= "" then
  2688. u14.MessagePosted:fire(v59);
  2689. if not v39:ProcessCompletedChatMessage(v59, v36) then
  2690. local v62 = nil;
  2691. if v19.DisallowedWhiteSpace then
  2692. local v63 = #v19.DisallowedWhiteSpace;
  2693. local v64 = 1 - 1;
  2694. while true do
  2695. if v19.DisallowedWhiteSpace[v64] == "\t" then
  2696. v59 = string.gsub(v59, v19.DisallowedWhiteSpace[v64], " ");
  2697. else
  2698. v59 = string.gsub(v59, v19.DisallowedWhiteSpace[v64], "");
  2699. end;
  2700. if 0 <= 1 then
  2701. if v64 < v63 then
  2702.  
  2703. else
  2704. break;
  2705. end;
  2706. elseif v63 < v64 then
  2707.  
  2708. else
  2709. break;
  2710. end;
  2711. v64 = v64 + 1;
  2712. end;
  2713. end;
  2714. v62 = string.gsub(string.gsub(v59, "\n", ""), "[ ]+", " ");
  2715. local v65 = v36:GetTargetMessageChannel();
  2716. if v65 then
  2717. v41:SendMessage(v62, v65);
  2718. return;
  2719. end;
  2720. v41:SendMessage(v62, nil);
  2721. end;
  2722. end;
  2723. end;
  2724. end;
  2725. local u22 = {};
  2726. function setupChatBarConnections()
  2727. local v66 = #u22;
  2728. local v67 = 1 - 1;
  2729. while true do
  2730. u22[v67]:Disconnect();
  2731. if 0 <= 1 then
  2732. if v67 < v66 then
  2733.  
  2734. else
  2735. break;
  2736. end;
  2737. elseif v66 < v67 then
  2738.  
  2739. else
  2740. break;
  2741. end;
  2742. v67 = v67 + 1;
  2743. end;
  2744. u22 = {};
  2745. table.insert(u22, (v40:GetTextBox().FocusLost:connect(chatBarFocusLost)));
  2746. table.insert(u22, (v40:GetTextBox().Focused:connect(chatBarFocused)));
  2747. end;
  2748. setupChatBarConnections();
  2749. v40.GuiObjectsChanged:connect(setupChatBarConnections);
  2750. function getEchoMessagesInGeneral()
  2751. if v19.EchoMessagesInGeneralChannel == nil then
  2752. return true;
  2753. end;
  2754. return v19.EchoMessagesInGeneralChannel;
  2755. end;
  2756. u3.OnMessageDoneFiltering.OnClientEvent:connect(function(p62)
  2757. if not v19.ShowUserOwnFilteredMessage and p62.FromSpeaker == v30.Name then
  2758. return;
  2759. end;
  2760. local l__OriginalChannel__68 = p62.OriginalChannel;
  2761. local v69 = v36:GetChannel(l__OriginalChannel__68);
  2762. if v69 then
  2763. v69:UpdateMessageFiltered(p62);
  2764. end;
  2765. if getEchoMessagesInGeneral() and v19.GeneralChannelName and l__OriginalChannel__68 ~= v19.GeneralChannelName then
  2766. local v70 = v36:GetChannel(v19.GeneralChannelName);
  2767. if v70 then
  2768. v70:UpdateMessageFiltered(p62);
  2769. end;
  2770. end;
  2771. end);
  2772. u3.OnNewMessage.OnClientEvent:connect(function(p63, p64)
  2773. local v71 = v36:GetChannel(p64);
  2774. if v71 then
  2775. v71:AddMessageToChannel(p63);
  2776. if p63.FromSpeaker ~= v30.Name then
  2777. v37:UpdateMessagePostedInChannel(p64);
  2778. end;
  2779. if getEchoMessagesInGeneral() and v19.GeneralChannelName and p64 ~= v19.GeneralChannelName then
  2780. local v72 = v36:GetChannel(v19.GeneralChannelName);
  2781. if v72 then
  2782. v72:AddMessageToChannel(p63);
  2783. end;
  2784. end;
  2785. u14.MessageCount = u14.MessageCount + 1;
  2786. u14.MessagesChanged:fire(u14.MessageCount);
  2787. DoFadeInFromNewInformation();
  2788. end;
  2789. end);
  2790. u3.OnNewSystemMessage.OnClientEvent:connect(function(p65, p66)
  2791. p66 = p66 and "System";
  2792. local v73 = v36:GetChannel(p66);
  2793. if v73 then
  2794. v73:AddMessageToChannel(p65);
  2795. v37:UpdateMessagePostedInChannel(p66);
  2796. u14.MessageCount = u14.MessageCount + 1;
  2797. u14.MessagesChanged:fire(u14.MessageCount);
  2798. DoFadeInFromNewInformation();
  2799. if getEchoMessagesInGeneral() and v19.GeneralChannelName and p66 ~= v19.GeneralChannelName then
  2800. local v74 = v36:GetChannel(v19.GeneralChannelName);
  2801. if v74 then
  2802. v74:AddMessageToChannel(p65);
  2803. return;
  2804. end;
  2805. end;
  2806. else
  2807. warn(string.format("Just received system message for channel I'm not in [%s]", p66));
  2808. end;
  2809. end);
  2810. function HandleChannelJoined(p67, p68, p69, p70, p71, p72)
  2811. if v36:GetChannel(p67) then
  2812. v36:RemoveChannel(p67);
  2813. end;
  2814. if p67 == v19.GeneralChannelName then
  2815. u20 = true;
  2816. end;
  2817. if p70 then
  2818. v40:SetChannelNameColor(p67, p70);
  2819. end;
  2820. local v75 = v36:AddChannel(p67);
  2821. if v75 then
  2822. if p67 == v19.GeneralChannelName then
  2823. DoSwitchCurrentChannel(p67);
  2824. end;
  2825. if p69 then
  2826. local v76 = 1;
  2827. if v19.MessageHistoryLengthPerChannel < #p69 then
  2828. v76 = #p69 - v19.MessageHistoryLengthPerChannel;
  2829. end;
  2830. local v77 = #p69;
  2831. local v78 = v76 - 1;
  2832. while true do
  2833. v75:AddMessageToChannel(p69[v78]);
  2834. if 0 <= 1 then
  2835. if v78 < v77 then
  2836.  
  2837. else
  2838. break;
  2839. end;
  2840. elseif v77 < v78 then
  2841.  
  2842. else
  2843. break;
  2844. end;
  2845. v78 = v78 + 1;
  2846. end;
  2847. if getEchoMessagesInGeneral() then
  2848. if p71 then
  2849. if v19.GeneralChannelName then
  2850. if p67 ~= v19.GeneralChannelName then
  2851. local v79 = v36:GetChannel(v19.GeneralChannelName);
  2852. if v79 then
  2853. v79:AddMessagesToChannelByTimeStamp(p69, v76);
  2854. end;
  2855. end;
  2856. end;
  2857. end;
  2858. end;
  2859. end;
  2860. if p68 ~= "" then
  2861. local v80 = {
  2862. ID = -1,
  2863. FromSpeaker = nil,
  2864. SpeakerUserId = 0,
  2865. OriginalChannel = p67,
  2866. IsFiltered = true,
  2867. MessageLength = string.len(p68),
  2868. Message = trimTrailingSpaces(p68),
  2869. MessageType = v18.MessageTypeWelcome,
  2870. Time = os.time(),
  2871. ExtraData = nil
  2872. };
  2873. v75:AddMessageToChannel(v80);
  2874. if getEchoMessagesInGeneral() then
  2875. if p72 then
  2876. if not v19.ShowChannelsBar then
  2877. if p67 ~= v19.GeneralChannelName then
  2878. local v81 = v36:GetChannel(v19.GeneralChannelName);
  2879. if v81 then
  2880. v81:AddMessageToChannel(v80);
  2881. end;
  2882. end;
  2883. end;
  2884. end;
  2885. end;
  2886. end;
  2887. DoFadeInFromNewInformation();
  2888. end;
  2889. end;
  2890. u3.OnChannelJoined.OnClientEvent:connect(function(p73, p74, p75, p76)
  2891. HandleChannelJoined(p73, p74, p75, p76, false, true);
  2892. end);
  2893. u3.OnChannelLeft.OnClientEvent:connect(function(p77)
  2894. v36:RemoveChannel(p77);
  2895. DoFadeInFromNewInformation();
  2896. end);
  2897. u3.OnMuted.OnClientEvent:connect(function(p78)
  2898.  
  2899. end);
  2900. u3.OnUnmuted.OnClientEvent:connect(function(p79)
  2901.  
  2902. end);
  2903. u3.OnMainChannelSet.OnClientEvent:connect(function(p80)
  2904. DoSwitchCurrentChannel(p80);
  2905. end);
  2906. coroutine.wrap(function()
  2907. local l__ChannelNameColorUpdated__82 = v15:WaitForChild("ChannelNameColorUpdated", 5);
  2908. if l__ChannelNameColorUpdated__82 then
  2909. l__ChannelNameColorUpdated__82.OnClientEvent:connect(function(p81, p82)
  2910. v40:SetChannelNameColor(p81, p82);
  2911. end);
  2912. end;
  2913. end)();
  2914. local u23 = nil;
  2915. local u24 = nil;
  2916. local u25 = nil;
  2917. local u26 = nil;
  2918. pcall(function()
  2919. u23 = l__StarterGui__13:GetCore("PlayerBlockedEvent");
  2920. u24 = l__StarterGui__13:GetCore("PlayerMutedEvent");
  2921. u25 = l__StarterGui__13:GetCore("PlayerUnblockedEvent");
  2922. u26 = l__StarterGui__13:GetCore("PlayerUnmutedEvent");
  2923. end);
  2924. function SendSystemMessageToSelf(p83)
  2925. local v83 = v36:GetCurrentChannel();
  2926. if v83 then
  2927. v83:AddMessageToChannel({
  2928. ID = -1,
  2929. FromSpeaker = nil,
  2930. SpeakerUserId = 0,
  2931. OriginalChannel = v83.Name,
  2932. IsFiltered = true,
  2933. MessageLength = string.len(p83),
  2934. Message = trimTrailingSpaces(p83),
  2935. MessageType = v18.MessageTypeSystem,
  2936. Time = os.time(),
  2937. ExtraData = nil
  2938. });
  2939. end;
  2940. end;
  2941. function MutePlayer(p84)
  2942. local l__MutePlayerRequest__84 = v15:FindFirstChild("MutePlayerRequest");
  2943. if l__MutePlayerRequest__84 then
  2944.  
  2945. else
  2946. return false;
  2947. end;
  2948. return l__MutePlayerRequest__84:InvokeServer(p84.Name);
  2949. end;
  2950. if u23 then
  2951. u23.Event:connect(function(p85)
  2952. if MutePlayer(p85) then
  2953. if v19.PlayerDisplayNamesEnabled then
  2954. local v85 = p85.DisplayName;
  2955. else
  2956. v85 = p85.Name;
  2957. end;
  2958. SendSystemMessageToSelf(string.gsub(u1:Get("GameChat_ChatMain_SpeakerHasBeenBlocked", string.format("Speaker '%s' has been blocked.", v85)), "{RBX_NAME}", v85));
  2959. end;
  2960. end);
  2961. end;
  2962. if u24 then
  2963. u24.Event:connect(function(p86)
  2964. if MutePlayer(p86) then
  2965. if v19.PlayerDisplayNamesEnabled then
  2966. local v86 = p86.DisplayName;
  2967. else
  2968. v86 = p86.Name;
  2969. end;
  2970. SendSystemMessageToSelf(string.gsub(u1:Get("GameChat_ChatMain_SpeakerHasBeenMuted", string.format("Speaker '%s' has been muted.", v86)), "{RBX_NAME}", v86));
  2971. end;
  2972. end);
  2973. end;
  2974. function UnmutePlayer(p87)
  2975. local l__UnMutePlayerRequest__87 = v15:FindFirstChild("UnMutePlayerRequest");
  2976. if l__UnMutePlayerRequest__87 then
  2977.  
  2978. else
  2979. return false;
  2980. end;
  2981. return l__UnMutePlayerRequest__87:InvokeServer(p87.Name);
  2982. end;
  2983. if u25 then
  2984. u25.Event:connect(function(p88)
  2985. if UnmutePlayer(p88) then
  2986. if v19.PlayerDisplayNamesEnabled then
  2987. local v88 = p88.DisplayName;
  2988. else
  2989. v88 = p88.Name;
  2990. end;
  2991. SendSystemMessageToSelf(string.gsub(u1:Get("GameChat_ChatMain_SpeakerHasBeenUnBlocked", string.format("Speaker '%s' has been unblocked.", v88)), "{RBX_NAME}", v88));
  2992. end;
  2993. end);
  2994. end;
  2995. if u26 then
  2996. u26.Event:connect(function(p89)
  2997. if UnmutePlayer(p89) then
  2998. if v19.PlayerDisplayNamesEnabled then
  2999. local v89 = p89.DisplayName;
  3000. else
  3001. v89 = p89.Name;
  3002. end;
  3003. SendSystemMessageToSelf(string.gsub(u1:Get("GameChat_ChatMain_SpeakerHasBeenUnMuted", string.format("Speaker '%s' has been unmuted.", v89)), "{RBX_NAME}", v89));
  3004. end;
  3005. end);
  3006. end;
  3007. spawn(function()
  3008. if v30.UserId > 0 then
  3009. pcall(function()
  3010. local v90 = l__StarterGui__13:GetCore("GetBlockedUserIds");
  3011. if #v90 > 0 then
  3012. local l__SetBlockedUserIdsRequest__91 = v15:FindFirstChild("SetBlockedUserIdsRequest");
  3013. if l__SetBlockedUserIdsRequest__91 then
  3014. l__SetBlockedUserIdsRequest__91:FireServer(v90);
  3015. end;
  3016. end;
  3017. end);
  3018. end;
  3019. end);
  3020. spawn(function()
  3021. local v92, v93 = pcall(function()
  3022. return l__Chat__12:CanUserChatAsync(v30.UserId);
  3023. end);
  3024. if v92 then
  3025. u19 = l__RunService__28:IsStudio() and v93;
  3026. end;
  3027. end);
  3028. local v94 = u3.GetInitDataRequest:InvokeServer();
  3029. for v95, v96 in pairs(v94.Channels) do
  3030. if v96[1] == v19.GeneralChannelName then
  3031. HandleChannelJoined(v96[1], v96[2], v96[3], v96[4], true, false);
  3032. end;
  3033. end;
  3034. for v97, v98 in pairs(v94.Channels) do
  3035. if v98[1] ~= v19.GeneralChannelName then
  3036. HandleChannelJoined(v98[1], v98[2], v98[3], v98[4], true, false);
  3037. end;
  3038. end;
  3039. return u14;
  3040. Channelsbar:
  3041. -- Script GUID: {be3297a0-72d1-47b7-9780-04a82e644ed4}
  3042. -- Decompiled with the Synapse X Luau decompiler.
  3043.  
  3044. local v1 = {};
  3045. local l__PlayerGui__2 = game:GetService("Players").LocalPlayer:WaitForChild("PlayerGui");
  3046. local l__Parent__3 = script.Parent;
  3047. local v4 = {};
  3048. v4.__index = v4;
  3049. local u1 = require(game:GetService("Chat"):WaitForChild("ClientChatModules"):WaitForChild("ChatSettings"));
  3050. local u2 = require(l__Parent__3:WaitForChild("MessageSender"));
  3051. function v4.CreateGuiObjects(p1, p2)
  3052. local v5 = Instance.new("Frame");
  3053. v5.Selectable = false;
  3054. v5.Size = UDim2.new(1, 0, 1, 0);
  3055. v5.BackgroundTransparency = 1;
  3056. v5.Parent = p2;
  3057. local v6 = Instance.new("Frame");
  3058. v6.Selectable = false;
  3059. v6.Name = "ScrollingBase";
  3060. v6.BackgroundTransparency = 1;
  3061. v6.ClipsDescendants = true;
  3062. v6.Size = UDim2.new(1, 0, 1, 0);
  3063. v6.Position = UDim2.new(0, 0, 0, 0);
  3064. v6.Parent = v5;
  3065. local v7 = Instance.new("Frame");
  3066. v7.Selectable = false;
  3067. v7.Name = "ScrollerSizer";
  3068. v7.BackgroundTransparency = 1;
  3069. v7.Size = UDim2.new(1, 0, 1, 0);
  3070. v7.Position = UDim2.new(0, 0, 0, 0);
  3071. v7.Parent = v6;
  3072. local v8 = Instance.new("Frame");
  3073. v8.Selectable = false;
  3074. v8.Name = "ScrollerFrame";
  3075. v8.BackgroundTransparency = 1;
  3076. v8.Size = UDim2.new(1, 0, 1, 0);
  3077. v8.Position = UDim2.new(0, 0, 0, 0);
  3078. v8.Parent = v7;
  3079. local v9 = Instance.new("Frame");
  3080. v9.Selectable = false;
  3081. v9.Size = UDim2.new(1, 0, 1, 0);
  3082. v9.Position = UDim2.new(0, 0, 0, 0);
  3083. v9.ClipsDescendants = true;
  3084. v9.BackgroundTransparency = 1;
  3085. v9.Parent = v5;
  3086. local v10 = Instance.new("Frame");
  3087. v10.Selectable = false;
  3088. v10.Name = "LeaveConfirmationFrame";
  3089. v10.Size = UDim2.new(1, 0, 1, 0);
  3090. v10.Position = UDim2.new(0, 0, 1, 0);
  3091. v10.BackgroundTransparency = 0.6;
  3092. v10.BorderSizePixel = 0;
  3093. v10.BackgroundColor3 = Color3.new(0, 0, 0);
  3094. v10.Parent = v9;
  3095. local v11 = Instance.new("TextButton");
  3096. v11.Selectable = false;
  3097. v11.Size = UDim2.new(1, 0, 1, 0);
  3098. v11.BackgroundTransparency = 1;
  3099. v11.Text = "";
  3100. v11.Parent = v10;
  3101. local v12 = Instance.new("TextButton");
  3102. v12.Selectable = false;
  3103. v12.Size = UDim2.new(0.25, 0, 1, 0);
  3104. v12.BackgroundTransparency = 1;
  3105. v12.Font = u1.DefaultFont;
  3106. v12.TextSize = 18;
  3107. v12.TextStrokeTransparency = 0.75;
  3108. v12.Position = UDim2.new(0, 0, 0, 0);
  3109. v12.TextColor3 = Color3.new(0, 1, 0);
  3110. v12.Text = "Confirm";
  3111. v12.Parent = v10;
  3112. local v13 = v12:Clone();
  3113. v13.Parent = v10;
  3114. v13.Position = UDim2.new(0.75, 0, 0, 0);
  3115. v13.TextColor3 = Color3.new(1, 0, 0);
  3116. v13.Text = "Cancel";
  3117. local v14 = Instance.new("TextLabel");
  3118. v14.Selectable = false;
  3119. v14.Size = UDim2.new(0.5, 0, 1, 0);
  3120. v14.Position = UDim2.new(0.25, 0, 0, 0);
  3121. v14.BackgroundTransparency = 1;
  3122. v14.TextColor3 = Color3.new(1, 1, 1);
  3123. v14.TextStrokeTransparency = 0.75;
  3124. v14.Text = "Leave channel <XX>?";
  3125. v14.Font = u1.DefaultFont;
  3126. v14.TextSize = 18;
  3127. v14.Parent = v10;
  3128. local v15 = Instance.new("StringValue");
  3129. v15.Name = "LeaveTarget";
  3130. v15.Parent = v10;
  3131. local l__Position__3 = v10.Position;
  3132. v12.MouseButton1Click:connect(function()
  3133. u2:SendMessage(string.format("/leave %s", v15.Value), nil);
  3134. v10:TweenPosition(l__Position__3, Enum.EasingDirection.Out, Enum.EasingStyle.Quad, 0.2, true);
  3135. end);
  3136. v13.MouseButton1Click:connect(function()
  3137. v10:TweenPosition(l__Position__3, Enum.EasingDirection.Out, Enum.EasingStyle.Quad, 0.2, true);
  3138. end);
  3139. local v16 = Instance.new("ImageButton", v5);
  3140. v16.Selectable = u1.GamepadNavigationEnabled;
  3141. v16.Name = "PageLeftButton";
  3142. v16.SizeConstraint = Enum.SizeConstraint.RelativeYY;
  3143. v16.Size = UDim2.new(0.7, 0, 0.7, 0);
  3144. v16.BackgroundTransparency = 1;
  3145. v16.Position = UDim2.new(0, 4, 0.15000000000000002, 0);
  3146. v16.Visible = false;
  3147. v16.Image = "rbxassetid://471630199";
  3148. local v17 = Instance.new("ImageLabel", v16);
  3149. v17.Name = "ArrowLabel";
  3150. v17.BackgroundTransparency = 1;
  3151. v17.Size = UDim2.new(0.4, 0, 0.4, 0);
  3152. v17.Image = "rbxassetid://471630112";
  3153. local v18 = Instance.new("Frame", v5);
  3154. v18.Selectable = false;
  3155. v18.BackgroundTransparency = 1;
  3156. v18.Name = "PositionalHelper";
  3157. v18.Size = v16.Size;
  3158. v18.SizeConstraint = v16.SizeConstraint;
  3159. v18.Position = UDim2.new(1, 0, 0.15000000000000002, 0);
  3160. local v19 = v16:Clone();
  3161. v19.Parent = v18;
  3162. v19.Name = "PageRightButton";
  3163. v19.Size = UDim2.new(1, 0, 1, 0);
  3164. v19.SizeConstraint = Enum.SizeConstraint.RelativeXY;
  3165. v19.Position = UDim2.new(-1, -4, 0, 0);
  3166. local v20 = UDim2.new(0.05, 0, 0, 0);
  3167. v19.ArrowLabel.Position = UDim2.new(0.3, 0, 0.3, 0) + v20;
  3168. v16.ArrowLabel.Position = UDim2.new(0.3, 0, 0.3, 0) - v20;
  3169. v16.ArrowLabel.Rotation = 180;
  3170. p1.GuiObject = v5;
  3171. p1.GuiObjects.BaseFrame = v5;
  3172. p1.GuiObjects.ScrollerSizer = v7;
  3173. p1.GuiObjects.ScrollerFrame = v8;
  3174. p1.GuiObjects.PageLeftButton = v16;
  3175. p1.GuiObjects.PageRightButton = v19;
  3176. p1.GuiObjects.LeaveConfirmationFrame = v10;
  3177. p1.GuiObjects.LeaveConfirmationNotice = v14;
  3178. p1.GuiObjects.PageLeftButtonArrow = v16.ArrowLabel;
  3179. p1.GuiObjects.PageRightButtonArrow = v19.ArrowLabel;
  3180. p1:AnimGuiObjects();
  3181. v16.MouseButton1Click:connect(function()
  3182. p1:ScrollChannelsFrame(-1);
  3183. end);
  3184. v19.MouseButton1Click:connect(function()
  3185. p1:ScrollChannelsFrame(1);
  3186. end);
  3187. p1:ScrollChannelsFrame(0);
  3188. end;
  3189. function v4.UpdateMessagePostedInChannel(p3, p4)
  3190. local v21 = p3:GetChannelTab(p4);
  3191. if v21 then
  3192. v21:UpdateMessagePostedInChannel();
  3193. return;
  3194. end;
  3195. warn("ChannelsTab '" .. p4 .. "' does not exist!");
  3196. end;
  3197. local u4 = require(l__Parent__3:WaitForChild("ChannelsTab"));
  3198. function v4.AddChannelTab(p5, p6)
  3199. if p5:GetChannelTab(p6) then
  3200. error("Channel tab '" .. p6 .. "'already exists!");
  3201. end;
  3202. local v22 = u4.new(p6);
  3203. v22.GuiObject.Parent = p5.GuiObjects.ScrollerFrame;
  3204. p5.ChannelTabs[p6:lower()] = v22;
  3205. p5.NumTabs = p5.NumTabs + 1;
  3206. p5:OrganizeChannelTabs();
  3207. if u1.RightClickToLeaveChannelEnabled then
  3208. v22.NameTag.MouseButton2Click:connect(function()
  3209. p5.LeaveConfirmationNotice.Text = string.format("Leave channel %s?", v22.ChannelName);
  3210. p5.LeaveConfirmationFrame.LeaveTarget.Value = v22.ChannelName;
  3211. p5.LeaveConfirmationFrame:TweenPosition(UDim2.new(0, 0, 0, 0), Enum.EasingDirection.In, Enum.EasingStyle.Quad, 0.2, true);
  3212. end);
  3213. end;
  3214. return v22;
  3215. end;
  3216. function v4.RemoveChannelTab(p7, p8)
  3217. if not p7:GetChannelTab(p8) then
  3218. error("Channel tab '" .. p8 .. "'does not exist!");
  3219. end;
  3220. local v23 = p8:lower();
  3221. p7.ChannelTabs[v23]:Destroy();
  3222. p7.ChannelTabs[v23] = nil;
  3223. p7.NumTabs = p7.NumTabs - 1;
  3224. p7:OrganizeChannelTabs();
  3225. end;
  3226. function v4.GetChannelTab(p9, p10)
  3227. return p9.ChannelTabs[p10:lower()];
  3228. end;
  3229. function v4.OrganizeChannelTabs(p11)
  3230. local v24 = {};
  3231. table.insert(v24, p11:GetChannelTab(u1.GeneralChannelName));
  3232. table.insert(v24, p11:GetChannelTab("System"));
  3233. for v25, v26 in pairs(p11.ChannelTabs) do
  3234. if v26.ChannelName ~= u1.GeneralChannelName and v26.ChannelName ~= "System" then
  3235. table.insert(v24, v26);
  3236. end;
  3237. end;
  3238. for v27, v28 in pairs(v24) do
  3239. v28.GuiObject.Position = UDim2.new(v27 - 1, 0, 0, 0);
  3240. end;
  3241. p11.GuiObjects.ScrollerSizer.Size = UDim2.new(1 / math.max(1, math.min(u1.ChannelsBarFullTabSize, p11.NumTabs)), 0, 1, 0);
  3242. p11:ScrollChannelsFrame(0);
  3243. end;
  3244. function v4.ResizeChannelTabText(p12, p13)
  3245. for v29, v30 in pairs(p12.ChannelTabs) do
  3246. v30:SetTextSize(p13);
  3247. end;
  3248. end;
  3249. function v4.ScrollChannelsFrame(p14, p15)
  3250. if p14.ScrollChannelsFrameLock then
  3251. return;
  3252. end;
  3253. p14.ScrollChannelsFrameLock = true;
  3254. local l__ChannelsBarFullTabSize__31 = u1.ChannelsBarFullTabSize;
  3255. local v32 = p14.CurPageNum + p15;
  3256. if v32 < 0 then
  3257. v32 = 0;
  3258. elseif v32 > 0 and p14.NumTabs < v32 + l__ChannelsBarFullTabSize__31 then
  3259. v32 = p14.NumTabs - l__ChannelsBarFullTabSize__31;
  3260. end;
  3261. p14.CurPageNum = v32;
  3262. local v33 = UDim2.new(-p14.CurPageNum, 0, 0, 0);
  3263. p14.GuiObjects.PageLeftButton.Visible = p14.CurPageNum > 0;
  3264. p14.GuiObjects.PageRightButton.Visible = p14.CurPageNum + l__ChannelsBarFullTabSize__31 < p14.NumTabs;
  3265. if p15 == 0 then
  3266. p14.ScrollChannelsFrameLock = false;
  3267. return;
  3268. end;
  3269. p14:WaitUntilParentedCorrectly();
  3270. p14.GuiObjects.ScrollerFrame:TweenPosition(v33, Enum.EasingDirection.InOut, Enum.EasingStyle.Quad, 0.15, true, function()
  3271. p14.ScrollChannelsFrameLock = false;
  3272. end);
  3273. end;
  3274. local u5 = require(l__Parent__3:WaitForChild("CurveUtil"));
  3275. function v4.FadeOutBackground(p16, p17)
  3276. for v34, v35 in pairs(p16.ChannelTabs) do
  3277. v35:FadeOutBackground(p17);
  3278. end;
  3279. p16.AnimParams.Background_TargetTransparency = 1;
  3280. p16.AnimParams.Background_NormalizedExptValue = u5:NormalizedDefaultExptValueInSeconds(p17);
  3281. end;
  3282. function v4.FadeInBackground(p18, p19)
  3283. for v36, v37 in pairs(p18.ChannelTabs) do
  3284. v37:FadeInBackground(p19);
  3285. end;
  3286. p18.AnimParams.Background_TargetTransparency = 0.6;
  3287. p18.AnimParams.Background_NormalizedExptValue = u5:NormalizedDefaultExptValueInSeconds(p19);
  3288. end;
  3289. function v4.FadeOutText(p20, p21)
  3290. for v38, v39 in pairs(p20.ChannelTabs) do
  3291. v39:FadeOutText(p21);
  3292. end;
  3293. end;
  3294. function v4.FadeInText(p22, p23)
  3295. for v40, v41 in pairs(p22.ChannelTabs) do
  3296. v41:FadeInText(p23);
  3297. end;
  3298. end;
  3299. function v4.AnimGuiObjects(p24)
  3300. p24.GuiObjects.PageLeftButton.ImageTransparency = p24.AnimParams.Background_CurrentTransparency;
  3301. p24.GuiObjects.PageRightButton.ImageTransparency = p24.AnimParams.Background_CurrentTransparency;
  3302. p24.GuiObjects.PageLeftButtonArrow.ImageTransparency = p24.AnimParams.Background_CurrentTransparency;
  3303. p24.GuiObjects.PageRightButtonArrow.ImageTransparency = p24.AnimParams.Background_CurrentTransparency;
  3304. end;
  3305. function v4.InitializeAnimParams(p25)
  3306. p25.AnimParams.Background_TargetTransparency = 0.6;
  3307. p25.AnimParams.Background_CurrentTransparency = 0.6;
  3308. p25.AnimParams.Background_NormalizedExptValue = u5:NormalizedDefaultExptValueInSeconds(0);
  3309. end;
  3310. function v4.Update(p26, p27)
  3311. for v42, v43 in pairs(p26.ChannelTabs) do
  3312. v43:Update(p27);
  3313. end;
  3314. p26.AnimParams.Background_CurrentTransparency = u5:Expt(p26.AnimParams.Background_CurrentTransparency, p26.AnimParams.Background_TargetTransparency, p26.AnimParams.Background_NormalizedExptValue, p27);
  3315. p26:AnimGuiObjects();
  3316. end;
  3317. function v4.WaitUntilParentedCorrectly(p28)
  3318. while not p28.GuiObject:IsDescendantOf(game:GetService("Players").LocalPlayer) do
  3319. p28.GuiObject.AncestryChanged:wait();
  3320. end;
  3321. end;
  3322. function v1.new()
  3323. local v44 = setmetatable({}, v4);
  3324. v44.GuiObject = nil;
  3325. v44.GuiObjects = {};
  3326. v44.ChannelTabs = {};
  3327. v44.NumTabs = 0;
  3328. v44.CurPageNum = 0;
  3329. v44.ScrollChannelsFrameLock = false;
  3330. v44.AnimParams = {};
  3331. v44:InitializeAnimParams();
  3332. u1.SettingsChanged:connect(function(p29, p30)
  3333. if p29 == "ChatChannelsTabTextSize" then
  3334. v44:ResizeChannelTabText(p30);
  3335. end;
  3336. end);
  3337. return v44;
  3338. end;
  3339. return v1;
  3340. Chatbar:
  3341. -- Script GUID: {225d0ebe-465c-434d-9573-b847046e759e}
  3342. -- Decompiled with the Synapse X Luau decompiler.
  3343.  
  3344. local v1 = {};
  3345. local l__UserInputService__2 = game:GetService("UserInputService");
  3346. local l__RunService__3 = game:GetService("RunService");
  3347. local l__Players__4 = game:GetService("Players");
  3348. local l__TextService__5 = game:GetService("TextService");
  3349. local v6 = l__Players__4.LocalPlayer;
  3350. while not v6 do
  3351. l__Players__4.PlayerAdded:wait();
  3352. v6 = l__Players__4.LocalPlayer;
  3353. end;
  3354. local l__Chat__7 = game:GetService("Chat");
  3355. local l__ClientChatModules__8 = l__Chat__7:WaitForChild("ClientChatModules");
  3356. local l__Parent__9 = script.Parent;
  3357. local v10 = require(l__ClientChatModules__8:WaitForChild("ChatSettings"));
  3358. local v11 = require(l__Parent__9:WaitForChild("CurveUtil"));
  3359. local v12 = require(l__ClientChatModules__8:WaitForChild("CommandModules"):WaitForChild("Whisper"));
  3360. local v13 = require(l__Parent__9:WaitForChild("MessageSender"));
  3361. local u1 = nil;
  3362. pcall(function()
  3363. u1 = require(game:GetService("Chat").ClientChatModules.ChatLocalization);
  3364. end);
  3365. if u1 == nil then
  3366. u1 = {
  3367. Get = function(p1, p2, p3)
  3368. return p3;
  3369. end
  3370. };
  3371. end;
  3372. local v14, v15 = pcall(function()
  3373. return UserSettings():IsUserFeatureEnabled("UserChatNewMessageLengthCheck2");
  3374. end);
  3375. local v16 = {};
  3376. v16.__index = v16;
  3377. function v16.CreateGuiObjects(p4, p5)
  3378. p4.ChatBarParentFrame = p5;
  3379. local v17 = Instance.new("Frame");
  3380. v17.Selectable = false;
  3381. v17.Size = UDim2.new(1, 0, 1, 0);
  3382. v17.BackgroundTransparency = 0.6;
  3383. v17.BorderSizePixel = 0;
  3384. v17.BackgroundColor3 = v10.ChatBarBackGroundColor;
  3385. v17.Parent = p5;
  3386. local v18 = Instance.new("Frame");
  3387. v18.Selectable = false;
  3388. v18.Name = "BoxFrame";
  3389. v18.BackgroundTransparency = 0.6;
  3390. v18.BorderSizePixel = 0;
  3391. v18.BackgroundColor3 = v10.ChatBarBoxColor;
  3392. v18.Size = UDim2.new(1, -14, 1, -14);
  3393. v18.Position = UDim2.new(0, 7, 0, 7);
  3394. v18.Parent = v17;
  3395. local v19 = Instance.new("Frame");
  3396. v19.BackgroundTransparency = 1;
  3397. v19.Size = UDim2.new(1, -10, 1, -10);
  3398. v19.Position = UDim2.new(0, 5, 0, 5);
  3399. v19.Parent = v18;
  3400. local v20 = Instance.new("TextBox");
  3401. v20.Selectable = v10.GamepadNavigationEnabled;
  3402. v20.Name = "ChatBar";
  3403. v20.BackgroundTransparency = 1;
  3404. v20.Size = UDim2.new(1, 0, 1, 0);
  3405. v20.Position = UDim2.new(0, 0, 0, 0);
  3406. v20.TextSize = v10.ChatBarTextSize;
  3407. v20.Font = v10.ChatBarFont;
  3408. v20.TextColor3 = v10.ChatBarTextColor;
  3409. v20.TextTransparency = 0.4;
  3410. v20.TextStrokeTransparency = 1;
  3411. v20.ClearTextOnFocus = false;
  3412. v20.TextXAlignment = Enum.TextXAlignment.Left;
  3413. v20.TextYAlignment = Enum.TextYAlignment.Top;
  3414. v20.TextWrapped = true;
  3415. v20.Text = "";
  3416. v20.Parent = v19;
  3417. local v21 = Instance.new("TextButton");
  3418. v21.Selectable = false;
  3419. v21.Name = "MessageMode";
  3420. v21.BackgroundTransparency = 1;
  3421. v21.Position = UDim2.new(0, 0, 0, 0);
  3422. v21.TextSize = v10.ChatBarTextSize;
  3423. v21.Font = v10.ChatBarFont;
  3424. v21.TextXAlignment = Enum.TextXAlignment.Left;
  3425. v21.TextWrapped = true;
  3426. v21.Text = "";
  3427. v21.Size = UDim2.new(0, 0, 0, 0);
  3428. v21.TextYAlignment = Enum.TextYAlignment.Center;
  3429. v21.TextColor3 = p4:GetDefaultChannelNameColor();
  3430. v21.Visible = true;
  3431. v21.Parent = v19;
  3432. local v22 = Instance.new("TextLabel");
  3433. v22.Selectable = false;
  3434. v22.TextWrapped = true;
  3435. v22.BackgroundTransparency = 1;
  3436. v22.Size = v20.Size;
  3437. v22.Position = v20.Position;
  3438. v22.TextSize = v20.TextSize;
  3439. v22.Font = v20.Font;
  3440. v22.TextColor3 = v20.TextColor3;
  3441. v22.TextTransparency = v20.TextTransparency;
  3442. v22.TextStrokeTransparency = v20.TextStrokeTransparency;
  3443. v22.TextXAlignment = v20.TextXAlignment;
  3444. v22.TextYAlignment = v20.TextYAlignment;
  3445. v22.Text = "...";
  3446. v22.Parent = v19;
  3447. p4.GuiObject = v17;
  3448. p4.TextBox = v20;
  3449. p4.TextLabel = v22;
  3450. p4.GuiObjects.BaseFrame = v17;
  3451. p4.GuiObjects.TextBoxFrame = v18;
  3452. p4.GuiObjects.TextBox = v20;
  3453. p4.GuiObjects.TextLabel = v22;
  3454. p4.GuiObjects.MessageModeTextButton = v21;
  3455. p4:AnimGuiObjects();
  3456. p4:SetUpTextBoxEvents(v20, v22, v21);
  3457. if p4.UserHasChatOff then
  3458. p4:DoLockChatBar();
  3459. end;
  3460. p4.eGuiObjectsChanged:Fire();
  3461. end;
  3462. function v16.DoLockChatBar(p6)
  3463. if p6.TextLabel then
  3464. if v6.UserId > 0 then
  3465. p6.TextLabel.Text = u1:Get("GameChat_ChatMessageValidator_SettingsError", "To chat in game, turn on chat in your Privacy Settings.");
  3466. else
  3467. p6.TextLabel.Text = u1:Get("GameChat_SwallowGuestChat_Message", "Sign up to chat in game.");
  3468. end;
  3469. p6:CalculateSize();
  3470. end;
  3471. if p6.TextBox then
  3472. p6.TextBox.Active = false;
  3473. p6.TextBox.Focused:connect(function()
  3474. p6.TextBox:ReleaseFocus();
  3475. end);
  3476. end;
  3477. end;
  3478. local u2 = v14 or v15;
  3479. function v16.SetUpTextBoxEvents(p7, p8, p9, p10)
  3480. for v23, v24 in pairs(p7.TextBoxConnections) do
  3481. v24:disconnect();
  3482. p7.TextBoxConnections[v23] = nil;
  3483. end;
  3484. p7.TextBoxConnections.UserInputBegan = l__UserInputService__2.InputBegan:connect(function(p11, p12)
  3485. if p11.KeyCode == Enum.KeyCode.Backspace and p7:IsFocused() and p8.Text == "" then
  3486. p7:SetChannelTarget(v10.GeneralChannelName);
  3487. end;
  3488. end);
  3489. p7.TextBoxConnections.TextBoxChanged = p8.Changed:connect(function(p13)
  3490. local v25 = nil;
  3491. if p13 == "AbsoluteSize" then
  3492. p7:CalculateSize();
  3493. return;
  3494. end;
  3495. if p13 ~= "Text" then
  3496. return;
  3497. end;
  3498. p7:CalculateSize();
  3499. if u2 then
  3500. if v10.MaximumMessageLength < utf8.len(utf8.nfcnormalize(p8.Text)) then
  3501. p8.Text = p7.PreviousText;
  3502. else
  3503. p7.PreviousText = p8.Text;
  3504. end;
  3505. elseif v10.MaximumMessageLength < string.len(p8.Text) then
  3506. p8.Text = string.sub(p8.Text, 1, v10.MaximumMessageLength);
  3507. return;
  3508. end;
  3509. if not p7.InCustomState then
  3510. v25 = p7.CommandProcessor:ProcessInProgressChatMessage(p8.Text, p7.ChatWindow, p7);
  3511. if not v25 then
  3512. return;
  3513. end;
  3514. else
  3515. p7.CustomState:TextUpdated();
  3516. return;
  3517. end;
  3518. p7.InCustomState = true;
  3519. p7.CustomState = v25;
  3520. end);
  3521. p7.TextBoxConnections.MessageModeClick = p10.MouseButton1Click:connect(function()
  3522. if p10.Text ~= "" then
  3523. p7:SetChannelTarget(v10.GeneralChannelName);
  3524. end;
  3525. end);
  3526. local function u3(p14)
  3527. if not p14 and p8.Text == "" then
  3528. p9.Visible = true;
  3529. return;
  3530. end;
  3531. p9.Visible = false;
  3532. end;
  3533. p7.TextBoxConnections.TextBoxFocused = p8.Focused:connect(function()
  3534. if not p7.UserHasChatOff then
  3535. p7:CalculateSize();
  3536. u3(true);
  3537. end;
  3538. end);
  3539. p7.TextBoxConnections.TextBoxFocusLost = p8.FocusLost:connect(function(p15, p16)
  3540. p7:CalculateSize();
  3541. if p16 and p16.KeyCode == Enum.KeyCode.Escape then
  3542. p8.Text = "";
  3543. end;
  3544. u3(false);
  3545. end);
  3546. end;
  3547. function v16.GetTextBox(p17)
  3548. return p17.TextBox;
  3549. end;
  3550. function v16.GetMessageModeTextButton(p18)
  3551. return p18.GuiObjects.MessageModeTextButton;
  3552. end;
  3553. function v16.GetMessageModeTextLabel(p19)
  3554. return p19:GetMessageModeTextButton();
  3555. end;
  3556. function v16.IsFocused(p20)
  3557. if p20.UserHasChatOff then
  3558. return false;
  3559. end;
  3560. return p20:GetTextBox():IsFocused();
  3561. end;
  3562. function v16.GetVisible(p21)
  3563. return p21.GuiObject.Visible;
  3564. end;
  3565. function v16.CaptureFocus(p22)
  3566. if not p22.UserHasChatOff then
  3567. p22:GetTextBox():CaptureFocus();
  3568. end;
  3569. end;
  3570. function v16.ReleaseFocus(p23, p24)
  3571. p23:GetTextBox():ReleaseFocus(p24);
  3572. end;
  3573. function v16.ResetText(p25)
  3574. p25:GetTextBox().Text = "";
  3575. end;
  3576. function v16.SetText(p26, p27)
  3577. p26:GetTextBox().Text = p27;
  3578. end;
  3579. function v16.GetEnabled(p28)
  3580. return p28.GuiObject.Visible;
  3581. end;
  3582. function v16.SetEnabled(p29, p30)
  3583. if p29.UserHasChatOff then
  3584. p29.GuiObject.Visible = true;
  3585. return;
  3586. end;
  3587. p29.GuiObject.Visible = p30;
  3588. end;
  3589. function v16.SetTextLabelText(p31, p32)
  3590. if not p31.UserHasChatOff then
  3591. p31.TextLabel.Text = p32;
  3592. end;
  3593. end;
  3594. function v16.SetTextBoxText(p33, p34)
  3595. p33.TextBox.Text = p34;
  3596. end;
  3597. function v16.GetTextBoxText(p35)
  3598. return p35.TextBox.Text;
  3599. end;
  3600. function v16.ResetSize(p36)
  3601. p36.TargetYSize = 0;
  3602. p36:TweenToTargetYSize();
  3603. end;
  3604. local function u4(p37)
  3605. return l__TextService__5:GetTextSize(p37.Text, p37.TextSize, p37.Font, Vector2.new(p37.AbsoluteSize.X, 10000));
  3606. end;
  3607. function v16.CalculateSize(p38)
  3608. if p38.CalculatingSizeLock then
  3609. return;
  3610. end;
  3611. p38.CalculatingSizeLock = true;
  3612. if p38:IsFocused() or p38.TextBox.Text ~= "" then
  3613. local v26 = p38.TextBox.TextSize;
  3614. local v27 = u4(p38.TextBox).Y;
  3615. else
  3616. v26 = p38.TextLabel.TextSize;
  3617. v27 = u4(p38.TextLabel).Y;
  3618. end;
  3619. local v28 = v27 - v26;
  3620. if p38.TargetYSize ~= v28 then
  3621. p38.TargetYSize = v28;
  3622. p38:TweenToTargetYSize();
  3623. end;
  3624. p38.CalculatingSizeLock = false;
  3625. end;
  3626. function v16.TweenToTargetYSize(p39)
  3627. local v29 = UDim2.new(1, 0, 1, p39.TargetYSize);
  3628. p39.GuiObject.Size = v29;
  3629. p39.GuiObject.Size = p39.GuiObject.Size;
  3630. local u5 = math.min(1, math.abs(p39.GuiObject.AbsoluteSize.Y - p39.GuiObject.AbsoluteSize.Y) * (1 / p39.TweenPixelsPerSecond));
  3631. if not pcall(function()
  3632. p39.GuiObject:TweenSize(v29, Enum.EasingDirection.Out, Enum.EasingStyle.Quad, u5, true);
  3633. end) then
  3634. p39.GuiObject.Size = v29;
  3635. end;
  3636. end;
  3637. function v16.SetTextSize(p40, p41)
  3638. if not p40:IsInCustomState() then
  3639. if p40.TextBox then
  3640. p40.TextBox.TextSize = p41;
  3641. end;
  3642. if p40.TextLabel then
  3643. p40.TextLabel.TextSize = p41;
  3644. end;
  3645. end;
  3646. end;
  3647. function v16.GetDefaultChannelNameColor(p42)
  3648. if not v10.DefaultChannelNameColor then
  3649. return Color3.fromRGB(35, 76, 142);
  3650. end;
  3651. return v10.DefaultChannelNameColor;
  3652. end;
  3653. function v16.SetChannelTarget(p43, p44)
  3654. local l__MessageModeTextButton__30 = p43.GuiObjects.MessageModeTextButton;
  3655. local l__TextBox__31 = p43.TextBox;
  3656. local l__TextLabel__32 = p43.TextLabel;
  3657. p43.TargetChannel = p44;
  3658. if not p43:IsInCustomState() then
  3659. if p44 == v10.GeneralChannelName then
  3660. l__MessageModeTextButton__30.Text = "";
  3661. l__MessageModeTextButton__30.Size = UDim2.new(0, 0, 0, 0);
  3662. l__TextBox__31.Size = UDim2.new(1, 0, 1, 0);
  3663. l__TextBox__31.Position = UDim2.new(0, 0, 0, 0);
  3664. l__TextLabel__32.Size = UDim2.new(1, 0, 1, 0);
  3665. l__TextLabel__32.Position = UDim2.new(0, 0, 0, 0);
  3666. return;
  3667. end;
  3668. else
  3669. return;
  3670. end;
  3671. l__MessageModeTextButton__30.Size = UDim2.new(0, 1000, 1, 0);
  3672. local v33 = p44;
  3673. if u1.tryLocalize then
  3674. v33 = u1:tryLocalize(p44);
  3675. end;
  3676. l__MessageModeTextButton__30.Text = string.format("[%s] ", v33);
  3677. local v34 = p43:GetChannelNameColor(p44);
  3678. if v34 then
  3679. l__MessageModeTextButton__30.TextColor3 = v34;
  3680. else
  3681. l__MessageModeTextButton__30.TextColor3 = p43:GetDefaultChannelNameColor();
  3682. end;
  3683. local l__X__35 = l__MessageModeTextButton__30.TextBounds.X;
  3684. l__MessageModeTextButton__30.Size = UDim2.new(0, l__X__35, 1, 0);
  3685. l__TextBox__31.Size = UDim2.new(1, -l__X__35, 1, 0);
  3686. l__TextBox__31.Position = UDim2.new(0, l__X__35, 0, 0);
  3687. l__TextLabel__32.Size = UDim2.new(1, -l__X__35, 1, 0);
  3688. l__TextLabel__32.Position = UDim2.new(0, l__X__35, 0, 0);
  3689. end;
  3690. function v16.IsInCustomState(p45)
  3691. return p45.InCustomState;
  3692. end;
  3693. function v16.ResetCustomState(p46)
  3694. if p46.InCustomState then
  3695. p46.CustomState:Destroy();
  3696. p46.CustomState = nil;
  3697. p46.InCustomState = false;
  3698. p46.ChatBarParentFrame:ClearAllChildren();
  3699. p46:CreateGuiObjects(p46.ChatBarParentFrame);
  3700. p46:SetTextLabelText(u1:Get("GameChat_ChatMain_ChatBarText", "To chat click here or press \"/\" key"));
  3701. end;
  3702. end;
  3703. function v16.EnterWhisperState(p47, p48)
  3704. p47:ResetCustomState();
  3705. if v12.CustomStateCreator then
  3706. p47.CustomState = v12.CustomStateCreator(p48, p47.ChatWindow, p47, v10);
  3707. p47.InCustomState = true;
  3708. else
  3709. if v10.PlayerDisplayNamesEnabled then
  3710. local v36 = p48.DisplayName;
  3711. else
  3712. v36 = p48.Name;
  3713. end;
  3714. p47:SetText("/w " .. v36);
  3715. end;
  3716. p47:CaptureFocus();
  3717. end;
  3718. function v16.GetCustomMessage(p49)
  3719. if not p49.InCustomState then
  3720. return nil;
  3721. end;
  3722. return p49.CustomState:GetMessage();
  3723. end;
  3724. function v16.CustomStateProcessCompletedMessage(p50, p51)
  3725. if not p50.InCustomState then
  3726. return false;
  3727. end;
  3728. return p50.CustomState:ProcessCompletedMessage();
  3729. end;
  3730. function v16.FadeOutBackground(p52, p53)
  3731. p52.AnimParams.Background_TargetTransparency = 1;
  3732. p52.AnimParams.Background_NormalizedExptValue = v11:NormalizedDefaultExptValueInSeconds(p53);
  3733. p52:FadeOutText(p53);
  3734. end;
  3735. function v16.FadeInBackground(p54, p55)
  3736. p54.AnimParams.Background_TargetTransparency = 0.6;
  3737. p54.AnimParams.Background_NormalizedExptValue = v11:NormalizedDefaultExptValueInSeconds(p55);
  3738. p54:FadeInText(p55);
  3739. end;
  3740. function v16.FadeOutText(p56, p57)
  3741. p56.AnimParams.Text_TargetTransparency = 1;
  3742. p56.AnimParams.Text_NormalizedExptValue = v11:NormalizedDefaultExptValueInSeconds(p57);
  3743. end;
  3744. function v16.FadeInText(p58, p59)
  3745. p58.AnimParams.Text_TargetTransparency = 0.4;
  3746. p58.AnimParams.Text_NormalizedExptValue = v11:NormalizedDefaultExptValueInSeconds(p59);
  3747. end;
  3748. function v16.AnimGuiObjects(p60)
  3749. p60.GuiObject.BackgroundTransparency = p60.AnimParams.Background_CurrentTransparency;
  3750. p60.GuiObjects.TextBoxFrame.BackgroundTransparency = p60.AnimParams.Background_CurrentTransparency;
  3751. p60.GuiObjects.TextLabel.TextTransparency = p60.AnimParams.Text_CurrentTransparency;
  3752. p60.GuiObjects.TextBox.TextTransparency = p60.AnimParams.Text_CurrentTransparency;
  3753. p60.GuiObjects.MessageModeTextButton.TextTransparency = p60.AnimParams.Text_CurrentTransparency;
  3754. end;
  3755. function v16.InitializeAnimParams(p61)
  3756. p61.AnimParams.Text_TargetTransparency = 0.4;
  3757. p61.AnimParams.Text_CurrentTransparency = 0.4;
  3758. p61.AnimParams.Text_NormalizedExptValue = 1;
  3759. p61.AnimParams.Background_TargetTransparency = 0.6;
  3760. p61.AnimParams.Background_CurrentTransparency = 0.6;
  3761. p61.AnimParams.Background_NormalizedExptValue = 1;
  3762. end;
  3763. function v16.Update(p62, p63)
  3764. p62.AnimParams.Text_CurrentTransparency = v11:Expt(p62.AnimParams.Text_CurrentTransparency, p62.AnimParams.Text_TargetTransparency, p62.AnimParams.Text_NormalizedExptValue, p63);
  3765. p62.AnimParams.Background_CurrentTransparency = v11:Expt(p62.AnimParams.Background_CurrentTransparency, p62.AnimParams.Background_TargetTransparency, p62.AnimParams.Background_NormalizedExptValue, p63);
  3766. p62:AnimGuiObjects();
  3767. end;
  3768. function v16.SetChannelNameColor(p64, p65, p66)
  3769. p64.ChannelNameColors[p65] = p66;
  3770. if p64.GuiObjects.MessageModeTextButton.Text == p65 then
  3771. p64.GuiObjects.MessageModeTextButton.TextColor3 = p66;
  3772. end;
  3773. end;
  3774. function v16.GetChannelNameColor(p67, p68)
  3775. return p67.ChannelNameColors[p68];
  3776. end;
  3777. function v1.new(p69, p70)
  3778. local v37 = setmetatable({}, v16);
  3779. v37.GuiObject = nil;
  3780. v37.ChatBarParentFrame = nil;
  3781. v37.TextBox = nil;
  3782. v37.TextLabel = nil;
  3783. v37.GuiObjects = {};
  3784. v37.eGuiObjectsChanged = Instance.new("BindableEvent");
  3785. v37.GuiObjectsChanged = v37.eGuiObjectsChanged.Event;
  3786. v37.TextBoxConnections = {};
  3787. v37.PreviousText = "";
  3788. v37.InCustomState = false;
  3789. v37.CustomState = nil;
  3790. v37.TargetChannel = nil;
  3791. v37.CommandProcessor = p69;
  3792. v37.ChatWindow = p70;
  3793. v37.TweenPixelsPerSecond = 500;
  3794. v37.TargetYSize = 0;
  3795. v37.AnimParams = {};
  3796. v37.CalculatingSizeLock = false;
  3797. v37.ChannelNameColors = {};
  3798. v37.UserHasChatOff = false;
  3799. v37:InitializeAnimParams();
  3800. v10.SettingsChanged:connect(function(p71, p72)
  3801. if p71 == "ChatBarTextSize" then
  3802. v37:SetTextSize(p72);
  3803. end;
  3804. end);
  3805. coroutine.wrap(function()
  3806. local v38, v39 = pcall(function()
  3807. return l__Chat__7:CanUserChatAsync(v6.UserId);
  3808. end);
  3809. if (v38 and (l__RunService__3:IsStudio() and v39)) == false then
  3810. v37.UserHasChatOff = true;
  3811. v37:DoLockChatBar();
  3812. end;
  3813. end)();
  3814. return v37;
  3815. end;
  3816. return v1;
  3817. ChatChannel:
  3818. -- Script GUID: {74e636fd-ff73-45d2-80f8-616ec38612ad}
  3819. -- Decompiled with the Synapse X Luau decompiler.
  3820.  
  3821. local v1 = {};
  3822. local l__Parent__2 = script.Parent;
  3823. local v3 = {};
  3824. v3.__index = v3;
  3825. function v3.Destroy(p1)
  3826. p1.Destroyed = true;
  3827. end;
  3828. function v3.SetActive(p2, p3)
  3829. if p3 == p2.Active then
  3830. return;
  3831. end;
  3832. if p3 == false then
  3833. p2.MessageLogDisplay:Clear();
  3834. else
  3835. p2.MessageLogDisplay:SetCurrentChannelName(p2.Name);
  3836. for v4 = 1, #p2.MessageLog do
  3837. p2.MessageLogDisplay:AddMessage(p2.MessageLog[v4]);
  3838. end;
  3839. end;
  3840. p2.Active = p3;
  3841. end;
  3842. function v3.UpdateMessageFiltered(p4, p5)
  3843. local v5 = 1;
  3844. local l__MessageLog__6 = p4.MessageLog;
  3845. local v7 = nil;
  3846. while v5 <= #l__MessageLog__6 do
  3847. local v8 = l__MessageLog__6[v5];
  3848. if v8.ID == p5.ID then
  3849. v7 = v8;
  3850. break;
  3851. end;
  3852. v5 = v5 + 1;
  3853. end;
  3854. if v7 then
  3855. v7.Message = p5.Message;
  3856. v7.IsFiltered = true;
  3857. if not p4.Active then
  3858. return;
  3859. end;
  3860. else
  3861. p4:AddMessageToChannelByTimeStamp(p5);
  3862. return;
  3863. end;
  3864. p4.MessageLogDisplay:UpdateMessageFiltered(v7);
  3865. end;
  3866. local u1 = require(game:GetService("Chat"):WaitForChild("ClientChatModules"):WaitForChild("ChatSettings"));
  3867. function v3.AddMessageToChannel(p6, p7)
  3868. table.insert(p6.MessageLog, p7);
  3869. if p6.Active then
  3870. p6.MessageLogDisplay:AddMessage(p7);
  3871. end;
  3872. if u1.MessageHistoryLengthPerChannel < #p6.MessageLog then
  3873. p6:RemoveLastMessageFromChannel();
  3874. end;
  3875. end;
  3876. function v3.InternalAddMessageAtTimeStamp(p8, p9)
  3877. for v9 = 1, #p8.MessageLog do
  3878. if p9.Time < p8.MessageLog[v9].Time then
  3879. table.insert(p8.MessageLog, v9, p9);
  3880. return;
  3881. end;
  3882. end;
  3883. table.insert(p8.MessageLog, p9);
  3884. end;
  3885. function v3.AddMessagesToChannelByTimeStamp(p10, p11, p12)
  3886. for v10 = p12, #p11 do
  3887. p10:InternalAddMessageAtTimeStamp(p11[v10]);
  3888. end;
  3889. while u1.MessageHistoryLengthPerChannel < #p10.MessageLog do
  3890. table.remove(p10.MessageLog, 1);
  3891. end;
  3892. if p10.Active then
  3893. p10.MessageLogDisplay:Clear();
  3894. for v11 = 1, #p10.MessageLog do
  3895. p10.MessageLogDisplay:AddMessage(p10.MessageLog[v11]);
  3896. end;
  3897. end;
  3898. end;
  3899. function v3.AddMessageToChannelByTimeStamp(p13, p14)
  3900. if not (#p13.MessageLog >= 1) then
  3901. p13:AddMessageToChannel(p14);
  3902. return;
  3903. end;
  3904. if p14.Time < p13.MessageLog[1].Time then
  3905. return;
  3906. end;
  3907. if p13.MessageLog[#p13.MessageLog].Time <= p14.Time then
  3908. p13:AddMessageToChannel(p14);
  3909. return;
  3910. end;
  3911. for v12 = 1, #p13.MessageLog do
  3912. if p14.Time < p13.MessageLog[v12].Time then
  3913. table.insert(p13.MessageLog, v12, p14);
  3914. if u1.MessageHistoryLengthPerChannel < #p13.MessageLog then
  3915. p13:RemoveLastMessageFromChannel();
  3916. end;
  3917. if p13.Active then
  3918. p13.MessageLogDisplay:AddMessageAtIndex(p14, v12);
  3919. end;
  3920. return;
  3921. end;
  3922. end;
  3923. end;
  3924. function v3.RemoveLastMessageFromChannel(p15)
  3925. table.remove(p15.MessageLog, 1);
  3926. if p15.Active then
  3927. p15.MessageLogDisplay:RemoveLastMessage();
  3928. end;
  3929. end;
  3930. function v3.ClearMessageLog(p16)
  3931. p16.MessageLog = {};
  3932. if p16.Active then
  3933. p16.MessageLogDisplay:Clear();
  3934. end;
  3935. end;
  3936. function v3.RegisterChannelTab(p17, p18)
  3937. p17.ChannelTab = p18;
  3938. end;
  3939. function v1.new(p19, p20)
  3940. local v13 = setmetatable({}, v3);
  3941. v13.Destroyed = false;
  3942. v13.Active = false;
  3943. v13.MessageLog = {};
  3944. v13.MessageLogDisplay = p20;
  3945. v13.ChannelTab = nil;
  3946. v13.Name = p19;
  3947. return v13;
  3948. end;
  3949. return v1;
  3950. MessageLogDisplay:
  3951. -- Script GUID: {67841505-e9b3-4fe5-9f0d-509728a9ca95}
  3952. -- Decompiled with the Synapse X Luau decompiler.
  3953.  
  3954. local v1, v2 = pcall(function()
  3955. return UserSettings():IsUserFeatureEnabled("UserChatHistorySinksInput");
  3956. end);
  3957. local v3 = {
  3958. ScrollBarThickness = 4
  3959. };
  3960. local l__Parent__4 = script.Parent;
  3961. local v5 = {};
  3962. v5.__index = v5;
  3963. local u1 = require(game:GetService("Chat"):WaitForChild("ClientChatModules"):WaitForChild("ChatSettings"));
  3964. local u2 = v1 or v2;
  3965. function v5.Destroy(p1)
  3966. p1.GuiObject:Destroy();
  3967. p1.Destroyed = true;
  3968. end;
  3969. function v5.SetActive(p2, p3)
  3970. p2.GuiObject.Visible = p3;
  3971. end;
  3972. function v5.UpdateMessageFiltered(p4, p5)
  3973. local v6 = nil;
  3974. local v7 = 1;
  3975. local l__MessageObjectLog__8 = p4.MessageObjectLog;
  3976. while v7 <= #l__MessageObjectLog__8 do
  3977. local v9 = l__MessageObjectLog__8[v7];
  3978. if v9.ID == p5.ID then
  3979. v6 = v9;
  3980. break;
  3981. end;
  3982. v7 = v7 + 1;
  3983. end;
  3984. if v6 then
  3985. v6.UpdateTextFunction(p5);
  3986. p4:PositionMessageLabelInWindow(v6, v7);
  3987. end;
  3988. end;
  3989. local u3 = require(l__Parent__4:WaitForChild("MessageLabelCreator")).new();
  3990. function v5.AddMessage(p6, p7)
  3991. p6:WaitUntilParentedCorrectly();
  3992. local v10 = u3:CreateMessageLabel(p7, p6.CurrentChannelName);
  3993. if v10 == nil then
  3994. return;
  3995. end;
  3996. table.insert(p6.MessageObjectLog, v10);
  3997. p6:PositionMessageLabelInWindow(v10, #p6.MessageObjectLog);
  3998. end;
  3999. function v5.AddMessageAtIndex(p8, p9, p10)
  4000. local v11 = u3:CreateMessageLabel(p9, p8.CurrentChannelName);
  4001. if v11 == nil then
  4002. return;
  4003. end;
  4004. table.insert(p8.MessageObjectLog, p10, v11);
  4005. p8:PositionMessageLabelInWindow(v11, p10);
  4006. end;
  4007. function v5.RemoveLastMessage(p11)
  4008. p11:WaitUntilParentedCorrectly();
  4009. p11.MessageObjectLog[1]:Destroy();
  4010. table.remove(p11.MessageObjectLog, 1);
  4011. end;
  4012. function v5.IsScrolledDown(p12)
  4013. local l__Offset__12 = p12.Scroller.CanvasSize.Y.Offset;
  4014. local l__Y__13 = p12.Scroller.AbsoluteWindowSize.Y;
  4015. local v14 = true;
  4016. if not (l__Offset__12 < l__Y__13) then
  4017. v14 = l__Offset__12 - p12.Scroller.CanvasPosition.Y <= l__Y__13 + 5;
  4018. end;
  4019. return v14;
  4020. end;
  4021. function v5.UpdateMessageTextHeight(p13, p14)
  4022. local l__BaseFrame__15 = p14.BaseFrame;
  4023. for v16 = 1, 10 do
  4024. if p14.BaseMessage.TextFits then
  4025. break;
  4026. end;
  4027. l__BaseFrame__15.Size = UDim2.new(1, 0, 0, p14.GetHeightFunction(p13.Scroller.AbsoluteSize.X - v16));
  4028. end;
  4029. end;
  4030. function v5.PositionMessageLabelInWindow(p15, p16, p17)
  4031. p15:WaitUntilParentedCorrectly();
  4032. local l__BaseFrame__17 = p16.BaseFrame;
  4033. local v18 = 1;
  4034. if p15.MessageObjectLog[p17 - 1] then
  4035. if p17 == #p15.MessageObjectLog then
  4036. v18 = p15.MessageObjectLog[p17 - 1].BaseFrame.LayoutOrder + 1;
  4037. else
  4038. v18 = p15.MessageObjectLog[p17 - 1].BaseFrame.LayoutOrder;
  4039. end;
  4040. end;
  4041. l__BaseFrame__17.LayoutOrder = v18;
  4042. l__BaseFrame__17.Size = UDim2.new(1, 0, 0, p16.GetHeightFunction(p15.Scroller.AbsoluteSize.X));
  4043. l__BaseFrame__17.Parent = p15.Scroller;
  4044. if p16.BaseMessage then
  4045. p15:UpdateMessageTextHeight(p16);
  4046. end;
  4047. if p15:IsScrolledDown() then
  4048. p15.Scroller.CanvasPosition = Vector2.new(0, math.max(0, p15.Scroller.CanvasSize.Y.Offset - p15.Scroller.AbsoluteSize.Y));
  4049. end;
  4050. end;
  4051. function v5.ReorderAllMessages(p18)
  4052. p18:WaitUntilParentedCorrectly();
  4053. if p18.GuiObject.AbsoluteSize.Y < 1 then
  4054. return;
  4055. end;
  4056. for v19, v20 in pairs(p18.MessageObjectLog) do
  4057. p18:UpdateMessageTextHeight(v20);
  4058. end;
  4059. if not p18:IsScrolledDown() then
  4060. p18.Scroller.CanvasPosition = p18.Scroller.CanvasPosition;
  4061. return;
  4062. end;
  4063. p18.Scroller.CanvasPosition = Vector2.new(0, math.max(0, p18.Scroller.CanvasSize.Y.Offset - p18.Scroller.AbsoluteSize.Y));
  4064. end;
  4065. function v5.Clear(p19)
  4066. for v21, v22 in pairs(p19.MessageObjectLog) do
  4067. v22:Destroy();
  4068. end;
  4069. p19.MessageObjectLog = {};
  4070. end;
  4071. function v5.SetCurrentChannelName(p20, p21)
  4072. p20.CurrentChannelName = p21;
  4073. end;
  4074. function v5.FadeOutBackground(p22, p23)
  4075.  
  4076. end;
  4077. function v5.FadeInBackground(p24, p25)
  4078.  
  4079. end;
  4080. local u4 = require(l__Parent__4:WaitForChild("CurveUtil"));
  4081. function v5.FadeOutText(p26, p27)
  4082. for v23 = 1, #p26.MessageObjectLog do
  4083. if p26.MessageObjectLog[v23].FadeOutFunction then
  4084. p26.MessageObjectLog[v23].FadeOutFunction(p27, u4);
  4085. end;
  4086. end;
  4087. end;
  4088. function v5.FadeInText(p28, p29)
  4089. for v24 = 1, #p28.MessageObjectLog do
  4090. if p28.MessageObjectLog[v24].FadeInFunction then
  4091. p28.MessageObjectLog[v24].FadeInFunction(p29, u4);
  4092. end;
  4093. end;
  4094. end;
  4095. function v5.Update(p30, p31)
  4096. for v25 = 1, #p30.MessageObjectLog do
  4097. if p30.MessageObjectLog[v25].UpdateAnimFunction then
  4098. p30.MessageObjectLog[v25].UpdateAnimFunction(p31, u4);
  4099. end;
  4100. end;
  4101. end;
  4102. function v5.WaitUntilParentedCorrectly(p32)
  4103. while not p32.GuiObject:IsDescendantOf(game:GetService("Players").LocalPlayer) do
  4104. p32.GuiObject.AncestryChanged:wait();
  4105. end;
  4106. end;
  4107. local function u5()
  4108. local v26 = Instance.new("Frame");
  4109. v26.Selectable = false;
  4110. v26.Size = UDim2.new(1, 0, 1, 0);
  4111. v26.BackgroundTransparency = 1;
  4112. local v27 = Instance.new("ScrollingFrame");
  4113. v27.Selectable = u1.GamepadNavigationEnabled;
  4114. v27.Name = "Scroller";
  4115. v27.BackgroundTransparency = 1;
  4116. v27.BorderSizePixel = 0;
  4117. v27.Position = UDim2.new(0, 0, 0, 3);
  4118. v27.Size = UDim2.new(1, -4, 1, -6);
  4119. v27.CanvasSize = UDim2.new(0, 0, 0, 0);
  4120. v27.ScrollBarThickness = v3.ScrollBarThickness;
  4121. v27.Active = u2;
  4122. v27.Parent = v26;
  4123. local v28 = Instance.new("UIListLayout");
  4124. v28.SortOrder = Enum.SortOrder.LayoutOrder;
  4125. v28.Parent = v27;
  4126. return v26, v27, v28;
  4127. end;
  4128. function v3.new()
  4129. local v29 = setmetatable({}, v5);
  4130. v29.Destroyed = false;
  4131. local v30, v31, v32 = u5();
  4132. v29.GuiObject = v30;
  4133. v29.Scroller = v31;
  4134. v29.Layout = v32;
  4135. v29.MessageObjectLog = {};
  4136. v29.Name = "MessageLogDisplay";
  4137. v29.GuiObject.Name = "Frame_" .. v29.Name;
  4138. v29.CurrentChannelName = "";
  4139. v29.GuiObject:GetPropertyChangedSignal("AbsoluteSize"):Connect(function()
  4140. spawn(function()
  4141. v29:ReorderAllMessages();
  4142. end);
  4143. end);
  4144. local u6 = true;
  4145. v29.Layout:GetPropertyChangedSignal("AbsoluteContentSize"):Connect(function()
  4146. local l__AbsoluteContentSize__33 = v29.Layout.AbsoluteContentSize;
  4147. v29.Scroller.CanvasSize = UDim2.new(0, 0, 0, l__AbsoluteContentSize__33.Y);
  4148. if u6 then
  4149. v29.Scroller.CanvasPosition = Vector2.new(0, l__AbsoluteContentSize__33.Y - v29.Scroller.AbsoluteWindowSize.Y);
  4150. end;
  4151. end);
  4152. v29.Scroller:GetPropertyChangedSignal("CanvasPosition"):Connect(function()
  4153. u6 = v29:IsScrolledDown();
  4154. end);
  4155. return v29;
  4156. end;
  4157. return v3;
  4158. ChatWindow:
  4159. -- Script GUID: {e1e13763-0ee9-48ff-8afc-bd1232cef46c}
  4160. -- Decompiled with the Synapse X Luau decompiler.
  4161.  
  4162. local v1 = false;
  4163. local v2, v3 = pcall(function()
  4164. return UserSettings():IsUserFeatureEnabled("UserFixMouseCapture");
  4165. end);
  4166. if v2 then
  4167. v1 = v3;
  4168. end;
  4169. local v4 = {};
  4170. local l__Players__5 = game:GetService("Players");
  4171. local l__Chat__6 = game:GetService("Chat");
  4172. local l__Chat__7 = game:GetService("Chat");
  4173. local l__Parent__8 = script.Parent;
  4174. local v9 = {};
  4175. v9.__index = v9;
  4176. local u1 = require(l__Chat__7:WaitForChild("ClientChatModules"):WaitForChild("ChatSettings"));
  4177. function getClassicChatEnabled()
  4178. if u1.ClassicChatEnabled ~= nil then
  4179. return u1.ClassicChatEnabled;
  4180. end;
  4181. return l__Players__5.ClassicChat;
  4182. end;
  4183. function getBubbleChatEnabled()
  4184. if u1.BubbleChatEnabled ~= nil then
  4185. return u1.BubbleChatEnabled;
  4186. end;
  4187. return l__Players__5.BubbleChat;
  4188. end;
  4189. function bubbleChatOnly()
  4190. return not getClassicChatEnabled() and getBubbleChatEnabled();
  4191. end;
  4192. function mergeProps(p1, p2)
  4193. if p1 then
  4194. if not p2 then
  4195. return;
  4196. end;
  4197. else
  4198. return;
  4199. end;
  4200. local v10, v11, v12 = pairs(p1);
  4201. while true do
  4202. local v13, v14 = v10(v11, v12);
  4203. if v13 then
  4204.  
  4205. else
  4206. break;
  4207. end;
  4208. v12 = v13;
  4209. if p2[v13] ~= nil then
  4210. p2[v13] = v14;
  4211. end;
  4212. end;
  4213. end;
  4214. local l__PlayerGui__2 = l__Players__5.LocalPlayer:WaitForChild("PlayerGui");
  4215. function v9.CreateGuiObjects(p3, p4)
  4216. local u3 = nil;
  4217. pcall(function()
  4218. u3 = l__Chat__7:InvokeChatCallback(Enum.ChatCallbackType.OnCreatingChatWindow, nil);
  4219. end);
  4220. mergeProps(u3, u1);
  4221. local v15 = Instance.new("Frame");
  4222. v15.BackgroundTransparency = 1;
  4223. v15.Active = u1.WindowDraggable;
  4224. v15.Parent = p4;
  4225. v15.AutoLocalize = false;
  4226. local v16 = Instance.new("Frame");
  4227. v16.Selectable = false;
  4228. v16.Name = "ChatBarParentFrame";
  4229. v16.BackgroundTransparency = 1;
  4230. v16.Parent = v15;
  4231. local v17 = Instance.new("Frame");
  4232. v17.Selectable = false;
  4233. v17.Name = "ChannelsBarParentFrame";
  4234. v17.BackgroundTransparency = 1;
  4235. v17.Position = UDim2.new(0, 0, 0, 0);
  4236. v17.Parent = v15;
  4237. local v18 = Instance.new("Frame");
  4238. v18.Selectable = false;
  4239. v18.Name = "ChatChannelParentFrame";
  4240. v18.BackgroundTransparency = 1;
  4241. v18.BackgroundColor3 = u1.BackGroundColor;
  4242. v18.BackgroundTransparency = 0.6;
  4243. v18.BorderSizePixel = 0;
  4244. v18.Parent = v15;
  4245. local v19 = Instance.new("ImageButton");
  4246. v19.Selectable = false;
  4247. v19.Image = "";
  4248. v19.BackgroundTransparency = 0.6;
  4249. v19.BorderSizePixel = 0;
  4250. v19.Visible = false;
  4251. v19.BackgroundColor3 = u1.BackGroundColor;
  4252. v19.Active = true;
  4253. if bubbleChatOnly() then
  4254. v19.Position = UDim2.new(1, -v19.AbsoluteSize.X, 0, 0);
  4255. else
  4256. v19.Position = UDim2.new(1, -v19.AbsoluteSize.X, 1, -v19.AbsoluteSize.Y);
  4257. end;
  4258. v19.Parent = v15;
  4259. local v20 = Instance.new("ImageLabel");
  4260. v20.Selectable = false;
  4261. v20.Size = UDim2.new(0.8, 0, 0.8, 0);
  4262. v20.Position = UDim2.new(0.2, 0, 0.2, 0);
  4263. v20.BackgroundTransparency = 1;
  4264. v20.Image = "rbxassetid://261880743";
  4265. v20.Parent = v19;
  4266. local function v21()
  4267. local v22 = v15;
  4268. while v22 and not v22:IsA("ScreenGui") do
  4269. v22 = v22.Parent;
  4270. end;
  4271. return v22;
  4272. end;
  4273. local v23 = 3;
  4274. local v24 = v21();
  4275. if v24.AbsoluteSize.X <= 640 then
  4276. v23 = 1;
  4277. elseif v24.AbsoluteSize.X <= 1024 then
  4278. v23 = 2;
  4279. end;
  4280. local u4 = false;
  4281. local function u5()
  4282. if u4 then
  4283. return;
  4284. end;
  4285. u4 = true;
  4286. if not v15:IsDescendantOf(l__PlayerGui__2) then
  4287. return;
  4288. end;
  4289. local v25 = v21();
  4290. local l__MinimumWindowSize__26 = u1.MinimumWindowSize;
  4291. local l__MaximumWindowSize__27 = u1.MaximumWindowSize;
  4292. local v28 = l__MinimumWindowSize__26.X.Scale * v25.AbsoluteSize.X + l__MinimumWindowSize__26.X.Offset;
  4293. local v29 = math.max(l__MinimumWindowSize__26.Y.Scale * v25.AbsoluteSize.Y + l__MinimumWindowSize__26.Y.Offset, v17.AbsoluteSize.Y + v16.AbsoluteSize.Y);
  4294. local v30 = l__MaximumWindowSize__27.X.Scale * v25.AbsoluteSize.X + l__MaximumWindowSize__27.X.Offset;
  4295. local v31 = l__MaximumWindowSize__27.Y.Scale * v25.AbsoluteSize.Y + l__MaximumWindowSize__27.Y.Offset;
  4296. local l__X__32 = v15.AbsoluteSize.X;
  4297. local l__Y__33 = v15.AbsoluteSize.Y;
  4298. if l__X__32 < v28 then
  4299. v15.Size = v15.Size + UDim2.new(0, v28 - l__X__32, 0, 0);
  4300. elseif v30 < l__X__32 then
  4301. v15.Size = v15.Size + UDim2.new(0, v30 - l__X__32, 0, 0);
  4302. end;
  4303. if l__Y__33 < v29 then
  4304. v15.Size = v15.Size + UDim2.new(0, 0, 0, v29 - l__Y__33);
  4305. elseif v31 < l__Y__33 then
  4306. v15.Size = v15.Size + UDim2.new(0, 0, 0, v31 - l__Y__33);
  4307. end;
  4308. local v34 = v15.AbsoluteSize.X / v25.AbsoluteSize.X;
  4309. local v35 = v15.AbsoluteSize.Y / v25.AbsoluteSize.Y;
  4310. if v1 then
  4311. v34 = math.min(v34, 0.45);
  4312. v35 = math.min(v34, 0.45);
  4313. end;
  4314. v15.Size = UDim2.new(v34, 0, v35, 0);
  4315. u4 = false;
  4316. end;
  4317. v15.Changed:connect(function(p5)
  4318. if p5 == "AbsoluteSize" then
  4319. u5();
  4320. end;
  4321. end);
  4322. v19.DragBegin:connect(function(p6)
  4323. v15.Draggable = false;
  4324. end);
  4325. v19.DragStopped:connect(function(p7, p8)
  4326. v15.Draggable = u1.WindowDraggable;
  4327. end);
  4328. local u6 = false;
  4329. local function u7(p9)
  4330. if u1.WindowDraggable == false and u1.WindowResizable == false then
  4331. return;
  4332. end;
  4333. local v36 = p9 - v15.AbsolutePosition + v19.AbsoluteSize;
  4334. v15.Size = UDim2.new(0, v36.X, 0, v36.Y);
  4335. if bubbleChatOnly() then
  4336. v19.Position = UDim2.new(1, -v19.AbsoluteSize.X, 0, 0);
  4337. return;
  4338. end;
  4339. v19.Position = UDim2.new(1, -v19.AbsoluteSize.X, 1, -v19.AbsoluteSize.Y);
  4340. end;
  4341. v19.Changed:connect(function(p10)
  4342. if p10 == "AbsolutePosition" and not v15.Draggable then
  4343. if u6 then
  4344. return;
  4345. end;
  4346. u6 = true;
  4347. u7(v19.AbsolutePosition);
  4348. u6 = false;
  4349. end;
  4350. end);
  4351. local function v37(p11)
  4352. if v23 == 1 then
  4353. p11 = p11 or u1.ChatBarTextSizePhone;
  4354. else
  4355. p11 = p11 or u1.ChatBarTextSize;
  4356. end;
  4357. return p11 + 14 + 10;
  4358. end;
  4359. if bubbleChatOnly() then
  4360. v16.Position = UDim2.new(0, 0, 0, 0);
  4361. v17.Visible = false;
  4362. v17.Active = false;
  4363. v18.Visible = false;
  4364. v18.Active = false;
  4365. local v38 = v21();
  4366. if v23 == 1 then
  4367. local v39 = u1.DefaultWindowSizePhone.X.Scale;
  4368. local v40 = u1.DefaultWindowSizePhone.X.Offset;
  4369. elseif v23 == 2 then
  4370. v39 = u1.DefaultWindowSizeTablet.X.Scale;
  4371. v40 = u1.DefaultWindowSizeTablet.X.Offset;
  4372. else
  4373. v39 = u1.DefaultWindowSizeDesktop.X.Scale;
  4374. v40 = u1.DefaultWindowSizeDesktop.X.Offset;
  4375. end;
  4376. v15.Size = UDim2.new(v39, v40, 0, (v37()));
  4377. v15.Position = u1.DefaultWindowPosition;
  4378. else
  4379. local v41 = v21();
  4380. if v23 == 1 then
  4381. v15.Size = u1.DefaultWindowSizePhone;
  4382. elseif v23 == 2 then
  4383. v15.Size = u1.DefaultWindowSizeTablet;
  4384. else
  4385. v15.Size = u1.DefaultWindowSizeDesktop;
  4386. end;
  4387. v15.Position = u1.DefaultWindowPosition;
  4388. end;
  4389. if v23 == 1 then
  4390. u1.ChatWindowTextSize = u1.ChatWindowTextSizePhone;
  4391. u1.ChatChannelsTabTextSize = u1.ChatChannelsTabTextSizePhone;
  4392. u1.ChatBarTextSize = u1.ChatBarTextSizePhone;
  4393. end;
  4394. local function v42(p12)
  4395. v15.Active = p12;
  4396. v15.Draggable = p12;
  4397. end;
  4398. local function u8(p13)
  4399. if v23 == 1 then
  4400. p13 = p13 or u1.ChatChannelsTabTextSizePhone;
  4401. else
  4402. p13 = p13 or u1.ChatChannelsTabTextSize;
  4403. end;
  4404. return math.max(32, p13 + 8) + 2;
  4405. end;
  4406. local function u9()
  4407. local v43 = nil;
  4408. local v44 = u8();
  4409. v43 = v37();
  4410. if not u1.ShowChannelsBar then
  4411. v18.Size = UDim2.new(1, 0, 1, -(v43 + 2 + 2));
  4412. v18.Position = UDim2.new(0, 0, 0, 2);
  4413. return;
  4414. end;
  4415. v18.Size = UDim2.new(1, 0, 1, -(v44 + v43 + 2 + 2));
  4416. v18.Position = UDim2.new(0, 0, 0, v44 + 2);
  4417. end;
  4418. local function v45(p14)
  4419. v17.Size = UDim2.new(1, 0, 0, (u8(p14)));
  4420. u9();
  4421. end;
  4422. local function u10(p15)
  4423. local v46 = nil;
  4424. v19.Visible = p15;
  4425. v19.Draggable = p15;
  4426. v46 = v16.Size.Y.Offset;
  4427. if p15 then
  4428. v16.Size = UDim2.new(1, -v46 - 2, 0, v46);
  4429. if bubbleChatOnly() then
  4430. return;
  4431. end;
  4432. else
  4433. v16.Size = UDim2.new(1, 0, 0, v46);
  4434. if not bubbleChatOnly() then
  4435. v16.Position = UDim2.new(0, 0, 1, -v46);
  4436. end;
  4437. return;
  4438. end;
  4439. v16.Position = UDim2.new(0, 0, 1, -v46);
  4440. end;
  4441. local function v47(p16)
  4442. local v48 = v37(p16);
  4443. v16.Size = UDim2.new(1, 0, 0, v48);
  4444. if not bubbleChatOnly() then
  4445. v16.Position = UDim2.new(0, 0, 1, -v48);
  4446. end;
  4447. v19.Size = UDim2.new(0, v48, 0, v48);
  4448. v19.Position = UDim2.new(1, -v48, 1, -v48);
  4449. u9();
  4450. u10(u1.WindowResizable);
  4451. end;
  4452. local function v49(p17)
  4453. v17.Visible = p17;
  4454. u9();
  4455. end;
  4456. v45(u1.ChatChannelsTabTextSize);
  4457. v47(u1.ChatBarTextSize);
  4458. v42(u1.WindowDraggable);
  4459. u10(u1.WindowResizable);
  4460. v49(u1.ShowChannelsBar);
  4461. u1.SettingsChanged:connect(function(p18, p19)
  4462. if p18 == "WindowDraggable" then
  4463. v42(p19);
  4464. return;
  4465. end;
  4466. if p18 == "WindowResizable" then
  4467. u10(p19);
  4468. return;
  4469. end;
  4470. if p18 == "ChatChannelsTabTextSize" then
  4471. v45(p19);
  4472. return;
  4473. end;
  4474. if p18 == "ChatBarTextSize" then
  4475. v47(p19);
  4476. return;
  4477. end;
  4478. if p18 == "ShowChannelsBar" then
  4479. v49(p19);
  4480. end;
  4481. end);
  4482. p3.GuiObject = v15;
  4483. p3.GuiObjects.BaseFrame = v15;
  4484. p3.GuiObjects.ChatBarParentFrame = v16;
  4485. p3.GuiObjects.ChannelsBarParentFrame = v17;
  4486. p3.GuiObjects.ChatChannelParentFrame = v18;
  4487. p3.GuiObjects.ChatResizerFrame = v19;
  4488. p3.GuiObjects.ResizeIcon = v20;
  4489. p3:AnimGuiObjects();
  4490. end;
  4491. function v9.GetChatBar(p20)
  4492. return p20.ChatBar;
  4493. end;
  4494. function v9.RegisterChatBar(p21, p22)
  4495. p21.ChatBar = p22;
  4496. p21.ChatBar:CreateGuiObjects(p21.GuiObjects.ChatBarParentFrame);
  4497. end;
  4498. function v9.RegisterChannelsBar(p23, p24)
  4499. p23.ChannelsBar = p24;
  4500. p23.ChannelsBar:CreateGuiObjects(p23.GuiObjects.ChannelsBarParentFrame);
  4501. end;
  4502. function v9.RegisterMessageLogDisplay(p25, p26)
  4503. p25.MessageLogDisplay = p26;
  4504. p25.MessageLogDisplay.GuiObject.Parent = p25.GuiObjects.ChatChannelParentFrame;
  4505. end;
  4506. local u11 = require(l__Parent__8:WaitForChild("ChatChannel"));
  4507. function v9.AddChannel(p27, p28)
  4508. if p27:GetChannel(p28) then
  4509. error("Channel '" .. p28 .. "' already exists!");
  4510. return;
  4511. end;
  4512. local v50 = u11.new(p28, p27.MessageLogDisplay);
  4513. p27.Channels[p28:lower()] = v50;
  4514. v50:SetActive(false);
  4515. local v51 = p27.ChannelsBar:AddChannelTab(p28);
  4516. v51.NameTag.MouseButton1Click:connect(function()
  4517. p27:SwitchCurrentChannel(p28);
  4518. end);
  4519. v50:RegisterChannelTab(v51);
  4520. return v50;
  4521. end;
  4522. function v9.GetFirstChannel(p29)
  4523. local v52, v53, v54 = pairs(p29.Channels);
  4524. local v55, v56 = v52(v53, v54);
  4525. if not v55 then
  4526. return nil;
  4527. end;
  4528. return v56;
  4529. end;
  4530. function v9.RemoveChannel(p30, p31)
  4531. if not p30:GetChannel(p31) then
  4532. error("Channel '" .. p31 .. "' does not exist!");
  4533. end;
  4534. local v57 = p31:lower();
  4535. local v58 = false;
  4536. if p30.Channels[v57] == p30:GetCurrentChannel() then
  4537. v58 = true;
  4538. p30:SwitchCurrentChannel(nil);
  4539. end;
  4540. p30.Channels[v57]:Destroy();
  4541. p30.Channels[v57] = nil;
  4542. p30.ChannelsBar:RemoveChannelTab(p31);
  4543. if v58 then
  4544. if p30:GetChannel(u1.GeneralChannelName) ~= nil and v57 ~= u1.GeneralChannelName:lower() then
  4545. local v59 = u1.GeneralChannelName;
  4546. else
  4547. local v60 = p30:GetFirstChannel();
  4548. v59 = v60 and v60.Name or nil;
  4549. end;
  4550. p30:SwitchCurrentChannel(v59);
  4551. end;
  4552. if not u1.ShowChannelsBar and p30.ChatBar.TargetChannel == p31 then
  4553. p30.ChatBar:SetChannelTarget(u1.GeneralChannelName);
  4554. end;
  4555. end;
  4556. function v9.GetChannel(p32, p33)
  4557. return p33 and p32.Channels[p33:lower()] or nil;
  4558. end;
  4559. function v9.GetTargetMessageChannel(p34)
  4560. if not u1.ShowChannelsBar then
  4561. return p34.ChatBar.TargetChannel;
  4562. end;
  4563. local v61 = p34:GetCurrentChannel();
  4564. return v61 and v61.Name;
  4565. end;
  4566. function v9.GetCurrentChannel(p35)
  4567. return p35.CurrentChannel;
  4568. end;
  4569. function v9.SwitchCurrentChannel(p36, p37)
  4570. if not u1.ShowChannelsBar then
  4571. local v62 = p36:GetChannel(p37);
  4572. if v62 then
  4573. p36.ChatBar:SetChannelTarget(v62.Name);
  4574. end;
  4575. p37 = u1.GeneralChannelName;
  4576. end;
  4577. local v63 = p36:GetCurrentChannel();
  4578. local v64 = p36:GetChannel(p37);
  4579. if v64 == nil then
  4580. error(string.format("Channel '%s' does not exist.", p37));
  4581. end;
  4582. if v64 ~= v63 then
  4583. if v63 then
  4584. v63:SetActive(false);
  4585. p36.ChannelsBar:GetChannelTab(v63.Name):SetActive(false);
  4586. end;
  4587. if v64 then
  4588. v64:SetActive(true);
  4589. p36.ChannelsBar:GetChannelTab(v64.Name):SetActive(true);
  4590. end;
  4591. p36.CurrentChannel = v64;
  4592. end;
  4593. end;
  4594. function v9.UpdateFrameVisibility(p38)
  4595. p38.GuiObject.Visible = p38.Visible and p38.CoreGuiEnabled;
  4596. end;
  4597. function v9.GetVisible(p39)
  4598. return p39.Visible;
  4599. end;
  4600. function v9.SetVisible(p40, p41)
  4601. p40.Visible = p41;
  4602. p40:UpdateFrameVisibility();
  4603. end;
  4604. function v9.GetCoreGuiEnabled(p42)
  4605. return p42.CoreGuiEnabled;
  4606. end;
  4607. function v9.SetCoreGuiEnabled(p43, p44)
  4608. p43.CoreGuiEnabled = p44;
  4609. p43:UpdateFrameVisibility();
  4610. end;
  4611. function v9.EnableResizable(p45)
  4612. p45.GuiObjects.ChatResizerFrame.Active = true;
  4613. end;
  4614. function v9.DisableResizable(p46)
  4615. p46.GuiObjects.ChatResizerFrame.Active = false;
  4616. end;
  4617. local u12 = require(l__Parent__8:WaitForChild("CurveUtil"));
  4618. function v9.FadeOutBackground(p47, p48)
  4619. p47.ChannelsBar:FadeOutBackground(p48);
  4620. p47.MessageLogDisplay:FadeOutBackground(p48);
  4621. p47.ChatBar:FadeOutBackground(p48);
  4622. p47.AnimParams.Background_TargetTransparency = 1;
  4623. p47.AnimParams.Background_NormalizedExptValue = u12:NormalizedDefaultExptValueInSeconds(p48);
  4624. end;
  4625. function v9.FadeInBackground(p49, p50)
  4626. p49.ChannelsBar:FadeInBackground(p50);
  4627. p49.MessageLogDisplay:FadeInBackground(p50);
  4628. p49.ChatBar:FadeInBackground(p50);
  4629. p49.AnimParams.Background_TargetTransparency = 0.6;
  4630. p49.AnimParams.Background_NormalizedExptValue = u12:NormalizedDefaultExptValueInSeconds(p50);
  4631. end;
  4632. function v9.FadeOutText(p51, p52)
  4633. p51.MessageLogDisplay:FadeOutText(p52);
  4634. p51.ChannelsBar:FadeOutText(p52);
  4635. end;
  4636. function v9.FadeInText(p53, p54)
  4637. p53.MessageLogDisplay:FadeInText(p54);
  4638. p53.ChannelsBar:FadeInText(p54);
  4639. end;
  4640. function v9.AnimGuiObjects(p55)
  4641. p55.GuiObjects.ChatChannelParentFrame.BackgroundTransparency = p55.AnimParams.Background_CurrentTransparency;
  4642. p55.GuiObjects.ChatResizerFrame.BackgroundTransparency = p55.AnimParams.Background_CurrentTransparency;
  4643. p55.GuiObjects.ResizeIcon.ImageTransparency = p55.AnimParams.Background_CurrentTransparency;
  4644. end;
  4645. function v9.InitializeAnimParams(p56)
  4646. p56.AnimParams.Background_TargetTransparency = 0.6;
  4647. p56.AnimParams.Background_CurrentTransparency = 0.6;
  4648. p56.AnimParams.Background_NormalizedExptValue = u12:NormalizedDefaultExptValueInSeconds(0);
  4649. end;
  4650. function v9.Update(p57, p58)
  4651. p57.ChatBar:Update(p58);
  4652. p57.ChannelsBar:Update(p58);
  4653. p57.MessageLogDisplay:Update(p58);
  4654. p57.AnimParams.Background_CurrentTransparency = u12:Expt(p57.AnimParams.Background_CurrentTransparency, p57.AnimParams.Background_TargetTransparency, p57.AnimParams.Background_NormalizedExptValue, p58);
  4655. p57:AnimGuiObjects();
  4656. end;
  4657. function v4.new()
  4658. local v65 = setmetatable({}, v9);
  4659. v65.GuiObject = nil;
  4660. v65.GuiObjects = {};
  4661. v65.ChatBar = nil;
  4662. v65.ChannelsBar = nil;
  4663. v65.MessageLogDisplay = nil;
  4664. v65.Channels = {};
  4665. v65.CurrentChannel = nil;
  4666. v65.Visible = true;
  4667. v65.CoreGuiEnabled = true;
  4668. v65.AnimParams = {};
  4669. v65:InitializeAnimParams();
  4670. return v65;
  4671. end;
  4672. return v4;
  4673. MessageLabelCreator:
  4674. -- Script GUID: {1862df25-7a83-47a1-ba46-34cf5d067914}
  4675. -- Decompiled with the Synapse X Luau decompiler.
  4676.  
  4677. local v1 = {};
  4678. local l__Chat__2 = game:GetService("Chat");
  4679. local l__ClientChatModules__3 = l__Chat__2:WaitForChild("ClientChatModules");
  4680. local l__MessageCreatorModules__4 = l__ClientChatModules__3:WaitForChild("MessageCreatorModules");
  4681. local l__Parent__5 = script.Parent;
  4682. local v6 = require(l__ClientChatModules__3:WaitForChild("ChatSettings"));
  4683. local v7 = require(l__Parent__5:WaitForChild("MessageSender"));
  4684. local v8 = {};
  4685. v8.__index = v8;
  4686. function mergeProps(p1, p2)
  4687. if not p1 then
  4688. return;
  4689. end;
  4690. local v9, v10, v11 = pairs(p1);
  4691. while true do
  4692. local v12, v13 = v9(v10, v11);
  4693. if v12 then
  4694.  
  4695. else
  4696. break;
  4697. end;
  4698. v11 = v12;
  4699. p2[v12] = v13;
  4700. end;
  4701. end;
  4702. function ReturnToObjectPoolRecursive(p3, p4)
  4703. local v14 = p3:GetChildren();
  4704. local v15 = #v14;
  4705. local v16 = 1 - 1;
  4706. while true do
  4707. ReturnToObjectPoolRecursive(v14[v16], p4);
  4708. if 0 <= 1 then
  4709. if v16 < v15 then
  4710.  
  4711. else
  4712. break;
  4713. end;
  4714. elseif v15 < v16 then
  4715.  
  4716. else
  4717. break;
  4718. end;
  4719. v16 = v16 + 1;
  4720. end;
  4721. p3.Parent = nil;
  4722. p4:ReturnInstance(p3);
  4723. end;
  4724. local u1 = require(l__MessageCreatorModules__4:WaitForChild("Util"));
  4725. function GetMessageCreators()
  4726. local v17 = {};
  4727. local v18 = l__MessageCreatorModules__4:GetChildren();
  4728. local v19 = #v18;
  4729. local v20 = 1 - 1;
  4730. while true do
  4731. if v18[v20]:IsA("ModuleScript") then
  4732. if v18[v20].Name ~= "Util" then
  4733. local v21 = require(v18[v20]);
  4734. v17[v21[u1.KEY_MESSAGE_TYPE]] = v21[u1.KEY_CREATOR_FUNCTION];
  4735. end;
  4736. end;
  4737. if 0 <= 1 then
  4738. if v20 < v19 then
  4739.  
  4740. else
  4741. break;
  4742. end;
  4743. elseif v19 < v20 then
  4744.  
  4745. else
  4746. break;
  4747. end;
  4748. v20 = v20 + 1;
  4749. end;
  4750. return v17;
  4751. end;
  4752. function v8.WrapIntoMessageObject(p5, p6, p7)
  4753. local v22 = nil;
  4754. if u1.KEY_BASE_MESSAGE then
  4755. v22 = p7[u1.KEY_BASE_MESSAGE];
  4756. end;
  4757. return {
  4758. ID = p6.ID,
  4759. BaseFrame = p7[u1.KEY_BASE_FRAME],
  4760. BaseMessage = v22,
  4761. UpdateTextFunction = p7[u1.KEY_UPDATE_TEXT_FUNC] or function()
  4762. warn("NO MESSAGE RESIZE FUNCTION");
  4763. end,
  4764. GetHeightFunction = p7[u1.KEY_GET_HEIGHT],
  4765. FadeInFunction = p7[u1.KEY_FADE_IN],
  4766. FadeOutFunction = p7[u1.KEY_FADE_OUT],
  4767. UpdateAnimFunction = p7[u1.KEY_UPDATE_ANIMATION],
  4768. ObjectPool = p5.ObjectPool,
  4769. Destroyed = false,
  4770. Destroy = function(p8)
  4771. ReturnToObjectPoolRecursive(p8.BaseFrame, p8.ObjectPool);
  4772. p8.Destroyed = true;
  4773. end
  4774. };
  4775. end;
  4776. function v8.CreateMessageLabel(p9, p10, p11)
  4777. local v23 = nil;
  4778. p10.Channel = p11;
  4779. local u2 = nil;
  4780. pcall(function()
  4781. u2 = l__Chat__2:InvokeChatCallback(Enum.ChatCallbackType.OnClientFormattingMessage, p10);
  4782. end);
  4783. p10.ExtraData = p10.ExtraData or {};
  4784. mergeProps(u2, p10.ExtraData);
  4785. local l__MessageType__24 = p10.MessageType;
  4786. if p9.MessageCreators[l__MessageType__24] then
  4787. local v25 = p9.MessageCreators[l__MessageType__24](p10, p11);
  4788. if v25 then
  4789. return p9:WrapIntoMessageObject(p10, v25);
  4790. else
  4791. return;
  4792. end;
  4793. elseif p9.DefaultCreatorType then
  4794. v23 = p9.MessageCreators[p9.DefaultCreatorType](p10, p11);
  4795. if not v23 then
  4796. return;
  4797. end;
  4798. else
  4799. error("No message creator available for message type: " .. l__MessageType__24);
  4800. return;
  4801. end;
  4802. return p9:WrapIntoMessageObject(p10, v23);
  4803. end;
  4804. local u3 = require(l__Parent__5:WaitForChild("ObjectPool"));
  4805. function v1.new()
  4806. local v26 = setmetatable({}, v8);
  4807. v26.ObjectPool = u3.new(50);
  4808. v26.MessageCreators = GetMessageCreators();
  4809. v26.DefaultCreatorType = u1.DEFAULT_MESSAGE_CREATOR;
  4810. u1:RegisterObjectPool(v26.ObjectPool);
  4811. return v26;
  4812. end;
  4813. function v1.GetStringTextBounds(p12, p13, p14, p15, p16)
  4814. return u1:GetStringTextBounds(p13, p14, p15, p16);
  4815. end;
  4816. return v1;
  4817. CommandProcessor:
  4818. -- Script GUID: {bec2a34d-21a2-4ca8-846c-27cb5d9b3b84}
  4819. -- Decompiled with the Synapse X Luau decompiler.
  4820.  
  4821. local v1 = {};
  4822. local v2 = {};
  4823. v2.__index = v2;
  4824. local l__ClientChatModules__3 = game:GetService("Chat"):WaitForChild("ClientChatModules");
  4825. local l__CommandModules__4 = l__ClientChatModules__3:WaitForChild("CommandModules");
  4826. local l__Parent__5 = script.Parent;
  4827. local u1 = require(l__CommandModules__4:WaitForChild("Util"));
  4828. function v2.SetupCommandProcessors(p1)
  4829. local v6 = l__CommandModules__4:GetChildren();
  4830. for v7 = 1, #v6 do
  4831. if v6[v7]:IsA("ModuleScript") and v6[v7].Name ~= "Util" then
  4832. local v8 = nil;
  4833. local v9 = require(v6[v7]);
  4834. local v10 = v9[u1.KEY_COMMAND_PROCESSOR_TYPE];
  4835. v8 = v9[u1.KEY_PROCESSOR_FUNCTION];
  4836. if v10 == u1.IN_PROGRESS_MESSAGE_PROCESSOR then
  4837. table.insert(p1.InProgressMessageProcessors, v8);
  4838. elseif v10 == u1.COMPLETED_MESSAGE_PROCESSOR then
  4839. table.insert(p1.CompletedMessageProcessors, v8);
  4840. end;
  4841. end;
  4842. end;
  4843. end;
  4844. local u2 = require(l__ClientChatModules__3:WaitForChild("ChatSettings"));
  4845. function v2.ProcessCompletedChatMessage(p2, p3, p4)
  4846. for v11 = 1, #p2.CompletedMessageProcessors do
  4847. if p2.CompletedMessageProcessors[v11](p3, p4, u2) then
  4848. return true;
  4849. end;
  4850. end;
  4851. return false;
  4852. end;
  4853. function v2.ProcessInProgressChatMessage(p5, p6, p7, p8)
  4854. for v12 = 1, #p5.InProgressMessageProcessors do
  4855. local v13 = p5.InProgressMessageProcessors[v12](p6, p7, p8, u2);
  4856. if v13 then
  4857. return v13;
  4858. end;
  4859. end;
  4860. return nil;
  4861. end;
  4862. function v1.new()
  4863. local v14 = setmetatable({}, v2);
  4864. v14.CompletedMessageProcessors = {};
  4865. v14.InProgressMessageProcessors = {};
  4866. v14:SetupCommandProcessors();
  4867. return v14;
  4868. end;
  4869. return v1;
  4870. ChannelsTab:
  4871. -- Script GUID: {76e85709-929d-421a-a886-5014a998a445}
  4872. -- Decompiled with the Synapse X Luau decompiler.
  4873.  
  4874. local v1 = {};
  4875. local v2 = {};
  4876. v2.__index = v2;
  4877. local u1 = require(game:GetService("Chat"):WaitForChild("ClientChatModules"):WaitForChild("ChatSettings"));
  4878. function v2.Destroy(p1)
  4879. p1.GuiObject:Destroy();
  4880. end;
  4881. function v2.UpdateMessagePostedInChannel(p2, p3)
  4882. if p2.Active and p3 ~= true then
  4883. return;
  4884. end;
  4885. local v3 = p2.UnreadMessageCount + 1;
  4886. p2.UnreadMessageCount = v3;
  4887. local l__NewMessageIcon__4 = p2.NewMessageIcon;
  4888. l__NewMessageIcon__4.Visible = true;
  4889. l__NewMessageIcon__4.TextLabel.Text = v3 < 100 and tostring(v3) or "!";
  4890. local v5 = l__NewMessageIcon__4.Position + UDim2.new(0, 0, -0.1, 0);
  4891. l__NewMessageIcon__4.Position = UDim2.new(0, 0, -0.15, 0);
  4892. l__NewMessageIcon__4:TweenPosition(UDim2.new(0, 0, 0, 0), Enum.EasingDirection.Out, Enum.EasingStyle.Quad, 0.15, true);
  4893. end;
  4894. function v2.SetActive(p4, p5)
  4895. p4.Active = p5;
  4896. p4.UnselectedFrame.Visible = not p5;
  4897. p4.SelectedFrame.Visible = p5;
  4898. if not p5 then
  4899. p4.NameTag.Font = Enum.Font.SourceSans;
  4900. return;
  4901. end;
  4902. p4.UnreadMessageCount = 0;
  4903. p4.NewMessageIcon.Visible = false;
  4904. p4.NameTag.Font = Enum.Font.SourceSansBold;
  4905. end;
  4906. function v2.SetTextSize(p6, p7)
  4907. p6.NameTag.TextSize = p7;
  4908. end;
  4909. local u2 = require(script.Parent:WaitForChild("CurveUtil"));
  4910. function v2.FadeOutBackground(p8, p9)
  4911. p8.AnimParams.Background_TargetTransparency = 1;
  4912. p8.AnimParams.Background_NormalizedExptValue = u2:NormalizedDefaultExptValueInSeconds(p9);
  4913. end;
  4914. function v2.FadeInBackground(p10, p11)
  4915. p10.AnimParams.Background_TargetTransparency = 0.6;
  4916. p10.AnimParams.Background_NormalizedExptValue = u2:NormalizedDefaultExptValueInSeconds(p11);
  4917. end;
  4918. function v2.FadeOutText(p12, p13)
  4919. p12.AnimParams.Text_TargetTransparency = 1;
  4920. p12.AnimParams.Text_NormalizedExptValue = u2:NormalizedDefaultExptValueInSeconds(p13);
  4921. p12.AnimParams.TextStroke_TargetTransparency = 1;
  4922. p12.AnimParams.TextStroke_NormalizedExptValue = u2:NormalizedDefaultExptValueInSeconds(p13);
  4923. end;
  4924. function v2.FadeInText(p14, p15)
  4925. p14.AnimParams.Text_TargetTransparency = 0;
  4926. p14.AnimParams.Text_NormalizedExptValue = u2:NormalizedDefaultExptValueInSeconds(p15);
  4927. p14.AnimParams.TextStroke_TargetTransparency = 0.75;
  4928. p14.AnimParams.TextStroke_NormalizedExptValue = u2:NormalizedDefaultExptValueInSeconds(p15);
  4929. end;
  4930. function v2.AnimGuiObjects(p16)
  4931. p16.UnselectedFrame.BackgroundTransparency = p16.AnimParams.Background_CurrentTransparency;
  4932. p16.SelectedFrame.BackgroundImage.BackgroundTransparency = p16.AnimParams.Background_CurrentTransparency;
  4933. p16.SelectedFrame.BlueBarLeft.ImageTransparency = p16.AnimParams.Background_CurrentTransparency;
  4934. p16.SelectedFrame.BlueBarRight.ImageTransparency = p16.AnimParams.Background_CurrentTransparency;
  4935. p16.NameTagNonSelect.TextTransparency = p16.AnimParams.Background_CurrentTransparency;
  4936. p16.NameTagNonSelect.TextStrokeTransparency = p16.AnimParams.Background_CurrentTransparency;
  4937. p16.NameTag.TextTransparency = p16.AnimParams.Text_CurrentTransparency;
  4938. p16.NewMessageIcon.ImageTransparency = p16.AnimParams.Text_CurrentTransparency;
  4939. p16.WhiteTextNewMessageNotification.TextTransparency = p16.AnimParams.Text_CurrentTransparency;
  4940. p16.NameTagSelect.TextTransparency = p16.AnimParams.Text_CurrentTransparency;
  4941. p16.NameTag.TextStrokeTransparency = p16.AnimParams.TextStroke_CurrentTransparency;
  4942. p16.WhiteTextNewMessageNotification.TextStrokeTransparency = p16.AnimParams.TextStroke_CurrentTransparency;
  4943. p16.NameTagSelect.TextStrokeTransparency = p16.AnimParams.TextStroke_CurrentTransparency;
  4944. end;
  4945. function v2.InitializeAnimParams(p17)
  4946. p17.AnimParams.Text_TargetTransparency = 0;
  4947. p17.AnimParams.Text_CurrentTransparency = 0;
  4948. p17.AnimParams.Text_NormalizedExptValue = u2:NormalizedDefaultExptValueInSeconds(0);
  4949. p17.AnimParams.TextStroke_TargetTransparency = 0.75;
  4950. p17.AnimParams.TextStroke_CurrentTransparency = 0.75;
  4951. p17.AnimParams.TextStroke_NormalizedExptValue = u2:NormalizedDefaultExptValueInSeconds(0);
  4952. p17.AnimParams.Background_TargetTransparency = 0.6;
  4953. p17.AnimParams.Background_CurrentTransparency = 0.6;
  4954. p17.AnimParams.Background_NormalizedExptValue = u2:NormalizedDefaultExptValueInSeconds(0);
  4955. end;
  4956. function v2.Update(p18, p19)
  4957. p18.AnimParams.Background_CurrentTransparency = u2:Expt(p18.AnimParams.Background_CurrentTransparency, p18.AnimParams.Background_TargetTransparency, p18.AnimParams.Background_NormalizedExptValue, p19);
  4958. p18.AnimParams.Text_CurrentTransparency = u2:Expt(p18.AnimParams.Text_CurrentTransparency, p18.AnimParams.Text_TargetTransparency, p18.AnimParams.Text_NormalizedExptValue, p19);
  4959. p18.AnimParams.TextStroke_CurrentTransparency = u2:Expt(p18.AnimParams.TextStroke_CurrentTransparency, p18.AnimParams.TextStroke_TargetTransparency, p18.AnimParams.TextStroke_NormalizedExptValue, p19);
  4960. p18:AnimGuiObjects();
  4961. end;
  4962. local function u3()
  4963. local v6 = Instance.new("Frame");
  4964. v6.Selectable = false;
  4965. v6.Size = UDim2.new(1, 0, 1, 0);
  4966. v6.BackgroundTransparency = 1;
  4967. local v7 = Instance.new("Frame");
  4968. v7.Selectable = false;
  4969. v7.Name = "BackgroundFrame";
  4970. v7.Size = UDim2.new(1, -2, 1, -2);
  4971. v7.Position = UDim2.new(0, 1, 0, 1);
  4972. v7.BackgroundTransparency = 1;
  4973. v7.Parent = v6;
  4974. local v8 = Instance.new("Frame");
  4975. v8.Selectable = false;
  4976. v8.Name = "UnselectedFrame";
  4977. v8.Size = UDim2.new(1, 0, 1, 0);
  4978. v8.Position = UDim2.new(0, 0, 0, 0);
  4979. v8.BorderSizePixel = 0;
  4980. v8.BackgroundColor3 = u1.ChannelsTabUnselectedColor;
  4981. v8.BackgroundTransparency = 0.6;
  4982. v8.Parent = v7;
  4983. local v9 = Instance.new("Frame");
  4984. v9.Selectable = false;
  4985. v9.Name = "SelectedFrame";
  4986. v9.Size = UDim2.new(1, 0, 1, 0);
  4987. v9.Position = UDim2.new(0, 0, 0, 0);
  4988. v9.BorderSizePixel = 0;
  4989. v9.BackgroundColor3 = u1.ChannelsTabSelectedColor;
  4990. v9.BackgroundTransparency = 1;
  4991. v9.Parent = v7;
  4992. local v10 = Instance.new("ImageLabel");
  4993. v10.Selectable = false;
  4994. v10.Name = "BackgroundImage";
  4995. v10.BackgroundTransparency = 1;
  4996. v10.BorderSizePixel = 0;
  4997. v10.Size = UDim2.new(1, 0, 1, 0);
  4998. v10.Position = UDim2.new(0, 0, 0, 0);
  4999. v10.ScaleType = Enum.ScaleType.Slice;
  5000. v10.Parent = v9;
  5001. v10.BackgroundTransparency = -0.4;
  5002. v10.BackgroundColor3 = Color3.fromRGB(93.6, 100.8, 115.19999999999999);
  5003. local v11 = Instance.new("ImageLabel");
  5004. v11.Selectable = false;
  5005. v11.Size = UDim2.new(0.5, -2, 0, 4);
  5006. v11.BackgroundTransparency = 1;
  5007. v11.ScaleType = Enum.ScaleType.Slice;
  5008. v11.SliceCenter = Rect.new(3, 3, 32, 21);
  5009. v11.Parent = v9;
  5010. local v12 = v11:Clone();
  5011. v12.Parent = v9;
  5012. v11.Position = UDim2.new(0, 2, 1, -4);
  5013. v12.Position = UDim2.new(0.5, 0, 1, -4);
  5014. v11.Image = "rbxasset://textures/ui/Settings/Slider/SelectedBarLeft.png";
  5015. v12.Image = "rbxasset://textures/ui/Settings/Slider/SelectedBarRight.png";
  5016. v11.Name = "BlueBarLeft";
  5017. v12.Name = "BlueBarRight";
  5018. local v13 = Instance.new("TextButton");
  5019. v13.Selectable = u1.GamepadNavigationEnabled;
  5020. v13.Size = UDim2.new(1, 0, 1, 0);
  5021. v13.Position = UDim2.new(0, 0, 0, 0);
  5022. v13.BackgroundTransparency = 1;
  5023. v13.Font = u1.DefaultFont;
  5024. v13.TextSize = u1.ChatChannelsTabTextSize;
  5025. v13.TextColor3 = Color3.new(1, 1, 1);
  5026. v13.TextStrokeTransparency = 0.75;
  5027. v13.Parent = v7;
  5028. local v14 = v13:Clone();
  5029. local v15 = v13:Clone();
  5030. v14.Parent = v8;
  5031. v15.Parent = v9;
  5032. v14.Font = Enum.Font.SourceSans;
  5033. v14.Active = false;
  5034. v15.Active = false;
  5035. local v16 = Instance.new("Frame");
  5036. v16.Selectable = false;
  5037. v16.Size = UDim2.new(0, 18, 0, 18);
  5038. v16.Position = UDim2.new(0.8, -9, 0.5, -9);
  5039. v16.BackgroundTransparency = 1;
  5040. v16.Parent = v7;
  5041. local v17 = Instance.new("ImageLabel");
  5042. v17.Selectable = false;
  5043. v17.Size = UDim2.new(1, 0, 1, 0);
  5044. v17.BackgroundTransparency = 1;
  5045. v17.Image = "rbxasset://textures/ui/Chat/MessageCounter.png";
  5046. v17.Visible = false;
  5047. v17.Parent = v16;
  5048. local v18 = Instance.new("TextLabel");
  5049. v18.Selectable = false;
  5050. v18.BackgroundTransparency = 1;
  5051. v18.Size = UDim2.new(0, 13, 0, 9);
  5052. v18.Position = UDim2.new(0.5, -7, 0.5, -7);
  5053. v18.Font = u1.DefaultFont;
  5054. v18.TextSize = 14;
  5055. v18.TextColor3 = Color3.new(1, 1, 1);
  5056. v18.Text = "";
  5057. v18.Parent = v17;
  5058. return v6, v13, v14, v15, v17, v8, v9;
  5059. end;
  5060. function v1.new(p20)
  5061. local v19 = setmetatable({}, v2);
  5062. local v20, v21, v22, v23, v24, v25, v26 = u3();
  5063. v19.GuiObject = v20;
  5064. v19.NameTag = v21;
  5065. v19.NameTagNonSelect = v22;
  5066. v19.NameTagSelect = v23;
  5067. v19.NewMessageIcon = v24;
  5068. v19.UnselectedFrame = v25;
  5069. v19.SelectedFrame = v26;
  5070. v19.BlueBarLeft = v26.BlueBarLeft;
  5071. v19.BlueBarRight = v26.BlueBarRight;
  5072. v19.BackgroundImage = v26.BackgroundImage;
  5073. v19.WhiteTextNewMessageNotification = v19.NewMessageIcon.TextLabel;
  5074. v19.ChannelName = p20;
  5075. v19.UnreadMessageCount = 0;
  5076. v19.Active = false;
  5077. v19.GuiObject.Name = "Frame_" .. v19.ChannelName;
  5078. if u1.MaxChannelNameLength < string.len(p20) then
  5079. p20 = string.sub(p20, 1, u1.MaxChannelNameLength - 3) .. "...";
  5080. end;
  5081. v19.NameTag.Text = "";
  5082. v19.NameTagNonSelect.Text = p20;
  5083. v19.NameTagSelect.Text = p20;
  5084. v19.AnimParams = {};
  5085. v19:InitializeAnimParams();
  5086. v19:AnimGuiObjects();
  5087. v19:SetActive(false);
  5088. return v19;
  5089. end;
  5090. return v1;
  5091. ObjectPool:
  5092. -- Script GUID: {c4029029-c46d-4d9d-ba07-3e8c4a4416d0}
  5093. -- Decompiled with the Synapse X Luau decompiler.
  5094.  
  5095. local v1 = {};
  5096. local v2 = {};
  5097. v2.__index = v2;
  5098. function v2.GetInstance(p1, p2)
  5099. if p1.InstancePoolsByClass[p2] == nil then
  5100. p1.InstancePoolsByClass[p2] = {};
  5101. end;
  5102. local v3 = #p1.InstancePoolsByClass[p2];
  5103. if not (v3 > 0) then
  5104. return Instance.new(p2);
  5105. end;
  5106. table.remove(p1.InstancePoolsByClass[p2]);
  5107. return p1.InstancePoolsByClass[p2][v3];
  5108. end;
  5109. function v2.ReturnInstance(p3, p4)
  5110. if p3.InstancePoolsByClass[p4.ClassName] == nil then
  5111. p3.InstancePoolsByClass[p4.ClassName] = {};
  5112. end;
  5113. if not (#p3.InstancePoolsByClass[p4.ClassName] < p3.PoolSizePerType) then
  5114. p4:Destroy();
  5115. return;
  5116. end;
  5117. table.insert(p3.InstancePoolsByClass[p4.ClassName], p4);
  5118. end;
  5119. function v1.new(p5)
  5120. local v4 = setmetatable({}, v2);
  5121. v4.InstancePoolsByClass = {};
  5122. v4.Name = "ObjectPool";
  5123. v4.PoolSizePerType = p5;
  5124. return v4;
  5125. end;
  5126. return v1;
  5127. MessageSender:
  5128. -- Script GUID: {0fb37f2f-f8d5-4400-bc9e-44ac716a5054}
  5129. -- Decompiled with the Synapse X Luau decompiler.
  5130.  
  5131. local v1 = {};
  5132. local l__Parent__2 = script.Parent;
  5133. local v3 = {};
  5134. v3.__index = v3;
  5135. function v3.SendMessage(p1, p2, p3)
  5136. p1.SayMessageRequest:FireServer(p2, p3);
  5137. end;
  5138. function v3.RegisterSayMessageFunction(p4, p5)
  5139. p4.SayMessageRequest = p5;
  5140. end;
  5141. function v1.new()
  5142. local v4 = setmetatable({}, v3);
  5143. v4.SayMessageRequest = nil;
  5144. return v4;
  5145. end;
  5146. return v1.new();
  5147. CurveUtil:
  5148. -- Script GUID: {aac71cdd-83ac-4b6b-9435-05ca45660866}
  5149. -- Decompiled with the Synapse X Luau decompiler.
  5150.  
  5151. local u1 = {
  5152. Expt = function(p1, p2, p3, p4, p5)
  5153. if math.abs(p3 - p2) < 0.01 then
  5154. return p3;
  5155. end;
  5156. return p2 + (p3 - p2) * u1:Expty(p2, p3, p4, p5);
  5157. end,
  5158. Expty = function(p6, p7, p8, p9, p10)
  5159. return 1 - math.exp(-(-math.log(1 - p9)) * p10);
  5160. end,
  5161. Sign = function(p11, p12)
  5162. if p12 > 0 then
  5163. return 1;
  5164. end;
  5165. if p12 < 0 then
  5166. return -1;
  5167. end;
  5168. return 0;
  5169. end,
  5170. BezierValForT = function(p13, p14, p15, p16, p17, p18)
  5171. return (1 - p18) * (1 - p18) * (1 - p18) * p14 + 3 * p18 * (1 - p18) * (1 - p18) * p15 + 3 * p18 * p18 * (1 - p18) * p16 + p18 * p18 * p18 * p17;
  5172. end,
  5173. _BezierPt2ForT = {
  5174. x = 0,
  5175. y = 0
  5176. },
  5177. BezierPt2ForT = function(p19, p20, p21, p22, p23, p24, p25, p26, p27, p28)
  5178. u1._BezierPt2ForT.x = u1:BezierValForT(p20, p22, p24, p26, p28);
  5179. u1._BezierPt2ForT.y = u1:BezierValForT(p21, p23, p25, p27, p28);
  5180. return u1._BezierPt2ForT;
  5181. end,
  5182. YForPointOf2PtLine = function(p29, p30, p31, p32)
  5183. local v1 = (p30.y - p31.y) / (p30.x - p31.x);
  5184. return v1 * p32 + (p30.y - v1 * p30.x);
  5185. end,
  5186. DeltaTimeToTimescale = function(p33, p34)
  5187. return p34 / 0.016666666666666666;
  5188. end,
  5189. SecondsToTick = function(p35, p36)
  5190. return 0.016666666666666666 / p36;
  5191. end,
  5192. ExptValueInSeconds = function(p37, p38, p39, p40)
  5193. return 1 - math.pow(p38 / p39, 1 / (60 * p40));
  5194. end,
  5195. NormalizedDefaultExptValueInSeconds = function(p41, p42)
  5196. return p41:ExptValueInSeconds(0.01, 1, p42);
  5197. end
  5198. };
  5199. return u1;
Advertisement
Add Comment
Please, Sign In to add comment