I want a text to appear by a chatbox. I DONT MEAN BY THIS
game.Chat:Chat()
Can you please help? Well, I don't know what to do so thats why theres no code.
I want a text to appear by a chatbox. I DONT MEAN BY THIS
game.Chat:Chat()
Can you please help? Well, I don't know what to do so thats why theres no code.
I have a fix and I would appreciate it if you could also fix my problems(on my scripting helpers profile)
CLIENT SETUP
WITH CLIENT SETUP EVERY PLAYER WILL SEE A DIFFRENT MESSAGE
To do on client put this code in a local script in StarterPlayerScripts:
while true do
local WaitTime = math.random(30,60) --wait time randomiser
local Chat = { --Text to be used(list of possible chat msgs)
"[System Message] Hello",
"[System Message] Remember to like this game",
"[System Message] Are you enjoying?"
}
local randommsgs = Chat[math.random(1, #Chat)]
game.StarterGui:SetCore( "ChatMakeSystemMessage",
{ Text = randommsgs,
Color = Color3.fromRGB( 255,0,0 ), --Coulor to be used
Font = Enum.Font.Arial, --Font to be used
FontSize = Enum.FontSize.Size24 } ) --Text size
wait(WaitTime) --Waits the vale of w seconds between each message
end
with this one it only shows in chat box
Here is your 20 reputation.
thanks
The correct syntax for using Chat() is as follows:
local Mouth = game:GetService("Chat") -- Lolz
local Players = game:GetService("Players")
local ind = 1
local Speaker = Instance.new("Part",workspace)
Players.PlayerAdded:Connect(function(plr)
while plr.Character == nil do
print("Waiting"..string.rep(".",ind))
if(plr.Character ~= nil) then wait(1) break end
wait()
ind = ind+1 < 4 and ind +1 or 1
end
Mouth:Chat(Speaker,"Hai!, "..plr.Name.."!!1!!") -- Say Hai!
end)
The only way this will work is you need to have the chat box open, so it won't work in run mode only in play mode. Also, it will only appear as a chat bubble and NOT in the chat box, I'm not sure if it is possible to do that from client/server side scripts.
This discussion is preserved as it was. New answers, comments, and votes are closed.
4 comments
Do you mean like making an npc chat, making a player chat, or making a custom chat?
I mean I want it to show in chatbox when you hit the chat button.
So you mean like a gui...when a player enters input and press "chat", it shows up as actual chat?
Oh, your chatbox is broken. They only way you could have done that is by literally going into chat settings and either disabling whatever it would be or deleted a script. Sorry, but I don't know how to help.