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

Roblox Studio Crashing With This Script?

Asked by 10 years ago

Hello!

I would just require a little bit of help please :)

I have a script but it seems to be crashing. There is no error code because my roblox studio crashes ;/

Code:

screen = script.Parent.Decal
while true do
    if game.Workspace.A.Zig.Value == false then
    screen.Texture = "http://www.roblox.com/asset/?id=162925348"
    else    
    if game.Workspace.A.Zig.Value == true then


     screen.Texture = "http://www.roblox.com/asset/?id=162925339"

end 
    end
end 

Yes, I have checked my workspace in the parents.

Please help asap!

Thanks!

Best regards, Nathan.

1 answer

Log in to vote
0
Answered by 10 years ago

When you use while true do loop, YOU MUST use wait() even if it's blank or else it will do it so fast and simultaneously that it will crash!

0
Thanks! :) WelpNathan 307 — 10y
Ad

Answer this question