Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- function ShowLicenses(playerid, id) {
- new text1[20], text2[20], text3[20], text4[20], string[128];
- if(playerVariables[id][pCarLic] == 1) { text1 = "Passed"; } else { text1 = "Not Passed"; }
- if(playerVariables[id][pFlyLic] == 1) { text2 = "Passed"; } else { text2 = "Not Passed"; }
- if(playerVariables[id][pBoatLic] == 1) { text3 = "Passed"; } else { text3 = "Not Passed"; }
- if(playerVariables[id][pGunLic] == 1) { text4 = "Passed"; } else { text4 = "Not Passed"; }
- SCMF(playerid, COLOR_WHITE, "---- %s's licenses ----", GetName(id));
- if(playerVariables[id][pCarLicT] == 0) {
- if(playerVariables[id][pCarLicSuspend] == 0) format(string, sizeof(string), "Drivers licence: %s", text1);
- else if(playerVariables[id][pCarLicSuspend] > 0) format(string, sizeof(string), "Drivers licence: Suspended (suspended for %d hours)", playerVariables[id][pCarLicSuspend]);
- }
- else format(string, sizeof(string), "Drivers licence: %s (expires in %d hours)", text1, playerVariables[id][pCarLicT]);
- SendClientMessage(playerid, COLOR_WHITE, string);
- if(playerVariables[id][pFlyLicT] == 0) format(string, sizeof(string), "Flying licence: %s", text2);
- else format(string, sizeof(string), "Flying licence: %s (expires in %d hours)", text2, playerVariables[id][pFlyLicT]);
- SendClientMessage(playerid, COLOR_WHITE, string);
- if(playerVariables[id][pBoatLicT] == 0) format(string, sizeof(string), "Boat licence: %s", text3);
- else format(string, sizeof(string), "Boat licence: %s (expires in %d hours)", text3, playerVariables[id][pBoatLicT]);
- SendClientMessage(playerid, COLOR_WHITE, string);
- if(playerVariables[id][pGunLicT] == 0) {
- if(playerVariables[id][pGunLicSuspend] == 0) format(string, sizeof(string), "Weapon licence: %s", text4);
- else if(playerVariables[id][pGunLicSuspend] > 0) format(string, sizeof(string), "Weapon licence: Suspended (suspended for %d hours)", playerVariables[id][pGunLicSuspend]);
- }
- else format(string, sizeof(string), "Weapon licence: %s (expires in %d hours)", text4, playerVariables[id][pGunLicT]);
- SendClientMessage(playerid, COLOR_WHITE, string);
- SendClientMessage(playerid, COLOR_WHITE,"------------");
- return 1;
- }
Add Comment
Please, Sign In to add comment