local BCounter = (Gun["C"..BCount]) table.insert(BTransparentT,BCounter) for i,v in pairs(BTransparentT) do v.Transparency=1
So I have this function that inserts these variables into a table, but I don't know how to remove them all at once. I tried doing this
for i,v in pairs(BTransparentT) table.remove(BTransparentT,v) --But it didn't work, I keep getting an error
Thank you for answering if you did.
Try testing this out:
local MyTable = {1,2,3,4,5,6} for i=#MyTable,1,-1 do table.remove(MyTable,i) end
Now try changing it into yours.
This will clear your table of all values:
BTransparentT = {}
BTTransparent will now be an empty table.