/cb chat needed
#1

I would like to do in chat rooms so that they appointed / cb ...... and that the player would type / cb 1 would be transferred into that room and that others would not see how this would naredul
Reply
#2

pawn Код:
CMD:changeroom(playerid, params[])
{
    new room;
    if(sscanf(params,"i",room))
        return SendClientMessage(playerid, -1, "Usage: /cb [room]");
    else
    {
        //Send a message showing that he changes the room!
        Room[playerid] = room;
    }
}

CMD:cb(playerid, params[])
{
    new text[128];
    if(sscanf(params, "s",text))
        return //Usage: bla bla bla
    else
    {
        format(string,sizeof(string), "[Room %d]%s Says: %s",Room[playerid], PLAYERNAME, text);//you must get the player name or use a stock if you have...
        for(new i=0; i<MAXPLAYERS; i++)
        {
            if(Room[i] == Room[playerid])
            SendClientMessage(i, -1, string);
        }
    }
    return 1;
}
Reply
#3

Quote:
Originally Posted by Pharrel
Посмотреть сообщение
pawn Код:
CMD:changeroom(playerid, params[])
{
    new room;
    if(sscanf(params,"i",room))
        return SendClientMessage(playerid, -1, "Usage: /cb [room]");
    else
    {
        //Send a message showing that he changes the room!
        Room[playerid] = room;
    }
}

CMD:cb(playerid, params[])
{
    new text[128];
    if(sscanf(params, "s",text))
        return //Usage: bla bla bla
    else
    {
        format(string,sizeof(string), "[Room %d]%s Says: %s",Room[playerid], PLAYERNAME, text);//you must get the player name or use a stock if you have...
        for(new i=0; i<MAXPLAYERS; i++)
        {
            if(Room[i] == Room[playerid])
            SendClientMessage(i, -1, string);
        }
    }
    return 1;
}
not working
Reply
#4

C:\Server\filterscripts\CB.pwn(29) : warning 203: symbol is never used: "cb"
C:\Server\filterscripts\CB.pwn(29) : warning 203: symbol is never used: "changeroom"
C:\Server\filterscripts\CB.pwn(29) : error 013: no entry point (no public functions)
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


1 Error.
Reply
#5

Did you even #include <zcmd>?
Reply
#6

i don.t anderstand sory
Reply
#7

i don.t know how to make cb canel... please help
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)