Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- local function printFullNames()
- local object = assert(loadstring("return " .. getgenv().path))()
- if object then
- print("Object:", object:GetFullName())
- -- Print children
- print("Children:")
- for _, child in pairs(object:GetChildren()) do
- print(child:GetFullName())
- end
- -- Print parents
- print("Parents:")
- local parent = object.Parent
- while parent do
- print(parent:GetFullName())
- parent = parent.Parent
- end
- else
- print("Object not found.")
- end
- end
- -- Example usage:
- printFullNames()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement