Allow playing oggs using 'play soundname'

This commit is contained in:
Eric Wasylishen 2011-01-19 15:10:12 -07:00
parent f908623606
commit fa8a6f88f2
1 changed files with 1 additions and 7 deletions

View File

@ -1148,13 +1148,7 @@ void S_Play (void)
i = 1; i = 1;
while (i < Cmd_Argc()) while (i < Cmd_Argc())
{ {
if (!Q_strrchr(Cmd_Argv(i), '.')) Q_strcpy(name, Cmd_Argv(i));
{
Q_strcpy(name, Cmd_Argv(i));
Q_strcat(name, ".wav");
}
else
Q_strcpy(name, Cmd_Argv(i));
sfx = S_PrecacheSound(name); sfx = S_PrecacheSound(name);
S_StartSound(hash++, 0, sfx, listener_origin, 1.0, 1.0); S_StartSound(hash++, 0, sfx, listener_origin, 1.0, 1.0);
i++; i++;