Disable symbols - 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)
+--- Thread: Disable symbols (
/showthread.php?tid=293434)
Disable symbols -
BGMike - 28.10.2011
How to disable to write in chat symbols like { and } because when somebody type code like this {ffffff} in the chat the server has restarted ..
Any ideas ?
Re: Disable symbols -
Ash. - 28.10.2011
The server restarts when you do that?! D:
Anyway; this has been fixed in 0.3d (if you're talking about the colour bug) and therefore you need not worry about it.
Re: Disable symbols -
BGMike - 28.10.2011
Quote:
Originally Posted by funky1234
The server restarts when you do that?! D:
Anyway; this has been fixed in 0.3d (if you're talking about the colour bug) and therefore you need not worry about it.
|
So how to fix this in 0.3c ?
Re: Disable symbols -
IstuntmanI - 28.10.2011
Try this:
Код:
public OnPlayerText( playerid, text[ ] )
{
for( new i; i < 129; i ++ )
{
if( text[ i ] == '{' ) text[ i ] = '(';
if( text[ i ] == '}' ) text[ i ] = ')';
}
// your codes
}
But, from what I know, { and } replaces with ( and ) in 0.3c+ ...