12.09.2009, 06:45
Put this anywhere
Based of Finn's reply
Untested, might not work.
Also you should get the PlayerName thingy
pawn Код:
stock PlayerName(playerid) {
GetPlayerName(playerid, name, 255);
return name;
}
pawn Код:
if(strcmp(cmd, "/refilladm", true) == 0)
{
if(dini_Get(PlayerName(playerid), "adminlevel") >= 1)
{
if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
{
Fuel[GetPlayerVehicleID(playerid)] = 999; // Change the array name & value to the correct ones
return SendMessage(playerid,WHITE,"[*] Vehicle refilled.");
}
else return SendMessage(playerid,WHITE,"[*] You're not driving a vehicle.");
}
else return SendMessage(playerid,WHITE,"[*] You're not an admin.");
}
Untested, might not work.
Also you should get the PlayerName thingy

