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: What's wrong?

Previous Thread :: Next Thread 
Ryloxx is not online. Ryloxx
Joined: 20 Sep 2011
Total Posts: 112
16 Aug 2015 06:50 PM
I'm not getting any errors, but the brick's color won't change even though my money value is below Price's value. Any ideas?


owner = script.Parent.Parent.OwnerName.Value

local thisplr = game.Players:findFirstChild(owner)
if (thisplr~=nil) then
local stats = thisplr:findFirstChild("leaderstats")
if (stats~=nil) then
local score = stats:findFirstChild("Money")
if (score~=nil) then
if score.value > (script.Parent.Price) then
script.Parent.BrickColor = BrickColor.new(1020)
else
if score.value ==(script.Parent.Price) then
script.Parent.BrickColor = BrickColor.new(1020)
else
if score.value < (script.Parent.Price) then
script.Parent.BrickColor = BrickColor.new(1004)
end
end
end
end
end
end

(Sorry for the messed up formatting)
Report Abuse
Ryloxx is not online. Ryloxx
Joined: 20 Sep 2011
Total Posts: 112
16 Aug 2015 06:52 PM
I should note, I added .Value to the end of all of the times I called script.Parent.Price, but still it's not working. No errors in the feedback, but nothing is happening.
Report Abuse
TimeTicks is not online. TimeTicks
Joined: 27 Apr 2011
Total Posts: 27115
16 Aug 2015 06:52 PM
put prints wherever you think problems are


"Talk is cheap. Show me the code." - Linus Torvalds
Report Abuse
Ryloxx is not online. Ryloxx
Joined: 20 Sep 2011
Total Posts: 112
16 Aug 2015 06:59 PM
The script doesn't make it past Line Three, however I have no idea what's wrong there. Anyone have any ideas?
Report Abuse
EmsyThorne is not online. EmsyThorne
Joined: 07 May 2015
Total Posts: 183
16 Aug 2015 07:06 PM
You got anything to start the script? A function etc.?
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