Beispiel #1
0
 public NusbioLandscapeMatrix(NusbioMatrix nusbioMatrix, int deviceIndex)
 {
     this._deviceIndex     = deviceIndex;
     this._nusbioMatrix    = nusbioMatrix;
     this.CurrentXPosition = this._nusbioMatrix.Width - 1;
     this.CurrentYPosition = this._nusbioMatrix.Height - 1;
     _nusbioMatrix.Clear(this._deviceIndex, true);
 }
Beispiel #2
0
        public void Redraw()
        {
            NusbioMatrix.Clear(0, false);
            foreach (var o in _objects)
            {
                o.Move();
                o.Redraw();
            }
            NusbioMatrix.WriteDisplay();

            // The ball reached the wall area
            if (this._mainBall._x == this.Width - 1)
            {
                if (this.Rackette.InYArea(this._mainBall._y))
                {
                    this.PointWon++;
                }
                else
                {
                    this.PointLost++;
                }
            }
        }