예제 #1
0
 public void Init(int floorcount)
 {
     for (int i = 0; i < floorcount; i++)
     {
         var elevatorstat = new ElevatorStat(i);
         elevatorstat.SetEvent += Elevatorstat_SetEvent;
         Floors.Add(elevatorstat);
     }
 }
예제 #2
0
 private void Elevatorstat_SetEvent(int arg1, int arg2, ElevatorStat arg3)
 {
     if (arg2 == 0)//down
     {
         up.Add(arg3);
     }
     else//up
     {
         down.Add(arg3);
     }
 }