I have a script that modifies the health of all my divisions. The issue is, they are all in folders, and I have them in there to organize it. It would be much easier if I could have one script with all my locals, and just modify it from there, so I can just make the values of the variables that go across all the scripts.
✓ ANSWER ACCEPTED
Is it possible to have one script with all my locals that would apply to multiple scripts?
1 answer
✓ Accepted answer
In a Server Script you can use Global Values to transfer objects between scripts,
Example:
Script 1:
_G.P = workspace.Part
Script 2
print(_G.P.Name) -- prints the part name "Part"
However, in LocalScripts you need to use RemoteEvents !
Learn about them Here: Click
( You could use Remote Events to make global values to other scripts or just make a script from the Data from the RemoteEvent arguments )
This discussion is preserved as it was. New answers, comments, and votes are closed.

2 comments
_G. defines the value, after that it's the define / name of it. Value of it doesn't really matter!
Alright, thanks, i'll test it out.