Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Why wont my Color change script work?? It Says color3 and Something about a string

it wont work it just errors in output saying argument #3 to 'Color' (Color3 expected, got string)

local player = game:GetService("Players").LocalPlayer
local button = script.Parent 

button.Activated:Connect(function()
    local char = player.Character
    local UpperTorsoColor = char.UpperTorso.color

    local UpperTorsoColor = char.UpperTorso.color ~= '0, 0, 255'
end)

2 comments

0

You need to do A LOT of research. Don't know why you're using Color3 when you can use BrickColor and don't know why you're confusing yourself by setting it = to eachother for the 2n'd time

0

.

2 answers

You need to do A LOT of research. Don't know why you're using Color3 when you can use BrickColor and don't know why you're confusing yourself by setting it = to each other for the 2n'd time

local player = game:GetService("Players").LocalPlayer
local button = script.Parent 

button.Activated:Connect(function()
    local char = player.Character
    local UpperTorsoColor = char.UpperTorso.Color

    local UpperTorsoColor = Color3.new(0, 0, 255)
end)

Hope this helps, I don't use Color3 a lot so if it has an error, you know why.

7 comments

0

i never said i was using color3

0

.

0

The please explain to me what "color" is

0

Color in the properties menu, is Color3 luv. In case you didn't know, it uses 3 different measurments of RGB that's why it's 3. You really need to read a scripting book or something, I'm sorry.

0

Anyway if the script works put it as the answer, or I'll have to report this post.

0

why??? would you have to report it

0

and this script didnt work at all i am trying to color a brick in the character...

Unfortunately, JayShepherdMD's answer wont work, the code is wrong.

Here's my version.

local player =game:GetService("Players").LocalPlayer
local button =script.Parent 

button.Activated:Connect(function()
    local char =player.Character
    char.UpperTorso.Color =Color3.new(0,0,255)
end)

Hope it helps. If it doesn't, tell me and I'll rewrite it.

This discussion is preserved as it was. New answers, comments, and votes are closed.