Query isnt working
#6

You would, but due to bug/feature in pawn compiler sizeof doesn't work for 2d arrays as you would expect. You can:
1. Simply use constant number equal to your password length
2. Define a constant:
pawn Код:
#define MAX_PASSWORD_LENGTH (128)

//say in your enum
enum E_PLAYER_DATA {
    //(...)
    Password[MAX_PASSWORD_LENGTH],
    //(...)
}
And then use MAX_PASSWORD_LENGTH.

Word of advice: avoid using common words in your enums, as you'll run into a lot of namespace clashes. I'd recommend something like
pawn Код:
//Do not do this
enum Player {
    Password
}
//Do this
enum E_PLAYER {
    E_PLAYER_PASSWORD
}
3. Use Zeex's compiler with this bug fixed
Reply


Messages In This Thread
Query isnt working - by sammp - 19.02.2016, 22:38
Re: Query isnt working - by LukeCourt - 20.02.2016, 00:10
Re: Query isnt working - by sammp - 20.02.2016, 00:15
Re: Query isnt working - by AmigaBlizzard - 20.02.2016, 11:51
Re: Query isnt working - by sammp - 20.02.2016, 13:45
Re: Query isnt working - by Misiur - 20.02.2016, 16:43

Forum Jump:


Users browsing this thread: 3 Guest(s)