Exemple #1
0
 private void InitializeValues()
 {
     this.health           = 5;
     this.bombCount        = 1;
     this.superBombCount   = 0;
     this.mineCount        = 1;
     this.superMineCount   = 0;
     this.action           = "";
     this.speed            = 2;
     this.explosionPower   = 2;
     this.pictureStructure = "";
     this.movementControl  = new MovementControl();
     this.hasSuperbombs    = true;
     this.invincibleUntil  = 0;
     this.undoTimer        = 0;
     this.canUndo          = true;
     stateContext          = new Context(movementControl, this);
     stateContext.SetState(new Alive());
     this.previousBlock = new List <int[]>();
     for (int i = 0; i < 4; i++)
     {
         previousBlock.Add(new int[2]);
     }
 }
Exemple #2
0
 public Context(MovementControl movement, Player player)
 {
     currentState    = new InLobby();
     movementControl = movement;
     this.player     = player;
 }