Пример #1
0
    public void RequestSpawnAt(TrapModel model, Vector3Int position)
    {
        if (!CanSpawnTrapAt(model, position))
        {
            return;
        }
        if (Souls < model.Souls)
        {
            return;
        }

        var trap = TrapManager.SpawnTrap(model, position);

        trap.OnPurchase();
        if (trap != null)
        {
            m_traps.Add(trap);
        }
    }