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
 

Can someone help me fix this script

Previous Thread :: Next Thread 
LifelessCreator is not online. LifelessCreator
Joined: 02 Jun 2012
Total Posts: 75
26 Jan 2017 06:17 PM
Sorry, I'm new to scripting and i was wondering what i did wrong, I've tried everything!

Its a money giver command, also affected by a game pass if you have it.

amount = 10 -- This variable is the amount of cash we will give each time.
timedelay = 30 -- This variable is the amount of seconds inbetween each time the cash is rewarded
currencyname = "Cash" -- This is the name of our Currency
id = 626428513

while true do

wait(timedelay)

for i,v in pairs(game.Players:GetPlayers()) do
if v:FindFirstChild("leaderstats") and v if game:GetService("MarketplaceService"):PlayerOwnsAsset(v,id) then

v.leaderstats[currencyname].Value = v.leaderstats[currencyname].Value + amount * 2
else
v.leaderstats[currencyname].Value = v.leaderstats[currencyname].Value + amount

end
end
end


Report Abuse
OAuth2 is not online. OAuth2
Joined: 27 Nov 2016
Total Posts: 751
26 Jan 2017 06:19 PM
if v:FindFirstChild("leaderstats") and v if game:GetService("MarketplaceService"):PlayerOwnsAsset(v,id) then

to

if v:FindFirstChild("leaderstats") and game:GetService("MarketplaceService"):PlayerOwnsAsset(v,id) then
Report Abuse
LifelessCreator is not online. LifelessCreator
Joined: 02 Jun 2012
Total Posts: 75
26 Jan 2017 06:23 PM
Thanks, thanks so much! it works now


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