19.10.2013, 16:30
This Command to give players car refund but i got error.
and this the error
PHP код:
CMD:vrefund(playerid, params[])
{
if(GetPVarInt(playerid, "VehicleRefund") == 1) {
if(GetPlayerVirtualWorld(playerid) != 0) return SendClientMessageEx(playerid, -1, "* You must be outside in Virtual World 0.");
if(GetPlayerInterior(playerid) != 0) return SendClientMessageEx(playerid, -1, "* You must be outside in Interior 0.");
ShowPlayerDialog(playerid, RFDVEH, DIALOG_STYLE_LIST, "{3399FF}Refunded Vehicle", "Sultan\nNRG-500\nSandking\nTurismo\nBullet\nAdmiral\nPremier\nElegy\nMaverick", "Choose", "");
}
else
return SendClientMessageEx(playerid, -1, "* You are not eligible or already got your refund.");
return 1;
}
CMD:grantvrefund(playerid, params[])
{
new giveplayerid;
if(PlayerInfo[playerid][pAdmin] != 99999) return SendClientMessageEx(playerid, -1, "You are not authorized to use this command.");
if(sscanf(params, "u", giveplayerid)) return SendClientMessageEx(playerid, COLOR_GREY, "USAGE: /grantvrefund [player]");
if(GetPVarInt(giveplayerid, "VehicleRefund") != 1) {
SetPVarInt(giveplayerid, "VehicleRefund", 1);
SendClientMessageEx(giveplayerid, COLOR_ORANGE, "* You have been granted one free vehicle refund by an Executive Director! (/vrefund)");
}
else SendClientMessageEx(playerid, -1, "* That player already has the ability to use /vrefund");
return 1;
}
PHP код:
C:\Users\pc\Downloads\rotana\Server Files\gamemodes\R-RP.pwn(54927) : error 017: undefined symbol "RFDVEH"