Currently, Roblox allows you to send messages with a lot of whitespace in any experience, which can allow you to create fake system messages if you ever choose to. This includes using the textbox or through :SendAsync().
This should not be the case as it can allow users to flood the chat with long stretches of whitespace.
Expected behavior
I expect messages sent with :SendAsync() with a lot of whitespace to be shortened, including replacing tab spaces with regular spaces.
Ideally Roblox shouldn’t limit this for custom uses of the API (or they should at least make it optional), though. TextChatService is already so heavily restricted as-is. Another limitation would only add to the difficulties with dealing with it.
This is why :DisplaySystemMessage() was excluded. The displayed system message system already doesn’t convert any symbols to their escape forms automatically (eg. < into <) to allow for custom rich text within messages. Using the textbox or :SendAsync() automatically does convert them so that users are unable to write rich text manually. This limitation for users is to ensure that they cannot bypass chat by using invisible rich text
How about if I want users to be able to send messages with multiple spaces for my use-case? DisplaySystemMessage doesn’t filter messages so it is unfortunately unsuitable for that use-case.
You then will need to use TextService:FilterStringAsync() for :DisplaySystemMessage(). You’d have to ensure that it is connected to a server remote. I currently do not know about any use-case for keeping this unless you manually write it in yourself. Perhaps this can be implemented in the default properties that you can optionally bring back through scripting
Can you explain your use-cases for allowing users to send a lot of whitespace? I want to make sure you aren’t confusing it with developers adding it to existing messages because that will not be affected by it being added after the message is sent to the client. Adding metadata to the message is a solution to allow scripts to know to add the required whitespace for developers
I also am sure that Roblox answered that using TextService’s filter is fine
They do mention to not use it inappropriately for a chat feature. If you are using :DisplaySystemMessage(), then it is not a chat message and is instead an announcement. I am assuming that this is your use-case unless it is not the case
It also is stated as part of the API reference as such
If I am incorrect about this, I would like staff to answer that and ensure that it is fixed to reduce confusion!