What is the differnce betwwen FindFirstAncestorWhichIsA() and FindFirstAncestorOfClass()

what is the differnce betwwen FindFirstAncestorWhichIsA() and FindFirstAncestorOfClass()

Not too much. There is one difference, as mentioned in the documentation:

For example, let’s say you have a single child with the class of “Part”. You can use any of these to get that part:

Parent:FindFirstChildWhichIsA("Instance")
Parent:FindFirstChildWhichIsA("PVInstance")
Parent:FindFirstChildWhichIsA("BasePart")
Parent:FindFirstChildWhichIsA("Part")

Parent:FindFirstChildOfClass("Part")

Notice how you can use any classes the part inherits from with FindFirstChildWhichIsA and only the class name with FindFirstChildOfClass.

1 Like