Hello i need help with a character customization script, Hair,Shirt,Pants everything works except changing the Skin, i keep getting “(self: Instance, name: string, recusrive: boolean?) → Instance” Could this be the problem? No error in output or anything
1 Like
it may seem tricky, but it’s wrong because of how you’re checking for hair
if (FoundInstance and String ~= "Hair") then
elseif String == "Skin" then
end
...
-- Read it like this instead
if String ~= "Hair" then -- If String is not "Hair" then; Otherwise String is "Hair"
elseif String == "Skin" then -- the elseif means String is "Hair" (elseif "Hair" == "Skin" cannot be compared)
end
edit: the (self: Instance, name: string, recursive: boolean?) -> Instance
text is from hovering over :FindFirstChild()
Are you using the strict typechecker?
Try changing the type of ChangeName to comply with “Skin”.
local ChangeName: "Hair" | "Skin"
1 Like
Thank u worked
This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.