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

Faces won't change in my team face script?

so i made a script that changes the face of the player when they are in a specific team but it won't work. help!

local plr = game.Players.LocalPlayer
local char = plr.Character
local face = char.Head.face
local vface = 1044179525
local sface = 111523405
if plr.TeamColor == "Really Red" then
	face.Texture = "rbxassetid://"..vface
elseif plr.TeamColor == "Bright Blue" then
	face.Texture = "rbxassetid://"..sface
end

2 comments

0

??

0

memz

1 answer

Lua is case sensitive about the colors in ROBLOX. The actual colors are called "Really red", not "Really Red" and "Bright blue" instead of "Bright Blue" like you had. Make sure to look at the colors and match the names so that the capitalization is correct.

EDIT: Be sure to also add BrickColor.new() if you are using strings as color names.

local plr = game.Players.LocalPlayer
local char = plr.Character
local face = char.Head.face
local vface = 1044179525
local sface = 111523405
if plr.TeamColor == BrickColor.new("Really red") then --Changed from Really Red
    face.Texture = "rbxassetid://"..vface
elseif plr.TeamColor == BrickColor.new("Bright blue") then --Changed from Bright Blue
    face.Texture = "rbxassetid://"..sface
end

2 comments

0

Hmm. This doesn't really work... But i don't see any errors.

0

Is this script local?

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