Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP

Loading…

Using a custom build speed. #7

Closed
wants to merge 1 commit into from

2 participants

@ptdorf

Because I like to step in. :P

@rwos rwos closed this pull request from a commit
@rwos Now exposing the speed of the animation via a cpp definition.
This closes #7. Thanks to Pedro Barbosa.
babe68b
@rwos rwos closed this in babe68b
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Commits on Aug 31, 2012
  1. Using a custom build speed.

    Pedro Barbosa authored
This page is out of date. Refresh to see the latest.
Showing with 4 additions and 1 deletion.
  1. +4 −1 gti.c
View
5 gti.c
@@ -19,6 +19,9 @@
#include <string.h>
#define GIT_NAME "git"
+#ifndef GTI_SPEED
+#define GTI_SPEED 40
+#endif
int term_width(void);
void init_space(void);
@@ -37,7 +40,7 @@ int main(int argc, char **argv)
init_space();
for (i = -20; i < TERM_WIDTH; i++) {
draw_car(i);
- usleep(20*1000);
+ usleep(1000*100/GTI_SPEED);
clear_car(i);
}
char *git_path = getenv("GIT");
Something went wrong with that request. Please try again.