What's wrong with this Codes GUI script!?

Hello. I really need help with this script. I payed attention to all the scripts I made for my Codes GUI, and I don’t understand or find what’s the issue. I’m trying to fix it deleting or changing things, but… I dunno:


If anybody can help me, it would be great have some help. Thank you.

Where’s your client code? Can we see that? That would be helpful

Also, I would advise you to not send screenshots of your code and instead format it correctly with the three backticks (```), it will be easier for us to read and help you

2 Likes

I’m a really noob scripter (I know, If I’m noob I shouldn’t make this kind of scripts) and I don’t know what’s the client code. It’s like the principal script or…?

Your cash value seems like nil.

Nil means unknown.

add print(cash) to see what it prints.
And make sure the client sided script sends the cash as number.

2 Likes

It’s where you fired the code from,

As a sidenote: do NOT do something like this!
An exploiter can just fire this event, and get free cash with the cash variable

1 Like

How though? It’s a script and clients can’t access it.

This probably won’t answer your question, but you dont have to say:

player.leaderstats.Cash.Value = player.leaderstats.Cash.Value + cash

Instead you can say:

player.leaderstats.Cash.Value += cash

And can we see the script where you fired the remote event from.

game.ReplicatedStorage.TwitterCodes:FireServer(9e9)
1 Like

You put an “e” in the argument. Just remove the “e”.

9e9 means 9 with 9 zeroes (9,000,000,000)

1 Like

Yeah I know, but I don’t think roblox supports that.