How to add all skins?
#1

i want to add all skins id 0 to id 299 i know how to add with

Код:
AddPlayerClass(blah);
but it would take so many days to add it up to 299

how can i add skins only with short code?
Reply
#2

pawn Код:
for(new i = 0; i < 299; i++)
{
    if(IsValidSkin(i)) AddPlayerClass(i, ...);
}
If you don't have a "IsValidSkin" function search around for one, or remove it.
Reply
#3

pawn Код:
public OnGameModeInit()
{
    for(new skinid = 0; skinid < 299; skinid++)
    {
        if(IsValidSkin(skinid))
        {
            AddPlayerClass(skinid, . . .);
        }
    }
    return true;
}

stock IsValidSkin(skinid)
{
    if(skinid < 0 || skinid > 299) return false;
    switch(skinid)
    {
        case 3, 4, 5, 6, 8, 42, 65, 74, 86, 119, 149, 208, 273, 289: return false;
    }
    return true;
}
Edit: Too late.
Reply
#4

If you are using 0.3d the "invalid" skins were added.
Reply
#5

CyberGhost code is working but wheres id 299
Reply
#6

Skins start with 0, so 299 = 298. Set it to 300. (My bad )
Reply
#7

thanks guys it work
Reply
#8

Lol when i added skin ongamemode, i had to do 1 by 1
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)