|
| 10 Sep 2013 09:09 PM |
plyr = game.Players.LocalPlayer Cash = script.Parent.Parent.Parent.Parent.Parent.Parent.leaderstats.Points
function onClick() if Cash.Value >= 10 then Cash.Value = Cash.Value - 0 script.Parent.Parent.Parent.Parent.Parent.SwordGui.Frame.Frame.CurrentSword.Text = "Riptide" end end
script.Parent.MouseButton1Click:connect(onClick)
The parenting is correct for sure, I checked it 3 or 4 times. I dont see a problem. Does anyone else? There is nothing in the output, Or Remote Monitoring System. |
|
|
| Report Abuse |
|
|
|
| 10 Sep 2013 09:10 PM |
"Cash.Value = Cash.Value - 0"
Why is this here? |
|
|
| Report Abuse |
|
|
|
| 10 Sep 2013 09:12 PM |
| Idk, I copied it from another script the gui, So I just kept it there. |
|
|
| Report Abuse |
|
|
ZachBloxx
|
  |
| Joined: 26 Jun 2013 |
| Total Posts: 2833 |
|
|
| 10 Sep 2013 09:19 PM |
| This is in a LocalScript, right? |
|
|
| Report Abuse |
|
|
| |
|
ZachBloxx
|
  |
| Joined: 26 Jun 2013 |
| Total Posts: 2833 |
|
|
| 10 Sep 2013 09:26 PM |
Then why don't you just do:
local plyr = game.Players.LocalPlayer local Cash = plyr.leaderstats.Points |
|
|
| Report Abuse |
|
|
| |
|
|
| 10 Sep 2013 09:30 PM |
| The if statement is most likely not following the condition. Try adding else print("ErrorFixed") to check. |
|
|
| Report Abuse |
|
|
| |
|
|
| 10 Sep 2013 09:38 PM |
| Is the script enabled, or is it in a service that doesn't run scripts such as lighting? |
|
|
| Report Abuse |
|
|
|
| 10 Sep 2013 09:39 PM |
| That was a stupid question of mine. |
|
|
| Report Abuse |
|
|
|
| 10 Sep 2013 09:41 PM |
| Is it a textbutton that you are applying the MouseButton1Click event to? |
|
|
| Report Abuse |
|
|