Question
#1

in all my script cmds this line


PartOfCode
pawn Код:
CMD:gotoplayerscar(playerid, params[]) {
    if(PlayerInfo[playerid][pAdmin] >= 2 && PlayerInfo[playerid][pAdminDuty] != 1) return SendClientMessageEx(playerid, COLOR_GRAD2, "You can't do this whilst your off Duty!"); // this !
    if(PlayerInfo[playerid][pAdmin] >= 2) // and this
    {

        new
            iTargetID;

        if(sscanf(params, "u", iTargetID)) {
            SendClientMessage(playerid, COLOR_WHITE, "USAGE: /gotoplayerscar [playerid]");
        }
        else if(IsPlayerConnected(iTargetID)) {
another part
pawn Код:
CMD:cutterrims(playerid, params[])
{
    if(PlayerInfo[playerid][pAdmin] >= 2 && PlayerInfo[playerid][pAdminDuty] != 1) return SendClientMessageEx(playerid, COLOR_GRAD2, "You can't do this whilst your off Duty!"); // this

    if(IsPlayerConnected(playerid)) {
        if(PlayerInfo[playerid][pAdmin] < 2) { // this
            SendClientMessageEx(playerid, COLOR_GRAD1, "You are not authorized to use that command!");
            return 1;
        }
        if(!IsPlayerInAnyVehicle(playerid)) {
question here
is it fine to replace
pawn Код:
if(PlayerInfo[playerid][pAdmin] >= 2 && PlayerInfo[playerid][pAdminDuty] != 1) return SendClientMessageEx(playerid, COLOR_GRAD2, "You can't do this whilst your off Duty!");
to
pawn Код:
if(PlayerInfo[playerid][pAdminDuty] != 1) return SendClientMessageEx(playerid, COLOR_GRAD2, "You can't do this whilst your off Duty!");
in the both codes up ?
Reply


Messages In This Thread
Question - by Joe_Goro - 17.11.2013, 09:07
Re: Question - by dominik523 - 17.11.2013, 09:48

Forum Jump:


Users browsing this thread: 1 Guest(s)