Exemple #1
0
 private void SetupBoard()
 {
     PlayerDeckManager    = playerDeckManager;
     PlayerHand           = playerHand;
     PlayerDiscardManager = playerDiscardManager;
     PlayerCam            = playerCam;
     CardGameRef          = this;
     // PlayerHealthGlobe = playerHealthGlobe;
 }
    private void Awake()
    {
        int gameManagerCount = FindObjectsOfType <PlayerDeckManager>().Length;

        if (gameManagerCount > 1)
        {
            Destroy(gameObject);
        }
        else
        {
            DontDestroyOnLoad(gameObject);
        }

        if (instance != null)
        {
            Debug.LogError("More than one Player Deck Manager");
        }
        instance = this;
    }