Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

Everyone in the server can hear the music why?

Asked by 5 years ago

I'm making a loading screen but everyone can hear the music even those not on the loading screen what do I do?

01local function playerAdded(player)
02    wait(2)
03    script.Parent.Text = "loading."
04    script.Parent.Parent.TextButton.LocalScript.LoadingScreen.Playing = true
05    wait(.7)
06    script.Parent.Text = "loading.."
07    wait(.7)
08    script.Parent.Text = "loading..."
09    wait(.7)
10    script.Parent.Text = "loading"
11    wait(.7)
12    script.Parent.Text = "loading."
13    wait(.7)
14    script.Parent.Text = "loading.."
15    wait(.7)
View all 82 lines...

1 answer

Log in to vote
0
Answered by 5 years ago

Instead of making the loading screen invisible, destroy it so others cannot activate the audio.

This issue occurs because it is a regular script and not a localscript.

01local function playerAdded(player)
02    wait(2)
03    script.Parent.Text = "loading."
04    script.Parent.Parent.TextButton.LocalScript.LoadingScreen.Playing = true
05    wait(.7)
06    script.Parent.Text = "loading.."
07    wait(.7)
08    script.Parent.Text = "loading..."
09    wait(.7)
10    script.Parent.Text = "loading"
11    wait(.7)
12    script.Parent.Text = "loading."
13    wait(.7)
14    script.Parent.Text = "loading.."
15    wait(.7)
View all 80 lines...

This should fix it.

0
Please incorporate a for loop to help him make more efficient code Ziffixture 6913 — 5y
0
they didn't ask for a loop. TheMaster9245 41 — 5y
Ad

Answer this question