generic image
Processing...
  • Games
  • Catalog
  • Develop
  • Robux
  • Search in Players
  • Search in Games
  • Search in Catalog
  • Search in Groups
  • Search in Library
  • Log In
  • Sign Up
  • Games
  • Catalog
  • Develop
  • Robux
   
ROBLOX Forum » Game Creation and Development » Scripters
Home Search
 

Why does this not change the Color3 values value?

Previous Thread :: Next Thread 
haydebug2003 is not online. haydebug2003
Joined: 21 Jan 2012
Total Posts: 5302
04 Jun 2015 06:21 PM
script.Parent.MouseButton1Click:connect(function()
if script.Parent.Parent.NumValue.Value==1 then --Red
script.Parent.Parent.ColorValue.Value=255, 0, 0
script.Parent.Parent.NumValue.Value=2
elseif script.Parent.Parent.NumValue.Value==2 then --Green
script.Parent.Parent.ColorValue.Value=0, 170, 0
script.Parent.Parent.NumValue.Value=3
elseif script.Parent.Parent.NumValue.Value==3 then --Blue
script.Parent.Parent.ColorValue.Value=0, 85, 255
script.Parent.Parent.NumValue.Value=3
elseif script.Parent.Parent.NumValue.Value==4 then --Purple
script.Parent.Parent.ColorValue.Value=0, 0, 255
script.Parent.Parent.NumValue.Value=5
elseif script.Parent.Parent.NumValue.Value==5 then --Yellow
script.Parent.Parent.ColorValue.Value=255, 255, 0
script.Parent.Parent.NumValue.Value=6
elseif script.Parent.Parent.NumValue.Value==6 then --Black
script.Parent.Parent.ColorValue.Value=0, 0, 0
script.Parent.Parent.NumValue.Value=7
elseif script.Parent.Parent.NumValue.Value==7 then --White
script.Parent.Parent.ColorValue.Value=255, 255, 255
script.Parent.Parent.NumValue.Value=1
end
end)

The value is set at one and it doesnt do anything.


http://www.roblox.com/Trade/TradeWindow.aspx?TradePartnerID=23313558
Report Abuse
Dr01d3k4 is not online. Dr01d3k4
Joined: 11 Oct 2007
Total Posts: 17916
04 Jun 2015 06:24 PM
Colour3.new(1, 0, 0)
etc
Report Abuse
nickcool9999 is not online. nickcool9999
Joined: 04 Dec 2007
Total Posts: 1528
04 Jun 2015 06:29 PM
A brick color value has to be assigned as a redundant BrickColor.new(Color3.new(0, 0, 0)). If you assign a brick color that way it will not be accurate 99% of the time and will be an approximation

If you mean of an interface, I don't think there are any interface properties called "Value". If you're looking to declare it as a BackgroundColor3 or a OutlineColor3, you have to use the full name or an abbreviated version that has had its full name referenced before.

i.e.
local value = "BackgroundColor3"
label[value] = Color3.new(0, 0, 0)
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripters
   
 
   
  • About Us
  • Jobs
  • Blog
  • Parents
  • Help
  • Terms
  • Privacy

©2017 Roblox Corporation. Roblox, the Roblox logo, Robux, Bloxy, and Powering Imagination are among our registered and unregistered trademarks in the U.S. and other countries.



Progress
Starting Roblox...
Connecting to Players...
R R

Roblox is now loading. Get ready to play!

R R

You're moments away from getting into the game!

Click here for help

Check Remember my choice and click Launch Application in the dialog box above to join games faster in the future!

Gameplay sponsored by:
Loading 0% - Starting game...
Get more with Builders Club! Join Builders Club
Choose Your Avatar
I have an account
generic image