コード例 #1
0
ファイル: GameLevel.cs プロジェクト: xewelus/UnityTetris
        public GameLevel(GameDesk gameDesk)
        {
            TweenFactory.DefaultTimeFunc = () => this.timing.deltaTime;

            this.gameDesk     = gameDesk;
            this.atomCubePool = new AtomCubePool(this.gameDesk.AtomCube, MaterialsScope.Cache.Default);

            this.cubesArray              = new CubesArray(gameDesk.Width, gameDesk.Height);
            this.cubesArray.CellChanged += this.CubesArray_OnCellChanged;

            if (gameDesk.Parameters == null)
            {
                throw new Exception("gameDesk.Parameters");
            }
            if (gameDesk.Parameters.Keyboard == null)
            {
                throw new Exception("gameDesk.Parameters.Keyboard");
            }

            this.keyboard = new KeyboardController(gameDesk.Parameters.Keyboard, this.timing);
            KeyboardEvents.Init(this, this.keyboard);
        }
コード例 #2
0
ファイル: User.cs プロジェクト: STaras1992/CheckersForms
 public void MakeMove(GameDesk i_Desk, string i_Move)
 {
     i_Desk.MakeMove(i_Move, r_Symbol, r_SymbolKing, Position);
 }
コード例 #3
0
 static void Main(string[] args)
 {
     GameDesk newGame = new GameDesk();
 }