iPhone Deck Game Loop
can anyone tell the best approach to run game loop like Uno or Herats (Deck Game)
[CPU2 turn];
[CPU3 turn];
[User tur开发者_开发问答n]; // Wait to get user input before proceed to [CPU4 turn]
[CPU4 turn];
Perhaps you could make turns into NSOperation subclass instances placed into an NSOperationQueue, which is set to allow only one concurrent turn/operation. In this case, turns are handled in first-in-first-out (FIFO) order. You can read more about this in Apple's Managing Concurrency document.
加载中,请稍侯......
精彩评论