Attempt to index nil with 'FindFirstChild'

Because it updates depending on a stat a player has called Multiplier, and it changes in the game. So the formula has to update every time

1 Like

Yes it is, the problem doesn’t come around here apparently

1 Like

Then use RunService instead of yielding the whole script with a loop

1 Like

Okay, by the way you said that I shouldn’t put these types of script in the Workspace, then where do you think I should put them?

1 Like

It doesn’t actually matter. You can put it in ServerSctiptService, but it’s purely aesthetic.

1 Like

small correction, I’d avoid placing scripts in workspace unless they really need to, simply because most scripts don’t need to be replicated to the client. (the name, classname etc, i am aware source isnt replicated)

1 Like

Okay so I took the advice of everyone but I’m facing an issue.
The script doesn’t give the cash to the player but it works, basically I tell the script to give cash depending on a numbervalue placed in the Workspace, but I don’t know why, this number value is equal to 0 for the game. Lemme show you:

I made a script that print’s the NumberValue’s Value:
print(game.Workspace["Usefull Informations"].DevProducts.Cash.Cash1.Value)

And here is the number value in game:

It prints out 0, I don’t know why. How could I fix that?

1 Like

Could you send your scripts as they currently are and I’ll give you the fix? Just so I don’t need to piece together what changes have/haven’t been made.


It won’t really be replicated to the client. The ‘Script’ object will, but only as a hollow shell comprised of a Name, ClassName, LinkedSource, and Disabled property. It will take up so little data that it won’t matter. The source of the script (which takes up far more space) won’t be replicated because server side script sources are never sent to the client.

1 Like

I made a new topic that covers my new problem here: Printing out a NumberValue that changes doesn't work - #4 by FlyingFrets

2 Likes