adds XP check for firetruck usage
This commit is contained in:
parent
65fd8ac780
commit
8e2101fad3
@ -128,9 +128,19 @@ hook OnServerGameDayEnd( )
|
|||||||
hook OnPlayerDriveVehicle( playerid, vehicleid )
|
hook OnPlayerDriveVehicle( playerid, vehicleid )
|
||||||
{
|
{
|
||||||
new
|
new
|
||||||
modelid = GetVehicleModel( vehicleid );
|
modelid = GetVehicleModel( vehicleid ),
|
||||||
|
Float: total_experience;
|
||||||
|
|
||||||
|
GetPlayerTotalExperience( playerid, total_experience );
|
||||||
|
|
||||||
if ( modelid == 407 ) {
|
if ( modelid == 407 ) {
|
||||||
|
|
||||||
|
if ( total_experience < 2500 )
|
||||||
|
{
|
||||||
|
RemovePlayerFromVehicle( playerid );
|
||||||
|
return SendServerMessage( playerid, "You must have 2,500XP to use a Firetruck." );
|
||||||
|
}
|
||||||
|
|
||||||
ShowPlayerHelpDialog( playerid, 2500, "You can see where fires are using ~g~/fires" );
|
ShowPlayerHelpDialog( playerid, 2500, "You can see where fires are using ~g~/fires" );
|
||||||
}
|
}
|
||||||
return 1;
|
return 1;
|
||||||
|
Loading…
Reference in New Issue
Block a user