Put version in window title.

This commit is contained in:
Nicolás Ortega Froysa 2018-03-29 01:06:15 +02:00
parent ab10fcdf02
commit 2d64adf476
No known key found for this signature in database
GPG Key ID: FEC70E3BAE2E69BF

View File

@ -48,7 +48,9 @@ const char *info_format =
"velY: %f";
int main() {
printf("SpaceShipSim v%s\n", VERSION);
char title[32];
sprintf(title, "SpaceShipSim v%s", VERSION);
puts(title);
if(!al_init())
{
@ -79,6 +81,7 @@ int main() {
fprintf(stderr, "alleg5: failed to initialize display.\n");
return 1;
}
al_set_window_title(display, title);
#ifdef DEBUG
puts("Created display.");
#endif