Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if( strcmp( cmd, "/suspect", true ) == 0 || strcmp( cmd, "/sus", true ) == 0 )
- {
- new param1[256]
- printf( "suspect cmd" );
- new ReturnPlayerName[MAX_PLAYER_NAME];
- GetPlayerName(playerid,ReturnPlayerName,sizeof(ReturnPlayerName);
- if( gTeam[ playerid ] == COPS )
- {
- new suspect;
- if( !strlen(param1))
- {
- SendClientMessage( playerid, COLOR_RED, "Usage: /suspect [player id] [reason ( one word only, sorry )]" );
- return 1;
- }
- suspect = strval(param1);
- if( suspect == playerid )
- {
- SendClientMessage( playerid, COLOR_RED, "You can not suspect yourself!" );
- return 1;
- }
- if( IsPlayerConnected( suspect ) == 0 )
- {
- SendClientMessage( playerid, COLOR_RED, "You can not suspect non - players." );
- return 1;
- }
- if( IsSuspect[ suspect ] == 1 )
- {
- SendClientMessage( playerid, COLOR_RED, "This player is already a suspect." );
- return 1;
- }
- new client_msg[ 256 ];
- format( client_msg, sizeof( client_msg ), "Player %s suspected of: %s by Officer %s, calling all cars.", ReturnPlayerName( suspect ), param2, ReturnPlayerName( playerid ) );
- SendClientMessageToAll( COLOR_ORANGE, client_msg );
- SetPlayerColor( suspect, COLOR_ORANGE );
- IsSuspect[ suspect ] = 1;
- return 1;
- }
- else
- {
- SendClientMessage( playerid, COLOR_RED, "You must be a police officer to suspect people." );
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment