If you want to change a part’s property locally, you won’t be able to do that if the localscript is parented to the part since local script only works if it’s in starterplayer or startergui so what you can do is create a localscript in the starterplayerscript folder and do something like
-- LocalScript
local Wall = wall
local Button = button
Button.Touched:Connect(function(Hit)
if Hit.Parent:FindFirstChild("Humanoid") then
wall.Transparency = 1
end
end)
I might not be good in scripting but try this:-
I think its MouseButton1Click or something else
local Model = game.Workspace.Model -- Put Model Path
local Button = game.Workspace.Button -- Put Button Path Here
Button.MouseButton1Click:Connect(function())
for i, v in pairs(Model:GetChildren()) do
v.Transperency = 1
end
end)
The ‘: Model’ in ‘model: Model’ is typechecking. It basically tells Roblox Studio what type a variable is. It’s optional, but definitely helps a lot as it autocompletes specific functions and properties found in that type (e.g. :PivotTo(), PrimaryPart, etc).