-(void)update:(NSTimeInterval)currentTime {
if(_gameState == STARTING) {
_startedTime = currentTime;
_gameState = PLAYING;
}
if(_gameState == PLAYING) {
int timeLeftRounded = ceil(LEVEL_TIME+(_startedTime - currentTime));
timerLabel.text = [NSString stringWithFormat:@"Time: %d", timeLeftRounded];
}
}
行中的错误
int timeLeftRounded = ceil(LEVEL_TIME+(_startedTime - currentTime));
错误消息说我应该删除最后一个)。但它不对,仍然得到错误。