A game loop has more to it than you think.
游戏循环比你想象的要复杂。
This sequence is handled through the game loop.
这序列就是通过游戏循环来实现的。
The game loop is the heartbeat of every game, no game can run without it.
游戏循环就像心跳,没有游戏能离开它。
For example, implementing a replay function in this kind of game loop is easy.
比如,在这样的游戏循环下实现一个重播的函数并不难。
With this kind of game loop, the implementation of update_game will stay easy.
在这种游戏循环下,update_game的实现能保持简单。
The game loop is just that: a loop.
简单来说,游戏主循环就是一个循环过程。
何为游戏循环?
Just like I said in the introduction, the game loop is the heartbeat of every game.
正如我在介绍中所说,所谓游戏循环就是每个游戏的心跳。
Another implementation of a game loop is to let it run as fast as possible, and let the FPS dictate the game speed.
另一种游戏循环的实现就是让其尽可能快地运行,然后让FPS控制游戏速度。
In this article I will not go into details on any of the above mentioned tasks, but will concentrate on the game loop alone.
在本文我不会深入前面提到的各种任务的详细实现,而是专注于游戏循环这一点。
But fear not, because you have just stumbled upon the one and only article that gives the game loop the attention it deserves.
但别担心,因为你正好遇到这篇文章,这是唯一一篇给予游戏循环应有重视的文章。
Thanks to my job as a game programmer, I come into contact with a lot of code for small mobile games. And it always amazes me how many game loop implementations are out there.
多亏作为游戏程序员的工作,我能接触到大量小型手机游戏的代码,并且总让我惊奇地发现如此之多的游戏循环的实现方式。
Game loop latency is not a single constant and varies over time.
游戏循环延迟不是一个单一的常数并会随着时间的推移而异。
Game loop latency is not a single constant and varies over time.
游戏循环延迟不是一个单一的常数并会随着时间的推移而异。
应用推荐