I was trying to use FindFirstDescendant() but it gave the error mentioned in the title. Have used this for tons of times and never had a problem with it. I was trying to get descendant of a model.
For now bypassed the issue by using FindFirstChild(whatever, true), but I have many things in my game that use FindFirstDescendant, and it would be a pain in the ass to change them all. What is the issue?
You posted release notes that were 100 releases before. I literally used FindFirstDescendant() Yesterday, and many times before that, and it worked without any issue.
This explains nothing as to why it stopped working now. I also mentioned that I did use findfirstchild with recursive, but that it is not a solution for me.
I’ve ran into this problem before apparently this is a disabled or none active feature it took me some time to look and I saw people on the devforum talk about how it’s not a working feature yet is this true? I don’t have any other evidence it’s not ready yet
Stop referencing old topics. If you read the post fully you would see that literally yesterday it was working, and I did use findfirstchild with a recursive.
Find me any page in documentation that says “This Works”. Things that DO NOT work should be specifically marked as such, as deprecated or something else.
I did some searching around, and it seems like a pretty odd situation. Stumbled on this thread due to getting the same error. Nothing in the method’s documentation shows that it’s not functional in any way, but no results came up on actually making it work. I took other’s advice in this thread and used Instance:FindFirstChild(name, true) instead. If you’ve had :FindFirstDescendant in scripts before, I’d recommend just using the replace all functionality to quickly swap all of them out for the recommended method.
I know you posted it like a year ago but you can replace it with a function.
function FindFirstDescendant(obj, child, parent, is)
for _, objs in pairs(obj:GetDescendants()) do
print(objs)
if objs.Name == child then
if is then
if not objs:IsA(is) then return end
end
if parent then
if objs.Parent.Name ~= parent then return end
end
print(objs.Name.." Found")
return objs
end
end
end
i added in some extra parameters (is, parent) so i can truely make sure the object im searching for matches
Will we ever be able to just use FindFirstDescendant? I’m already using the recursive parameter from FindFirstChild, but personally it just looks cleaner to have it as FindFirstDescendant("Name") than FindFirstChild("Name", true).