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

1 comment

0

Where is the counter located?