Example #1
0
        /// <summary>
        /// Navigates to game
        /// </summary>
        /// <param name="sessionData">Savedata of a session to load</param>
        public void NavigateToGame(Session.Data sessionData)
        {
            PageGame game = new PageGame(this);

            currentPage = game;
            Navigate(game);
            game.Load(sessionData);
        }
Example #2
0
        /// <summary>
        /// Navigate to the game
        /// </summary>
        /// <param name="playerNames">List of all player names</param>
        /// <param name="frontType">Fronttype for the cards</param>
        /// <param name="backType">Backtype for the cards</param>
        /// <param name="layout">Layout for the board</param>
        public void NavigateToGame(List <string> playerNames, ImagePool.FrontTypes frontType, ImagePool.BackTypes backType, Board.Layouts layout)
        {
            PageGame game = new PageGame(this);

            currentPage = game;
            Navigate(game);
            game.Setup(playerNames, frontType, backType, layout);
        }
Example #3
0
    public static void Init()
    {
        _canvas = GameObject.Find("Canvas").GetComponent <Canvas>();

        _background = GameObject.Find("BackgroundPlayer").gameObject;

        _pageMainMenu = new PageMainMenu();
        _pageGame     = new PageGame();

        _pages.Add(_pageMainMenu);
        _pages.Add(_pageGame);

        for (var i = 0; i < _pages.Count; i++)
        {
            _pages[i].Load();
            _pages[i].Init();
        }

        //HideAll();
    }