Hello! so i made a local script that is suposed to define “gui”, gui is located in the same folder as the script , so im doing , local gui = script.Parent:WaitForChild(“GUIScript”) but it say inf yield possible, if i dont put wait for child it just say it does not exist, but thats false, look
I guess it’s going to be better if you first define the folder variable then define the gui
ill try that , but im not sure that it will work, it should rn
still not working, with defined folder
one more thing you want to get the gui or the script only?
the gui, but it block on the script
this script Should Find The Gui for you without problem
for i,v in pairs(script.Parent:GetChildren()) do
if v:IsA("LocalScript") then
if v.Name == "GUIscript" then
local GUI = v:FindFirstChild("GUI")
end
end
end
alright, trying this code to see…
you can add a print()
function after this line so it would be easier to findout
its working now the thing is now it blocks on everything now , but it works on another script that is literally the same one
just replcae the ends to the end of your script
no like, your block of code is working, but now my code isnt able to locate (everything)
oh, can you record a video or take a screen shot?
sure, ill take a gyzao and link it
Looking at your code it seems you did this
local gui = script.Parent.WaitForChild("GUIScript")
whereas it should be a colon
local gui = script.Parent:WaitForChild("GUIScript")
so see, in it we can see that i can reload the small gun but not the big one
https://gyazo.com/2e4017bd56209c9024ba16f64b954af7
If he did this one wrong he shouldn’t even get infinite yield in output
No just a typo on the picture, it say infinite yield
hmm, is the script of the big gun is inside that local script or the one that you had the problem?
The one that is not working is the SKS (big gun)