Пример #1
0
 public void Update()
 {
     for (int i = 0; i < bombDataList.Count; i++)
     {
         if (TimerThread.GetNowTime() - bombDataList[i].startTime >= bombDataList[i].durationTime * 1000)
         {
             SendOpenBomb(bombDataList[i]);
             RemoveBomb(bombDataList[i]);
             i--;
         }
     }
 }
Пример #2
0
 //启动线程的方法
 public void AddBomb(BombData bombData)
 {
     bombData.startTime = TimerThread.GetNowTime();
     bombDataList.Add(bombData);
 }