[HELP]Script skin
#1

Hello everyone, I have this script that includes all the designs of the selection class, but it lacks a the id 299, how can I fix this?. Also how can I do in class selection are two animations skin?

OnGameModeInit:

Код:
for(new i = 0; i < 299; i++) if(isValidSkin(i)) AddPlayerClass(i, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
out of everything

Код:
isValidSkin(skinid)
{
   switch(skinid)
   {
      case 3, 4, 5, 6, 8, 42, 65, 74, 86, 119, 149, 208, 268, 273, 289: return 0;
   }
   return 1;
}
Reply
#2

for(new i = 0; i < 300; i++) if(isValidSkin(i)) AddPlayerClass(i, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);

< = less than. If it is less than 299, 298 is the greatest skin id.
Reply
#3

ok then if I want him to do two animations in selecting the class of skin as I do?
Reply
#4

pawn Код:
public OnPlayerRequestClass(playerid, classid)
{
    new skinid = GetPlayerSkin(playerid);
    switch(skinid)
    {
        case 299: //If the skin is 299
        {
            //Set the player's animation here
        }
    }
    return 1;
}
Reply
#5

pawn Код:
public OnPlayerRequestClass( playerid, classid ) {
    new r = random( 2 );
    switch( r ) {
        case 0: ApplyAnimation( ... ); // Animation number 1.
        case 1: ApplyAnimation( ... ); // Animation number 2.
    }
    return 1;
}
@PotH3Ad: I don't think he only wants it for skin ID 299.
Reply
#6

there is a faster way?
Reply
#7

that all the designs must accomplish two different animations, but only two animations for all skin
Reply
#8

Switch is the fastest method I can think of...
Reply
#9

but I do it for each skin?
Reply
#10

some help ?
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)