if game.Workspace.setup.Value == 1 then is running when value is 0. whats going on?
so. I have made a script to clone spheres.
question 1: do the scripts of clones run when created?
question 2: if not, how do you make it run?
question3: so the script, first when the game runs then a setup part of the script runs, NOT the script I want the clones to have. when the clones are created, sometimes in output I get the message "sphere setup started" and that's the exact opposite of what its supposed to do. whyyyyy?
here is me code:
01 | local sphere = script.Parent |
02 | local setup = game.Workspace.setup |
03 | if setup.Value = = 1 then |
05 | print ( "sphere setup started" ) |
06 | sphere.Transparency = 1 |
09 | print ( "creating sphere..." ) |
10 | cloned = sphere:Clone() |
11 | cloned.Parent = sphere.Parent |
12 | print ( "creating sphere..." ) |
15 | if setup.Value = = 0 then |
16 | sphere.Transparency = 0 |
17 | print ( "sphere created" ) |