Let codec loader decide which extension to give to extensionless filenames

This commit is contained in:
Thilo Schulz 2011-04-18 18:55:58 +00:00
parent 6a203bc8e9
commit 3551b0fa3c

View file

@ -410,12 +410,9 @@ void S_Play_f( void ) {
i = 1;
while ( i<Cmd_Argc() ) {
if ( !Q_strrchr(Cmd_Argv(i), '.') ) {
Com_sprintf( name, sizeof(name), "%s.wav", Cmd_Argv(1) );
} else {
Q_strncpyz( name, Cmd_Argv(i), sizeof(name) );
}
Q_strncpyz( name, Cmd_Argv(i), sizeof(name) );
h = si.RegisterSound( name, qfalse );
if( h ) {
si.StartLocalSound( h, CHAN_LOCAL_SOUND );
}