Why isn't this script working?

Hello!

I just started learning to script very recently and I’ve been using Lua learning on Roblox, the script in my game looks basically identical to the one in Lua learning. I have done this script before and it was working fine, than I decided to try it again but it doesn’t work.

p.s the script is for a chat welcomer

game.StarterGui:SetCore(“ChatMakeSystemMessage”, {
Text = “Welcome”;
Color = Color3.new(255, 221, 0);
Font = Enum.Font.SourceSansBold;
FontSize = Enum.FontSize.Size24;
})

1 Like

The quotes you were using on the script was different.

Don’t use “ , use " instead.

Remember to put that script in a LocalScript too.

It is local script and I only have " quotes. there is no alternative :expressionless:

yeah, but the script above returned this:
18:54:22.811 - Players.DevHumor.PlayerScripts.LocalScript:12: Unexpected Unicode character: U+201c. Did you mean '"'?

Are you getting any errors in your output?

i don’t think anything related to the script

Try putting the LocalScript in Game.StarterPlayer.StarterPlayerScripts

Could we see the full script? Since the error may be outside of the 6 lines provided.

That is the whole script lol

30charrrrrrsssssss

The errors he posted are not related to his code.

I never said they were related, but thanks for clarifying that.

This code worked once before, but when I tried it again it didn’t work. I had a few spelling mistakes but i fixed those, but it still wont work.

Here is your updated code:

game.StarterGui:SetCore("ChatMakeSystemMessage", {
Text = "Welcome";
Color = Color3.new(255, 221, 0);
Font = Enum.Font.SourceSansBold;
FontSize = Enum.FontSize.Size24;
})

You were not formatting strings correctly. @DevHumor was correct.

1 Like

That’s just how the forum formats quotes. The issue was that CRISPEY didn’t use a code block, not that they were using the wrong kind of quote. You can try typing two quotes in a normal post like this:
“”
^ … and you can see those are automatically turned to smart quotes. (Here’s what it looks like in the editor: image )

2 Likes

how do I get the different quotes then? because i cant see any different ones…

I put the code shown below in a LocalScript in StarterPlayerScripts and it worked fine for me.

game.StarterGui:SetCore("ChatMakeSystemMessage", {
Text = "Welcome";
Color = Color3.new(255, 221, 0);
Font = Enum.Font.SourceSansBold;
FontSize = Enum.FontSize.Size24;
})

The quotes have not changed, the script still does not work.

Oh my god I am so dumb…

I put the script in StarterPlayer not in StarterPlayerScripts… 0_0