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
 

Re: How do I get the value of a bricks x value

Previous Thread :: Next Thread 
Raildex is not online. Raildex
Joined: 06 Dec 2009
Total Posts: 934
03 Feb 2016 08:10 AM
I want to assign a bricks color to the value of its x Position, how can I get this.
Report Abuse
128Gigabytes is online. 128Gigabytes
Joined: 17 Apr 2014
Total Posts: 3616
03 Feb 2016 08:14 AM
This question makes no sense at all .
Report Abuse
NovusTheory is not online. NovusTheory
Joined: 14 Oct 2009
Total Posts: 4532
03 Feb 2016 08:15 AM
BrickColor.Color

Convert each one to a Vector3

@128Gig

It actually does make sense because I see why he would use it
Report Abuse
Raildex is not online. Raildex
Joined: 06 Dec 2009
Total Posts: 934
03 Feb 2016 08:18 AM
local part = script.Parent

local x

while true do
x = part.Position
part.BrickColor = BrickColor.new(Color3.new(x))
wait()
end

this is kinda what im going for^
Report Abuse
128Gigabytes is online. 128Gigabytes
Joined: 17 Apr 2014
Total Posts: 3616
03 Feb 2016 08:19 AM
The question makes no sense because I don't see what he wants not because I don't see why.
And I don't think why you posted is what he wants.

He wants a bircks color to be equal to its position on the x axis

You told him how to get the Color3 of a BrickColor?
Report Abuse
Raildex is not online. Raildex
Joined: 06 Dec 2009
Total Posts: 934
03 Feb 2016 08:20 AM
Im mainly just making this to test some stuff and learn more about scripting
Report Abuse
128Gigabytes is online. 128Gigabytes
Joined: 17 Apr 2014
Total Posts: 3616
03 Feb 2016 08:23 AM
Why did you say its x position if you wanted its position

Also brickColors given a color3 will round to the nearest BrickColor you can't just use any color you want.
Report Abuse
NovusTheory is not online. NovusTheory
Joined: 14 Oct 2009
Total Posts: 4532
03 Feb 2016 08:24 AM
128 I told him to get the Color3 of a brick color and change the parts position (x) to the Color3

(This case Color3.r)

Report Abuse
128Gigabytes is online. 128Gigabytes
Joined: 17 Apr 2014
Total Posts: 3616
03 Feb 2016 08:26 AM
Thats not what he wanred because thats not what he said and you posted it because you were guessing at what he wanted because the question didn't make sense.
Report Abuse
Raildex is not online. Raildex
Joined: 06 Dec 2009
Total Posts: 934
03 Feb 2016 08:28 AM
Sorry I wasnt thinking in terms of RGB when I titled the post, my original plan was to create the color based on the parts position, I was going to set each of the vectors to a variale and then have them as the color ints
Report Abuse
NovusTheory is not online. NovusTheory
Joined: 14 Oct 2009
Total Posts: 4532
03 Feb 2016 08:29 AM
@Raildex

You said it the other way.....
Report Abuse
128Gigabytes is online. 128Gigabytes
Joined: 17 Apr 2014
Total Posts: 3616
03 Feb 2016 08:33 AM
No, he didn't

"I want to assign a bricks color" So already you saying he wanted to set the position is wrong.
" to the value of its x Position, " So he wants to assign the BrickColor to the parts Position.X
Report Abuse
NovusTheory is not online. NovusTheory
Joined: 14 Oct 2009
Total Posts: 4532
03 Feb 2016 08:39 AM
wtf I read it wrong then
Report Abuse
Raildex is not online. Raildex
Joined: 06 Dec 2009
Total Posts: 934
03 Feb 2016 08:39 AM
local part = script.Parent

local x
local y
local z

while true do
x = part.Position.X
y = part.Position.Y
z = part.Position.Z
part.BrickColor = BrickColor.new(Color3.new(x,y,z))
wait()
end

am I getting any closer here?^
Report Abuse
NovusTheory is not online. NovusTheory
Joined: 14 Oct 2009
Total Posts: 4532
03 Feb 2016 08:56 AM
math.floor them
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