Beispiel #1
0
 public PaddleModel()
 {
     Height            = 100;
     Width             = 25;
     Style             = "fill:rgb(0,0,255);stroke-width:1;stroke:rgb(0,0,0)";
     Speed             = 5;
     LastMove          = DateTime.UtcNow;
     PaddleMovment     = PaddleMovment.PaddleMovmentAll();
     PaddleOutOfBounds = new PaddleOptons(false, false, false, false);
 }
Beispiel #2
0
 public static Player InitPlayer(List <Paddle> paddles, PaddleOptons playerScore, bool isHuman = true)
 {
     return(new Player()
     {
         IsHuman = isHuman,
         Paddles = paddles,
         Score = 0,
         PlayerScore = playerScore
     });
 }
Beispiel #3
0
 public static Player InitSinglePlayer(Paddle paddles, PaddleOptons playerScore, bool isHuman = true)
 {
     return(new Player()
     {
         IsHuman = isHuman,
         Paddles = new List <Paddle>()
         {
             paddles
         },
         Score = 0,
         PlayerScore = playerScore
     });
 }