Here’s what I’m doing:
I have about 17 decal layered on top of eachother (inefficient, I know! But the assets has a delay before loading in everytime so it’s even worse of a delay).
Here’s the script I use for it.
while true do --script.Parent.Texture = ids[counter]; --script.Parent.Parent.Decal2.Texture = ids[counter]; script.Parent.slash:GetChildren()[counter].Transparency = 0; for index, decal in pairs(script.Parent.slash:GetChildren()) do if index ~= counter then decal.Transparency = 1; end end counter = counter + 1; if counter > 17 then counter = 1 end print(counter) wait(1/30) end
slash is a part thats parented to
workspace. Inside the part is 17 decals, each with a frame of the slash animation. The code simply loops through it 18 times, enabling and disabling the transparency of the decal to run through the frames. As you can notice, however, it sometimes disappears and sometimes runs smoothly. Anyone knows how to fix this? Or a better way?