janthran
|
  |
| Joined: 15 May 2009 |
| Total Posts: 17429 |
|
|
| 28 Aug 2013 09:23 PM |
Why is it that you can set print as a variable, but not FindFirstChild?
local find=FindFirstChild local p=print if Workspace:find("Baseplate") then p("hi") end >find is not a valid member of Workspace
local find=FindFirstChild local p=print if Workspace:FindFirstChild("Baseplate") then p("hi") end >hi |
|
|
| Report Abuse |
|
|
|
| 28 Aug 2013 09:31 PM |
FindFirstChild is a method, not a function...
http://wiki.roblox.com/index.php/User:ElectricBlaze |
|
|
| Report Abuse |
|
|
|
| 28 Aug 2013 09:31 PM |
| print is a function findfirstchild is a method. |
|
|
| Report Abuse |
|
|
|
| 28 Aug 2013 09:37 PM |
>:( He beat me to it.
http://wiki.roblox.com/index.php/User:Aeacus |
|
|
| Report Abuse |
|
|
129K
|
  |
| Joined: 23 Aug 2011 |
| Total Posts: 19010 |
|
|
| 28 Aug 2013 11:02 PM |
| "FindFirstChild" would return nil, as it's not in the environment. Functions on the other hand are in the environment. |
|
|
| Report Abuse |
|
|
janthran
|
  |
| Joined: 15 May 2009 |
| Total Posts: 17429 |
|
| |
|