Scripting Helpers is winding down operations and is now read-only. More info→
Ad
Log in to vote
0

How can I make this onClicked()?

Asked by 10 years ago

local stuff = {} -- empty table

function get(model) -- function for i,v in pairs(model:GetChildren()) do -- loop through all objects if pcall(function() v.Transparency = 0 end) then table.insert(stuff,v) end -- if "Transparency" is a property get(v) -- repeat loop on the object (for models within models and decals also) end end

get(workspace.Exterior) -- get all the Transparency items within "Exterior"

for i = 0,1,.1 do -- loop from 0 to 1 (from visible to invisible) wait(.1) for t,k in pairs(stuff) do -- loop through all your parts k.Transparency = i -- set each part (or decal) to its transparency end end

0
please put the code into a Code Viewer thing just Select the code and click on the Lua logo above the text editor DragonSkyye 517 — 10y

Answer this question