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

How would I count enemies in a game with FilteredEnabled?

Asked by 6 years ago

Ok, so I trying to make a counter that holds a number of how many mobs(enemies) that are spawned in during the wave. How would I do that in FilteredEnabled?

function enemiesInGame(player,number)
local EnemIs = {}
    EnemyHolder.ChildAdded:connect(function(e)
        table.insert(EnemIs,e)
        for i,v in pairs(EnemIs) do
            return i
        end
    end)
end

EnRF.OnServerInvoke = enemiesInGame

How would I count every enemy that is in the holder and send it back to the Counter to hold?

BTW "EnRF" is the RemoteFunction

0
Where is the counter located? dirk2999 103 — 6y

Answer this question