// The following does not allow for changes during the traversal, but // but it does visit each record in sorted order (When-order or // Priority-order depending on the heap). // int CTaskHeap::TraverseOrdered(SCHLOOK *pfLook, SCHCMP *pfCompare) { Sort(pfCompare); for (int i = m_nCurrent-1; i >= 0; i--) { PTASK_RECORD p = m_pHeap[i]; int cmd = pfLook(p); if (IU_DONE == cmd) { break; } } Remake(pfCompare); return true; }
//輪胎向左移 void MainWindow::time_x() { if(t<31 &&t>=0) { position(); while(C>9) { C=0; for(int A=0;A<15;A++) { for(int B=0;B<15;B++) { if(tire1[A]-tire1[B]<101 || tire1[A]-tire1[B]<101) { tire1[A]=tire1[A]+100; } if(tire2[A]-tire1[B]<101 || tire2[A]-tire2[B]<101) { tire2[A]=tire2[A]+100; } } } C++; } Remake(); for(int k=0;k<15;k++) { if(tire1[k]<55 && tire1[k]>0) { combo=0; } if(tire2[k]<55 && tire2[k]>0) { combo=0; } } for(int i=0;i<15;i++) { tire1[i]=tire1[i]-5; tire2[i]=tire2[i]-5; } } }