Player-Problem with Sscanf2 and ZCMD
#1

Hello

I am from switzerland and my english isnt the best, dont hit me

Ok, since the update from 0.3b to 0.3c Ive problems with playernames or the id of players. At beginning I used the specifier u of the sscanf2 plugin, but i switched to the r specifier. Now, i cant use any id or playername who is higher than 2 ( x > 2). At first i thought that the problem was in sscanf2, but now I am not sure and think its because ZCMD.

In the sscanf2 thread, people says, that they have the same problem, but theres no solution (solution for me) and an update with a fix isnt there.

Today i thougt, mayby I can use YCMD to minimate one of these 2 factors, but YCMD is a part of YSI and I dont like to change the system for using YCMD.

I dont know how I should continue or something else, mayby theres anybody who can help me. Ive tested the id and playername with this code:

http://pastebin.com/y5hE6UGU


LG dUDALUS
Reply
#2

Well, i tryed this code and it works perfect to me.
pawn Код:
COMMAND:test(playerid, params[])
{
    new ID, string[256], name[60], name2[60];
    if(sscanf(params, "u", ID)) SendClientMessage(playerid, 0xFFFFFFAA, "USAGE: /test [id]");
    else if(IsPlayerConnected(ID) == 0) SendClientMessage(playerid, 0xFFFFFFAA, "Player is not connected!");
    else
    {
        GetPlayerName(playerid, name, 60);
        GetPlayerName(ID, name2, 60);

        format(string, 256, "%s bla bla  %s bla bla", name2, name);
        SendClientMessageToAll(0xFFFFFFAA, string);
    }
    return 1;
}
Reply
#3

Hello

Yeah, the problem with the specifier u was, that the name was not everytime the right name:

/pay Diebrook 100 --> Sent Brummi 100 Dollar

Did you testet this code with yourself ?

Lg dUDA

Edit:
Is it normal that ZCMD blocks DCMD+sscanf2 in a filterscript ?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)