add new player LEO arresting support

This commit is contained in:
Damen 2019-04-09 22:22:50 -04:00
parent 3a9d6127b9
commit 0922f8d8a0

View File

@ -546,4 +546,20 @@ hook OnPlayerAccessEntrance( playerid, entranceid, worldid, interiorid )
} }
} }
return 1; return 1;
}
hook OnPlayerUpdateEx( playerid )
{
if ( p_Class[ playerid ] == CLASS_POLICE && GetPlayerScore( playerid ) < 50 )
{
new
Float: radius = 25.0,
closestCivilian = GetClosestPlayerEx( playerid, CLASS_CIVILIAN, radius );
if ( GetPlayerWantedLevel( closestCivilian ) != 0 )
{
return ShowPlayerHelpDialog( playerid, 4000, "Use ~y~/taze [ID]~w~, ~b~/cuff [ID]~w~, and ~r~/ar [ID] ~w~commands to arrest." );
}
}
return 1;
} }