Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Trying to randomize the torso brickcolor of my character. How do I do this?

Asked by 2 years ago

So I have a starter character, and I'm trying to make it so every time you spawn in, you get a different torso color. I know this is a really basic thing, but I cant seem to get it.

Please help. (note: script is child to the torso)

local Torso = script.Parent.Parent.Torso
Torso.BrickColor = nil
Torso.BrickColor = BrickColor.Random()
0
ur script is correct, except that BrickColor.Random() should be BrickColor.random() T3_MasterGamer 2189 — 2y

1 answer

Log in to vote
0
Answered by 2 years ago

Hi, just use Bricolor.pallette like so

local random = math.random(1,27)
local Torso = game.Workspace.Part -- wherever your torso is
Torso.BrickColor = BrickColor.palette(random)
print(random)

dont go above 27

hope this helps

0
it worked! Also figured out I had to put the script in starter character scripts. Thanks! larssnakes 24 — 2y
Ad

Answer this question