I gain coins in 1 script and try to buy a thing using a 2nd script but when I check if the player has enough coins in the 2nd script to buy the thing it comes back as 0 meaning the 2nd script thinks the number of coins the player has is 0 even though the gui on the screen the player has enough coins to buy the thing (im using local gui stuff so that could have something to do with it but idk)
#How to save a number that's changing in a script to a different script
1 messages · Page 1 of 1 (latest)
from what i see, you’re changing text in client, and checking the text on the server, but what the client sees isnt actually what the server sees, so you need to replicate it to the server using remote events to change it
basically you have to change the text in a server script instead of a local one
which you'd od with remotes
Does it check it even if they r both local scripts?