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 » Scripting Helpers
Home Search
 

Re: This script won't work. Help

Previous Thread :: Next Thread 
Houston694 is not online. Houston694
Joined: 15 Dec 2013
Total Posts: 21
21 Dec 2013 08:09 PM
b = script.Parent.Parent.Buttons.Value
bb = script.Parent.Parent.ButtonsBought.Value
while b > bb do
if bb ~= 0 then
script.Parent.Name = "Progress: ".. b/bb*100 .."% Completed!"
elseif bb == 0 then
script.Parent.Name = "Progress: 0% Completed!"
wait(1)
end
end
Here is the layout of the game(only things necessary):
game
Workspace
Tycoon
Factory
ButtonsBought
Buttons
Progress: 0% Completed!
script
Report Abuse
Houston694 is not online. Houston694
Joined: 15 Dec 2013
Total Posts: 21
21 Dec 2013 08:17 PM
bump
Report Abuse
MidnightBuilder23 is not online. MidnightBuilder23
Joined: 20 Dec 2013
Total Posts: 759
21 Dec 2013 08:27 PM
What parts are not working
Report Abuse
Houston694 is not online. Houston694
Joined: 15 Dec 2013
Total Posts: 21
21 Dec 2013 08:38 PM
I'm trying to get it to display how close a player is to completion of a tycoon, it will display the "Progress: 0% Completed!" but after I touch a button (adding 1 to buttons bought) the percentage will not go up.
Report Abuse
lightpower26 is not online. lightpower26
Joined: 26 Apr 2012
Total Posts: 1046
21 Dec 2013 08:51 PM
Here's an idea but it might not work so you might not use it. it uses a number value

while true do
Percent = game. Work space .Percent
script.Parent.Name = "Progress: # .. Percent.Value .. ## Completed!#
end

it should work if not then edit it some and in each button add these lines of code:

Percent = game. Work space .Percent
function hit()--this is probably already in the script but if not it's here anyway
Percent.Value + 1
end

script.Parent.hit: connect (hit)
Report Abuse
MidnightBuilder23 is not online. MidnightBuilder23
Joined: 20 Dec 2013
Total Posts: 759
21 Dec 2013 10:07 PM
As @above said, you're probably not incrementing the value of b, and bb
Report Abuse
XtremeTemper is not online. XtremeTemper
Joined: 02 Mar 2012
Total Posts: 1774
21 Dec 2013 10:10 PM
Could I have a look at the script for the button? I think I may know the problem.
Report Abuse
Houston694 is not online. Houston694
Joined: 15 Dec 2013
Total Posts: 21
22 Dec 2013 04:43 PM
i got it figured out nvm
Report Abuse
Previous Thread :: Next Thread 
Page 1 of 1
 
 
ROBLOX Forum » Game Creation and Development » Scripting Helpers
   
 
   
  • 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