using System;
using UnityEngine;

[Serializable]
internal class LevelDesign : Rule
{
    protected override void ApplyRule()
    {
        // spawn randomly a prefab in a spawing area.
        GameObject gameObj = m_prefabs[UnityEngine.Random.Range(0, m_prefabs.Count)];

        GameObject spawnPoint = GameManager.GetSpawnPoint();

        GameObject.Instantiate(gameObj, spawnPoint.transform.position, Quaternion.identity);
    }
}
