vip levels...
#1

hey guys i want to start creating a base for a simple vip system using djson..
emmm a little question
how to make 3 vip levels
by defining or enum?
Reply
#2

enum
Reply
#3

yes but howto use it with enum..


like that:
pawn Код:
enum VIP
{
Vip 1,
Vip 2,
Vip 3
}
new Pinfo[MAX_PLAYERS][VIP];
?
Reply
#4

You could always do

pawn Код:
new IsVip[MAX_PLAYERS];

//VIP Thing
IsVip[playerid] = 1; // change to 2, 3, 4, etc for higher levels
Reply
#5

nah no because i want to use it like that
if(Pinfo[playerid][VIP] <1) etc..
Reply
#6

pawn Код:
enum PlayerInfo
{
    VIP
};
new Pinfo[MAX_PLAYERS][PlayerInfo];
Reply
#7

Quote:
Originally Posted by Kostas'
Посмотреть сообщение
pawn Код:
enum PlayerInfo
{
    VIP
};
new Pinfo[MAX_PLAYERS][PlayerInfo];
hmm kai meta na kanw allo enum me to vip?
Reply
#8

oxi, mono ena kai meta
pawn Код:
CMD:setvip(playerid, params[])
{
    new id, lvl;
    // blabla...
    if(lvl > 3 || lvl < 0) return SendClientMessage(playerid, -1, "The level must be between 0 and 3");
    // Rest Of Code
    Pinfo[id][VIP] = lvl;
    return 1;
}
Reply
#9

Both talk English here. This section ain't a foreign language section.
Reply
#10

Quote:
Originally Posted by Kingunit
Посмотреть сообщение
Both talk English here. This section ain't a foreign language section.
Sorry for this. For people didn't understand the text.
Quote:
Originally Posted by vassilis
Посмотреть сообщение
hmm kai meta na kanw allo enum me to vip?
English: Should I do another enum, with vip?

Quote:
Originally Posted by Kostas'
Посмотреть сообщение
oxi, mono ena kai meta
pawn Код:
CMD:setvip(playerid, params[])
{
    new id, lvl;
    // blabla...
    if(lvl > 3 || lvl < 0) return SendClientMessage(playerid, -1, "The level must be between 0 and 3");
    // Rest Of Code
    Pinfo[id][VIP] = lvl;
    return 1;
}
English: No. Only one.
pawn Код:
CMD:setvip(playerid, params[])
{
    new id, lvl;
    // blabla...
    if(lvl > 3 || lvl < 0) return SendClientMessage(playerid, -1, "The level must be between 0 and 3");
    // Rest Of Code
    Pinfo[id][VIP] = lvl;
    return 1;
}
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)