02.03.2014, 17:49
hi, i have this code:
and when I typing /sms Ance blablabla it show me this code:
but it should show this:
pawn Код:
CMD:sms( playerid, params[ ] )
{
if( zInfo[ playerid ][ mutelaikas ] > 0 ) return ErorMSG( playerid, "Jūs esate uћtildytas" );
if( !zInfo[ playerid ][ turitel ] ) return ErorMSG( playerid, "Jūs neturite telefono" );
if( zInfo[ playerid ][ telstat ] == 0 ) return ErorMSG( playerid, "Jūsų telefonas yra iљjungtas" );
if( zInfo[ playerid ][ psaskaita ] < 1 ) return ErorMSG( playerid, "Jums neuћtenka sąskaitos" );
new id,
tekstas[ 256 ],
_str[ 128 ],
vardas[ MAX_PLAYER_NAME ],
vardas2[ MAX_PLAYER_NAME ];
GetPlayerName( playerid, vardas, MAX_PLAYER_NAME );
GetPlayerName( id, vardas, MAX_PLAYER_NAME );
if( isnull( params, id, tekstas ) )return ErorMSG( playerid, "Siūsti sms ћinute: {FF0000}/sms [Vardas_Pavarde] [Tekstas]" );
if( !IsPlayerConnected( id ) ) return ErorMSG( playerid, "Tokio ћaidėjo nėra" );
if( zInfo[ id ][ telstat ] == 0 ) return ErorMSG( playerid, "Ћaidėjo telefonas iљjungtas" );
//if( id == playerid ) return ErorMSG( playerid, "Sau ћinutės siūsti negalite" );
else
{
format( _str, sizeof ( _str ), "{00FF00}SMS {FF0000}%s {FFFFFF}: %s", vardas2, params );
SendClientMessage( playerid, -1, _str );
zInfo[ playerid ][ issiustos ] += 1;
zInfo[ playerid ][ psaskaita ] -= 1;
format( _str, sizeof ( _str ), "{00FF00}SMS {FF0000}%s {FFFFFF}: %s", vardas, params );
SendClientMessage( id, -1, _str );
PlayerPlaySound( id, 1057, 0.0, 0.0, 0.0 );
zInfo[ id ][ gautos ] += 1;
}
return true;
Quote:
if( isnull( params, id, tekstas ) )return ErorMSG( playerid, "Siūsti sms ћinute: {FF0000}/sms [Vardas_Pavarde] [Tekstas]" ); |
Quote:
else { format( _str, sizeof ( _str ), "{00FF00}SMS {FF0000}%s {FFFFFF}: %s", vardas2, params ); SendClientMessage( playerid, -1, _str ); zInfo[ playerid ][ issiustos ] += 1; zInfo[ playerid ][ psaskaita ] -= 1; format( _str, sizeof ( _str ), "{00FF00}SMS {FF0000}%s {FFFFFF}: %s", vardas, params ); SendClientMessage( id, -1, _str ); PlayerPlaySound( id, 1057, 0.0, 0.0, 0.0 ); zInfo[ id ][ gautos ] += 1; } return true; |