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 have I done wrong?

Previous Thread :: Next Thread 
BluecoatAlex is not online. BluecoatAlex
Joined: 05 Jul 2016
Total Posts: 551
17 Apr 2017 03:41 PM
function onClicked(playerWhoClicked)
if check ~= nil then

local user = game.Players:GetPlayerFromCharacter(MouseClick.Parent)
local stats = user:findFirstChild("leaderstats") --Find moneyholder

if stats ~= nil then --If moneyholder exists then
local cash = stats:findFirstChild("Tokens") --Get money
cash.Value = cash.Value -1
wait(0.1)
end

ting = 0
end

end

script.Parent.Touched:connect(onClicked)

I have added a click detector and I have a leaderboard for cash all link up with Tokens.
Report Abuse
NilLogic is not online. NilLogic
Joined: 08 Apr 2016
Total Posts: 1369
17 Apr 2017 03:41 PM
The link below should answer your question, I hope I helped you.

https://en.help.roblox.com/hc/en-us/articles/203312820-Problem-Logging-Out-or-Logging-In

I'm just a friendly bot, please dont hate.
https://www.roblox.com/My/Groups.aspx?gid=3201548
Report Abuse
BluecoatAlex is not online. BluecoatAlex
Joined: 05 Jul 2016
Total Posts: 551
17 Apr 2017 03:41 PM
bump..
Report Abuse
seanconnoll is not online. seanconnoll
Joined: 27 Sep 2010
Total Posts: 2365
17 Apr 2017 03:42 PM
nillogic is a bot. dont listen to him


Report Abuse
BluecoatAlex is not online. BluecoatAlex
Joined: 05 Jul 2016
Total Posts: 551
17 Apr 2017 03:43 PM
bump
Report Abuse
BlackScorpyon04 is not online. BlackScorpyon04
Joined: 24 Jul 2015
Total Posts: 128
17 Apr 2017 04:15 PM
Whats ting ??
Report Abuse
BlackScorpyon04 is not online. BlackScorpyon04
Joined: 24 Jul 2015
Total Posts: 128
17 Apr 2017 04:35 PM
this script worked for me

script.Parent.ClickDetector.mouseClick:connect(function(playerWhoClicked)

local user = playerWhoClicked
local stats = user:findFirstChild("leaderstats") --Find moneyholder
if stats ~= nil then
local cash = stats:findFirstChild("Tokens") --Get money
cash.Value = cash.Value -1
wait(0.1)
end

ting = 0
end)



Hope it helps
Report Abuse
BluecoatAlex is not online. BluecoatAlex
Joined: 05 Jul 2016
Total Posts: 551
18 Apr 2017 05:04 AM
thanks!


https://www.roblox.com/catalog/?CatalogContext=1&Subcategory=19&SortType=3&SortAggregation=5&IncludeNotForSale=true&LegendExpanded=true&Category=11
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