this is my code thingy

	local function UnAnchor()
	    for _, v in pairs(script.Parent:GetChildren()) do
	        if v.ClassName == "Part" then
	            v.Anchored = false
	        end
	    end
	end
	 
	script.Parent.Touched:Connect(function()
	    print("Meteor was touched by player")
	    UnAnchor()
	end)

8 comments

0

please elaborate

0

Not entirely sure what you're asking for?

0

i need to make it so when the players touch the map the meteors unanchor

0

What is the script's parent?

0

What is the script's parent?

0

how do i know that

0

we do not know what the 'Map' is, and also, where is your script located? I was assuming in the last script I gave you which you pasted.. script.Parent is the map.

0

Instead of :Connect(function() just do script.Parent.Touched:Connect(UnAnchor) if the script parent is a part or whatever it is you want