|
| 29 Oct 2014 10:50 PM |
So I am working a completely custom chat gui, from one player to another. Now, I have come across this one issue, which I usually fix by making it a global variable, but is refusing to work right now. The output is ...LocalScript: 11: Attempt to Index Field 'fr' (a nil value!) heres the lines leading up to line 11: typed = false print("RUNNING ".. script.Parent.Name .." function script.") _G.fr = script.Parent.Parent:findFirstChild("body") script.Parent.FocusLost:connect(function(t) print("Focus Lost") if typed == false then print("typed = false") if t == true then print("Focus is definitly lost.") typed = true for _,v in pairs(_G.fr:getChildren("TextLabel")) do
if you want more, i may or may not post the rest. I don't think you need more though. |
|
|
| Report Abuse |
|
|
|
| 29 Oct 2014 10:53 PM |
show me where you declare _G.fr and also is the declaration in a script or localscript? the environments are different.
semicolons are love, semicolons are life |
|
|
| Report Abuse |
|
|
|
| 29 Oct 2014 11:00 PM |
third line,under: typed = false print("RUNNING ".. script.Parent.Name .." function script.") and yeah, i know they are different, this doesn't work online, but does on studio. Local Script. I don't get why it won't work. |
|
|
| Report Abuse |
|
|