epp does not support variadic args

SVN revision: 67588
This commit is contained in:
Davide Andreoli 2012-01-29 14:41:51 +00:00
parent 30980e2ecf
commit c37e388c4a
1 changed files with 7 additions and 10 deletions

View File

@ -9,14 +9,6 @@
#define BALL_SPEEDUP 0.1
#define BALL_SIZE 10
#if DEBUG_ENABLE
#define DBG(...) { \
new _buf[128]; \
snprintf(_buf, sizeof(_buf), __VA_ARGS__); \
set_text(PART:"dbg", _buf); }
#else
#define DBG(...)
#endif
collections {
group { name: "main";
@ -148,8 +140,13 @@ collections {
if (bx + BALL_SIZE > fw) player_wins();
/* show debug info (if debug enabled) */
DBG("loop:%d [speed %f %f] [mouse: %d %d] [ball: %f %f]",
count, speedx, speedy, mx, my, bx, by)
#if DEBUG_ENABLE
new _buf[128];
snprintf(_buf, sizeof(_buf),
"loop:%d [speed %f %f] [mouse: %d %d] [ball: %f %f]",
count, speedx, speedy, mx, my, bx, by);
set_text(PART:"dbg", _buf);
#endif
/* recall the loop in n seconds */
timer(1.0 / FPS, "game_loop", count);