strcmp dont work
#1

If I compare two strings, it doesn't work.

pawn Код:
if(strcmp(PlayerInfo[playerid][pBankPinCode],inputtext, true ) == 0 )
Everything I type in, will accepted.
I Just want to comapre the PIN-Code with the inputtext.
Reply
#2

pawn Код:
if(!strcmp(String1, String2)) {
/*If they are the same*/
}

if(strcmp(String1, String2) == -1) {
/*If they are not the same*/
}
Reply
#3

dont work

pawn Код:
if(!strcmp(PlayerInfo[playerid][pBankPinCode],inputtext))
        {
            format(string, sizeof(string), "Einzahlung \nAuszahlung \nKontostand");
            ShowPlayerDialog(playerid, 105, DIALOG_STYLE_LIST, "Bank", string, "Auswдhlen", "Abbrechen");
            return 1;
        }
Reply
#4

It can't be:

Код:
if(PlayerInfo[playerid][pBankPinCode] == strval(inputtext))
?
Reply
#5

Yes, i tried it myself out, works but thanks for help
Reply
#6

Quote:
Originally Posted by Jony_King
Посмотреть сообщение
dont work
They do work, you were just trying to put integers into it.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)