How to filter select parts with nearly identical name with :getchildren()

for this instance say i have 5 parts named:

orange square
green square
blue square
red square
yellow triangle

using a script like this below,
how would i filter it so that I would get only the squares from this table?

Is there something like:

if child.name has “square” in its name then

for _, child in ipairs(leader:GetChildren()) do
	
	
end
1 Like

yes there is its string.find im dumb

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.