Exemplo n.º 1
0
 protected void InitialPerson() //初始化人员
 {
     Generator = new PersonGenerator();
     Generator.Generate(100);
     for (int i = 0; i < MaxPersonNum; ++i)
     {
         People[i] = new Person();
     }
     for (int i = 0; i < MaxPersonNum; ++i)
     {
         People[i] = new Person(Generator.Next(People), i);
     }
     CheckPersonNumber();
 }
Exemplo n.º 2
0
 public Game()
 {
     GameCount      = 1;
     GameCamp       = Camp.CampA;
     MaxRound       = 1200;
     BallsDot       = new List <Dot>();
     BallDot        = new Dot(-1, -1);
     BallAtCollect  = new Dot(-1, -1);
     RequestNewBall = false;
     NoBall         = false;
     BallCntA       = BallCntB = 0;
     CollectCamp    = Camp.None;
     CarA           = new Car(Camp.CampA);
     CarB           = new Car(Camp.CampB);
     People         = new Person[MaxPersonNum];
     Round          = 0;
     State          = GameState.Unstart;
     Generator      = new PersonGenerator(100);
     InitialPerson();
     DebugMode  = false;
     FoulTimeFS = null;
 }