示例#1
0
文件: Box.cs 项目: dtd-amiele/BBTAN-
 // COnstructor of box
 //pass the window, x, y position and the value inside the box
 public Box(Window gameWindow, int x, int y, int value)
 {
     X           = x;
     Y           = y;
     Value       = value;
     _gameWindow = gameWindow;
     MainColor   = Color.RandomRGB(200);
     while ((SplashKit.RedOf(MainColor) == 0) && (SplashKit.GreenOf(MainColor) == 0) && (SplashKit.BlueOf(MainColor) == 0))
     {
         MainColor = Color.RandomRGB(200);
     }
 }