TextChatCommands created by Script only partially show up in Chat Box

  1. As seen in video when typing " / " in the textbox the commands appear, like the “/ChangeTeam” Command, this command is created by a serverscript once the server starts.
    It does work like intented, but as soon as I type, as example /C, the command disappears, and you can only see the default commands by roblox, (Auto completion is turned on btw.)

  2. When trying to type another command “reset_exe”, which is created before in studio, it will remain visible while typing letters of the command such as /res…

Is this some kind of bug? If the script, creating the commands is needed lmk.

Can you share the script? It’s hard to tell what’s the problem without a source.

This one creates the Commands

for i,v in pairs(CommandFunctions) do
	local Object = Instance.new("TextChatCommand")
	Object.Name = i
	Object.PrimaryAlias = v.Alias
	if v.SecondaryAlias then
		Object.SecondaryAlias = v.SecondaryAlias
	end
	Object.Parent = TCS.Commands
	
	Object.Triggered:Connect(function(originTextSource, unfilteredText)
		task.spawn(v.Function, originTextSource, unfilteredText)
	end)
end

And this a example Table

local CommandFunctions = {
	["View Items"] = {
		Alias = "/ViewItems",
		SecondaryAlias = nil,
		Function = function(originTextSource, unfilteredText)
			local Player = Players:GetPlayerByUserId(originTextSource.UserId)
			if not Dev(Player) then return end

			for _, child in pairs(Tools) do
				print(child.Name)
			end 
		end,
	}
}

image
Just to be said, I tried parenting the commands to TextChatService, like the “reset_exe” command, but it doesn’t change anything