CMD: to strcmp
#1

How to make this command into strcmp?

pawn Код:
CMD:setlandowner(playerid, params[])
{
    if(PlayerInfo[playerid][pAdmin] >= 5)
    {
        new land, playername[24], string[128];
        if(sscanf(params, "ds[24]", land, playername)) return SendClientMessage(playerid, COLOR_WHITE, "USAGE: /setlandowner [landid] [name]");
        if(LandInfo[land][landCreated] == 1)
        {
            format(LandInfo[land][landOwner], 24, "%s", playername);
            format(string, sizeof(string), "You have set land %d's owner to '%s'", land, LandInfo[land][landOwner]);
            SendClientMessage(playerid, COLOR_LIGHTBLUE, string);
            format(string, sizeof(string), "%s's Land (%d)", LandInfo[land][landOwner], land);
            UpdateDynamic3DTextLabelText(LandInfo[land][landText], COLOR_REALRED, string);
            LandInfo[land][landOwned] = 1;
        }
        else
        {
            SendClientMessage(playerid, COLOR_GREY, "That land does not exist.");
        }
    }
    return 1;
}
Reply


Messages In This Thread
CMD: to strcmp - by MayaEU - 08.07.2016, 22:08
Re: CMD: to strcmp - by Mencent - 08.07.2016, 22:12
Re: CMD: to strcmp - by Napst34 - 08.07.2016, 22:22
Re: CMD: to strcmp - by PrO.GameR - 08.07.2016, 23:59

Forum Jump:


Users browsing this thread: 1 Guest(s)