:GetChildren() returns a table (and takes no arguments, so you saying "FireBall" does nothing). In lua, you cannot apply an action to a table in order to apply that action to everything within it. That is, when you say fireballs.Transparency =, lua assumes you're trying to change the table rather than the list of children. To change the children, you have to use a for loop, like so:
local ch = Character:GetChildren()
local fireballs = {}
for i = 1, #ch do
if ch[i].Name == "FireBall" then
table.insert(fireballs, ch[i])
end
end
if #fireballs > 0 then
repeat
wait(0.1)
for i = 1, #fireballs do
fireballs[i].Transparency = fireballs[i].Transparency + .1
end
until fireballs[1].Transparency >= 1
end
for i = 0.1, 1, 0.1 do
wait(0.1)
for j = 1, #fireballs do
fireballs[j].Transparency = i
end
end
2 comments
The problem here is that get children returns a table of multiple objects, not just one object. Essentially, as crazycat said, you need to loop through the whole table with for i,v ipairs and change each ones transparency like that.
D: stop being mean to your computer doing more comparisons instead of using a for loop