public override void Update(uint elapsed) { base.Update(elapsed); updateTimeCountDown(); mLastMillionSec = (mLastMillionSec + elapsed) % uint.MaxValue; if ((mLastMillionSec - mOneSecNum) >= 1000) { mOneSecNum = mLastMillionSec; //updateTimeCountDown(); } if (mCacheCallBack != null && mCacheCallBack.Count != 0) { for (int i = 0; i < mCacheCallBack.Count; i++) { FuncCallBack func = mCacheCallBack[i]; if (func == null) { continue; } if (func.startMillionSec < func.endMillionSec) { func.startMillionSec += (int)elapsed; } else { func.callBack(func.go, func.param); mCacheCallBack.Remove(func); i = 0; // 重新从头开始遍历数组; } } } }