projects
/
rocksndiamonds.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
rnd-19980909
[rocksndiamonds.git]
/
src
/
events.c
diff --git
a/src/events.c
b/src/events.c
index 5f85101eb06ef4b6764c38034d140e0620b771f7..af4a4c5690f17aa8878fda42b2f556e10348567e 100644
(file)
--- a/
src/events.c
+++ b/
src/events.c
@@
-65,10
+65,13
@@
void EventLoop(void)
else /* got no event, but don't be lazy... */
{
HandleNoXEvent();
else /* got no event, but don't be lazy... */
{
HandleNoXEvent();
- Delay(1000); /* don't use all CPU time when idle */
- }
- XSync(display,FALSE);
+ /* don't use all CPU time when idle; the main loop while playing
+ has its own synchronization and is CPU friendly, too */
+
+ if (game_status != PLAYING)
+ Delay(1000);
+ }
if (game_status==EXITGAME)
return;
if (game_status==EXITGAME)
return;