Need help with CMDS
#1

I am having some problem with make a /vw command

I want it like /vw (1-999999)

Can any one tell me how should I do it?
Reply
#2

Elaborate please.

/vw What is it for? What you looking for?
Reply
#3

/vw = Virtual World.
pawn Код:
CMD:vw(playerid, params[])
{
    new vw, string[100];
    if(sscanf(params,"i", vw) || vw < 0 || vw > 999999)
    {
        SendClientMessage(playerid, 0xFFFFFFFF, "Usage: /vw <0-999999>.");
        return 1;
    }
    format(string, sizeof (string), "You've set your virtual world to %i!", vw);
    SendClientMessage(playerid, 0xFFFFFFFF, string);
    SetPlayerVirtualWorld(playerid, vw);
    return 1;
}
Reply
#4

Quote:
Originally Posted by [vTc]Patroool
Посмотреть сообщение
Elaborate please.

/vw What is it for? What you looking for?
ItS for virtual world
Reply
#5

Quote:
Originally Posted by SickAttack
Посмотреть сообщение
/vw = Virtual World.
pawn Код:
CMD:vw(playerid, params[])
{
    new vw, string[100];
    if(sscanf(params,"i", vw) || vw < 0 || vw > 999999)
    {
        SendClientMessage(playerid, 0xFFFFFFFF, "Usage: /vw <0-999999>.");
        return 1;
    }
    format(string, sizeof (string), "You've set your virtual world to %i!", vw);
    SendClientMessage(playerid, 0xFFFFFFFF, string);
    SetPlayerVirtualWorld(playerid, vw);
    return 1;
}
Thx but, when I put it in pawno, it gives me erros when I compile
Undefined symbols params and some more
When I define them, it still gives me the error plz can u make it in the normal way?
Which is:

if(!strcmp(cmdtext, "/help", true))
Reply
#6

If you are getting errors that means you don't have ZCMD. Download it from here: https://sampforum.blast.hk/showthread.php?tid=91354. I recomend that you use ZCMD because it's way easier and faster than the default one so again give it a try.
Reply
#7

Quote:
Originally Posted by SickAttack
Посмотреть сообщение
If you are getting errors that means you don't have ZCMD. Download it from here: https://sampforum.blast.hk/showthread.php?tid=91354. I recomend that you use ZCMD because its way eazier and faster than the default one so again give it a try.
I do have ZCMD and I think the problem is sscanf
Reply
#8

Then download sscanf. https://sampforum.blast.hk/showthread.php?tid=120356
Reply
#9

Quote:
Originally Posted by SickAttack
Посмотреть сообщение
Thx it really worked.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)