SA-MP Forums Archive
Changing default chat? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Changing default chat? (/showthread.php?tid=175439)



Changing default chat? - DarrenReeder - 09.09.2010

Hello,

I would like to change my default chat to

"MY_NAME says: MY TEXT"

although im not 100% sure how i do this, the only thing i know is i use onplayerText

----

also i need to know how to make it so when i use a command like /ooc [chat], it will change the text to

"MY_NAME says: (( MY TEXT ))"

-thanks for help!


Re: Changing default chat? - [XST]O_x - 09.09.2010

Okay then.

pawn Код:
public OnPlayerText(playerid,text[])
{
    new name[MAX_PLAYER_NAME],stringZ[128];
    GetPlayerName(playerid,name,sizeof(name));
    format(stringZ,sizeof(stringZ),"%s says: %s",name,text);
    SendClientMessageToAll(COLOR_GREY,stringZ);
    return 0; // returning a negative value so the message won't be sent twice,I mean,the normal chat + our script
}
Let me script /ooc


Re: Changing default chat? - DarrenReeder - 09.09.2010

Thankyou Kind sir

You dont Need to script OOC command, i just need to know how to make sure it doesnt send twice, that was main thing i needed help with..

THanks so much for help, greatly appriciated.