Paingred
|
  |
| Joined: 23 Oct 2008 |
| Total Posts: 1138 |
|
|
| 21 Sep 2011 12:48 AM |
| I'm now trying to take it up a bit and make a disco floor, but I have no idea how to randomize brickcolor! Is it possible? If so, someone please tell me how! |
|
|
| Report Abuse |
|
|
|
| 21 Sep 2011 12:52 AM |
| BrickColor.new(Color3.new(math.random(0,255)/255,math.random(0,255)/255,math.random(0,255)/255)) |
|
|
| Report Abuse |
|
|
Paingred
|
  |
| Joined: 23 Oct 2008 |
| Total Posts: 1138 |
|
| |
|
Paingred
|
  |
| Joined: 23 Oct 2008 |
| Total Posts: 1138 |
|
|
| 21 Sep 2011 12:57 AM |
No, that doesn't work... Maybe I should leave randomising for when i'm more experienced... |
|
|
| Report Abuse |
|
|
|
| 21 Sep 2011 12:59 AM |
| what do you mean it doesn't work? |
|
|
| Report Abuse |
|
|
Paingred
|
  |
| Joined: 23 Oct 2008 |
| Total Posts: 1138 |
|
|
| 21 Sep 2011 03:06 AM |
| i put it in the brick, and the brickcolor wasn't changing! |
|
|
| Report Abuse |
|
|
|
| 21 Sep 2011 09:43 AM |
You did put:
script.Parent.BrickColor.new(Color3.new(math.random(0,255)/255,math.random(0,255)/255,math.random(0,255)/255))
In it right? Don't mean to be insulting, I just don't know your scripting knowledge level.
CyberHusk Productions - CEO |
|
|
| Report Abuse |
|
|
grimm343
|
  |
| Joined: 18 Sep 2008 |
| Total Posts: 2796 |
|
|
| 21 Sep 2011 09:52 AM |
It may be easier to do sometihng a little smaller. :o
db = true script.Parent.Touched:connect(function(hit) if not db then return end db = false local plr = game.Players:GetPlayerFromCharacter(hit.Parent) if plr then script.Parent.BrickColor = BrickColor.Random() end wait(0.5) db = true end)
Put this text as the source of a script (contents).
Drag that script into the brick you want to change colors.
Whenever a player walks into it, it will change to a random color. |
|
|
| Report Abuse |
|
|
grimm343
|
  |
| Joined: 18 Sep 2008 |
| Total Posts: 2796 |
|
|
| 21 Sep 2011 09:53 AM |
something*
Also, by smaller, I meant this part..
script.Parent.BrickColor = BrickColor.Random() |
|
|
| Report Abuse |
|
|