TextChatService UI not appearing if default channels aren't created

I’m using custom channels in TextChatService, and it was working fine a week ago, and all of a sudden with no changes it stopped working. I’ve already checked the roblox update logs and nothing.

CreateDefaultTextChannels = false
CreateDefaultTextCommands = false
ChatInputBarConfiguration.TargetTextChannel = General

-- Authorized Use By SCP USNEOM and Galicate

-- Programmer : Galicate

--// SERVICES //--
local ReplicatedStorage = game:GetService("ReplicatedStorage")
local TextChatService = game:GetService("TextChatService")
local Players = game:GetService("Players")

--// FILES //--
local Knit = require(ReplicatedStorage.KnitPackage.Knit)
local ChatService = Knit.CreateService{Name = "ChatService", Client = {
	SystemMessageReceived = Knit.CreateSignal(),
	GeneralMessageReceived = Knit.CreateSignal(),
	RadioMessageReceived = Knit.CreateSignal()

--// CONSTANTS //--
local TEXT_CHANNELS = TextChatService:WaitForChild("TextChannels")
local SYSTEM_CHANNEL: TextChannel = TEXT_CHANNELS:WaitForChild("System")
local GENERAL_CHANNEL: TextChannel = TEXT_CHANNELS:WaitForChild("General")
local RADIO_CHANNEL: TextChannel = TEXT_CHANNELS:WaitForChild("Radio")

--// VARIABLES //--

--// FUNCTIONS //--
local function playerAdded(player: Player)
	ChatService:DisplaySystemMessageToAll(player.DisplayName .. " has joined the site!")

local function playerRemoved(player: Player)
	ChatService:DisplaySystemMessageToAll(player.DisplayName .. " has left the site!")

function ChatService:DisplaySystemMessageToAll(message: string)

function ChatService:DisplaySystemMessageToClient(client: Player, message: string)
	assert(client, "DisplaySystemMessageToClient() requires a [client: Player] as the first parameter.")
	self.Client.SystemMessageReceived:Fire(client, message)

function ChatService:DisplayGeneralMessageToAll(message: string, metadata: string)
	self.Client.GeneralMessageReceived:FireAll(message, metadata)

function ChatService:DisplayGeneralMessageToClient(client: Player, message: string, metadata: string)
	assert(client, "DisplayGeneralMessageToClient() requires a [client: Player] as the first parameter.")
	self.Client.GeneralMessageReceived:Fire(client, message, metadata)

function ChatService:KnitStart()
	for _, player in pairs(Players:GetPlayers()) do
		task.spawn(playerAdded, player)

--// HOOKS //--

--// EXECUTION //--
return ChatService

The UI does not appear, I cannot press the slash key to open the UI, nor can I click the chat button, however I do still seem to get the dot for unread messages, I’m just unable to open the UI or chat at all.


Bumping and edit:
It seems that if I enable CreateDefaultTextChannels and then delete them after the player has joined, then it works, however there are a few bugs to this and it doesn’t work.

  1. Any players who join after the channels are deleted can’t use TextChatService
  2. Players can still type /team, however because the text channel for their team doesn’t exist, it sets their TargetTextChannel to nil, making it so they cannot speak.

Edit 2:
If I give the player a custom textbox to chat through, the messages still go through, however I can’t use slash to focus the text bot, chat bubbles don’t appear, and I still can’t see the messages, I have to use print in the output to see them.


Turns out one of the studio updates broke it, I reported it and this issue is no longer happening.

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.