Exemplo n.º 1
0
    public void SpawnCreeps()
    {
        creepList.Clear();

        for (int i = 0; i < nmbrOfCreeps; i++)
        {
            SYCreep c = new SYScroot(RandomPosition, this, Map);
            creepList.Add(c);
        }
    }
Exemplo n.º 2
0
    public void SpawnCreep(CreepType type, int id, Vector2 position, Vector2 velocity)
    {
        if (creepList[id] != null)
        {
            RemoveCreep(id);
        }

        switch (type)
        {
        case CreepType.Scroot:
            creepList[id] = new SYScroot(id, position, velocity, this);
            break;
        }
    }