Scripting HelpersARCHIVE
A little piece of Roblox history. Preserved for everyone, one question at a time.Read about the archive →
COMMUNITY QUESTION

Variable not found?

Waiting = 22
VRC = script.VR:Clone() --VR is name of second script
VRC.Parent = Workspace
wait(.5+Waiting)
VRC.Disabled = false

Second script

Te.VR = game.Workspace.VR
if not TeVR then
break
end--Script disabled

Incase this helps I am bad at making errors, my output is broken, because it will not show errors..

2 comments

0

Why is there a period where you name the variable in your second script?

0

-_- Yeah, I knew that Incase this helps thing would be right, thanks.

1 answer

First off the output is saying there is no loop to break in the VR so I don't know if you have more code there. http://prntscr.com/7x93pm

Everything else worked for me.

First Script I made the waiting time a little bit shorter for testing purposes

Waiting = 1

VRC = script.Parent.VR:Clone() --VR is name of second script

VRC.Parent = game.Workspace
VRC.Name = "New" -- I used it to see what was happening in the new script, you can remove it
wait(.5+Waiting)

VRC.Disabled = false
print"done"

Copied Script

Te.VR = game.Workspace.VR

if not TeVR then
break -- This part is causing an error.
end--Script disabled

1 comment

0

Alright I changed code to this, still didn't work I removed break and added print("Working")

This discussion is preserved as it was. New answers, comments, and votes are closed.