Oops, make sure that one of the default splash screens gets used when the splash-texture is undefined
This commit is contained in:
parent
465d13b045
commit
22b5b1c405
1 changed files with 3 additions and 3 deletions
|
@ -58,11 +58,11 @@ void fgSplashInit ( const char *splash_texture ) {
|
||||||
splash.bind();
|
splash.bind();
|
||||||
|
|
||||||
SGPath tpath( globals->get_fg_root() );
|
SGPath tpath( globals->get_fg_root() );
|
||||||
if (splash_texture == NULL) {
|
if (splash_texture == NULL || !strcmp(splash_texture, "")) {
|
||||||
// load in the texture data
|
// load in the texture data
|
||||||
int num = (int)(sg_random() * 5.0 + 1.0);
|
int num = (int)(sg_random() * 5.0 + 1.0);
|
||||||
char num_str[256];
|
char num_str[5];
|
||||||
sprintf(num_str, "%d", num);
|
snprintf(num_str, 4, "%d", num);
|
||||||
|
|
||||||
tpath.append( "Textures/Splash" );
|
tpath.append( "Textures/Splash" );
|
||||||
tpath.concat( num_str );
|
tpath.concat( num_str );
|
||||||
|
|
Loading…
Reference in a new issue