new const szSoundRadio[][]={"vox/sc/buffclass22s4ct/character/win1.wav"};
public plugin_precache()
{
new i, szText[64]; //increase size to 128 if path too long
for(i=0;i<sizeof(szSoundRadio);i++)
{
formatex(szText, charsmax(szText), "sound/%s", szSoundRadio[i]);
precache_generic(szText); //not emit so use precache_generic to avoid 512 limit.
}
}
public plugin_init()
{
register_clcmd("say tt", "CmdPlaySound");
}
public CmdPlaySound(id)
{
client_cmd(id, "spk %s", szSoundRadio[random(sizeof(szSoundRadio))]);
}
Try this, if it work, then something is wrong with your code.