Restricted skins
#1

Ok i need to make a coding which restricts players that are NOT vips from spawing with the skin from under onplayerrequestclass my coding hasnt been working could someone help out real quick


PHP код:
        case 28 .. 29:
        {
            
gTeam[playerid] = VIPS;
            
ShowClassTextdraw(playeridred"Premium Accounts","GAZA UTES");
            if(
pInfo[playerid][VIP] < 1) return SendClientMessage(playerid,-1,"You are not a Premium Member..");
            return 
0;
          }
    } 
Reply
#2

You should check whether he is a VIP or not before setting his team to VIP.

PHP код:
case 28 .. 29
           { 
            if(
pInfo[playerid][VIP] < 1) return SendClientMessage(playerid,-1,"You are not a Premium Member.."); 
            
gTeam[playerid] = VIPS
            
ShowClassTextdraw(playeridred"Premium Accounts","GAZA UTES"); 
            return 
0
          } 
    } 
Reply
#3

Quote:
Originally Posted by AjaxM
Посмотреть сообщение
You should check whether he is a VIP or not before setting his team to VIP.

PHP код:
case 28 .. 29
           { 
            if(
pInfo[playerid][VIP] < 1) return SendClientMessage(playerid,-1,"You are not a Premium Member.."); 
            
gTeam[playerid] = VIPS
            
ShowClassTextdraw(playeridred"Premium Accounts","GAZA UTES"); 
            return 
0
          } 
    } 
Well even before you had suggested this , i did that already but it didnt work..
Reply
#4

PHP код:
new g_Classid[MAX_PLAYERS] = {-1, ...};
public 
OnPlayerRequestClass(playeridclassid) {
         
g_Classid[playerid] = classid;
         return 
true;
public 
OnPlayerRequestSpawn(playerid) {
       if((
g_Classid[playerid] == 28 || g_Classid[playerid] == 29) && pInfo[playerid][VIP] < 1) {
       
ShowClassTextdraw(playeridred"Premium Accounts","GAZA UTES"); 
       return;
       }
   }
   return 
true
Reply
#5

Quote:
Originally Posted by ISmokezU
Посмотреть сообщение
PHP код:
new g_Classid[MAX_PLAYERS] = {-1, ...};
public 
OnPlayerRequestClass(playeridclassid) {
         
g_Classid[playerid] = classid;
         return 
true;
public 
OnPlayerRequestSpawn(playerid) {
       if((
g_Classid[playerid] == 28 || g_Classid[playerid] == 29) && pInfo[playerid][VIP] < 1) {
       
ShowClassTextdraw(playeridred"Premium Accounts","GAZA UTES"); 
       return;
       }
   }
   return 
true
Please explain the coding you have posted , cause i dont think you understand what i needed
Reply
#6

What you want, You cannot use requesting class for that you have to use requesting spawn what i did is check for your classid 28 & 29 check if the playerid VIP level is below one and prevent them from spawning, Isn't that you wanted?
Reply
#7

Quote:
Originally Posted by ISmokezU
Посмотреть сообщение
What you want, You cannot use requesting class for that you have to use requesting spawn what i did is check for your classid 28 & 29 check if the playerid VIP level is below one and prevent them from spawning, Isn't that you wanted?
Mhmm... But i already made the coding what i wanted , but thanks for the response
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)