Ejemplo n.º 1
0
    public void SpawnTowerMonster(int level)
    {
        //Make sure to leave as integer division
        int areaToPickFrom = level / 10;

        Debug.Log("Picking a monster from: " + fm.areaInformation[areaToPickFrom].areaName);
        var enemy = enemySpawner.SpawnEnemy(fm.areaInformation[areaToPickFrom], level);

        enemy.unitDied.AddListener(towerMonsterDied);
        fm.RpcNotifyEnemySpawn(enemy.gameObject);
    }