using System.Collections;
using System.Collections.Generic;
using UnityEngine;

public class GoalController : CollectableController {

    public override void Push(GridObject source)
    {
        switch (source.m_type)
        {
            case objectType.PLAYER:
                Debug.Log("Balls");
                GameManager.Instance.AddScore(m_value);
                GameManager.Instance.m_currentLevel.gameObject.SetActive(false);
                gameObject.SetActive(true);
                PlayerController.Instance.m_position = new Vector2(m_position.x, m_position.y);
                PlayerController.Instance.UpdatePosition();
                GameManager.Instance.Win(this);
                break;
        }

    }
}
