One of my admins wrote this function, I think it would make a nice addition.
He doesn't have an account on here so I'm posting this on his behalf.
Credits to Mitch
for code / testing:
RegAdminCmd("sm_addhappy", Command_Addhappy, ADMFLAG_BAN, "Adds a happy phrase to happy_phrases.ini");
public Action:Command_Addhappy(client, args)
if(args < 1)
ReplyToCommand(client, "[SM] Usage: sm_addhappy <phrase>");
BuildPath(Path_SM, szFile, sizeof(szFile), "configs/happy_phrases.ini");
new Handle:hFile = OpenFile(szFile, "at");
WriteFileLine(hFile, "%s", szhappyphrase);
g_phraseCount = BuildPhrases();