convert zcmd to strcmp please
#7

I'd recommend converting your gamemode to ZCMD. ZCMD is much more faster then STRCMP, how-ever here it is,

pawn Код:
if(strcmp(cmd, "/mlift", true) == 0)
{
   if (isnull(params)) return SendClientMessage(playerid, -1, Usage: /mlift <up/down>");
    if (!strcmp(params, "
up", true))
    {
        if(!IsPlayerInRangeOfPoint(playerid, 5.0, 1569.34424, -2156.86060, 12.96720)) return SendClientMessage(playerid, blue, "
You Are Not In Garage!");
        MoveObject(MechLift, 1569.34424, -2156.86060, 14.70720, 0.5);
    }
    else if (!strcmp(params, "
down", true))
    {
        if(!IsPlayerInRangeOfPoint(playerid, 5.0, 1569.34424, -2156.86060, 12.96720)) return SendClientMessage(playerid, blue, "
You Are Not In Garage!");
        MoveObject(MechLift, 1569.34424, -2156.86060, 12.96720, 0.5);
    }
    else SendClientMessage(playerid, -1, "
usage: up da down!");
    return 1;
}
NOTE: You'll need to include the "isnull" function if you don't have it already as it's included with ZCMD.
Reply


Messages In This Thread
convert zcmd to strcmp please - by georgian1 - 11.09.2014, 16:44
Re: convert zcmd to strcmp please - by Stinged - 11.09.2014, 16:48
Re: convert zcmd to strcmp please - by georgian1 - 11.09.2014, 16:49
Re: convert zcmd to strcmp please - by Pottus - 11.09.2014, 16:56
Re: convert zcmd to strcmp please - by georgian1 - 11.09.2014, 17:43
Re: convert zcmd to strcmp please - by SilverPortal - 11.09.2014, 17:46
Re: convert zcmd to strcmp please - by Abagail - 11.09.2014, 17:46
Re: convert zcmd to strcmp please - by georgian1 - 11.09.2014, 20:48
Re: convert zcmd to strcmp please - by Dignity - 11.09.2014, 21:06
Re: convert zcmd to strcmp please - by georgian1 - 12.09.2014, 06:34

Forum Jump:


Users browsing this thread: 3 Guest(s)