Random Skins + Timer
#4

Quote:
Originally Posted by GaGlets®
Посмотреть сообщение
pawn Код:
new randomskins[skinsintotal(lines)][how many kommasdoyouhave]
So it owuld look like this.

pawn Код:
new randomskins[4][1] = {
   skin 1,
   skin 2,
   skin 3,
   skin 4
};
So at the comand you need to make a randoom.
pawn Код:
new rand = random(sizeof(randomskins));
SetPlayerSkin(playerid, rand);
I done it this way but the only skins it picks is CJ and that english guy with the fishing hat.. The skins i put down were a guy in a hoody (ID 29) and two mexican guys (47 and 4 so its like this

pawn Код:
new randomskins[4][1] = {
   29,
   47,
   48,
   285
};
pawn Код:
GivePlayerWeapon(playerid, 24, 99999);
                            GivePlayerWeapon(playerid, 3, 0);
                            GivePlayerWeapon(playerid, 41, 99999);
                            GivePlayerWeapon(playerid, 31, 99999);
                            CopOnDuty[playerid] = 1;
                            SetPlayerSkin(playerid, randa);
                            format(string, sizeof(string), "[LSPD:] %s is now an on duty police officer.",GetPlayerNameEx(playerid));
                            SendFactionTypeMessage(1, COLOR_LSPD, string);
                            return 1;
Changed from "rand" to "randa" due to a warning i got
Reply


Messages In This Thread
Random Skins + Timer - by Ritchie999 - 16.10.2010, 23:02
Re: Random Skins + Timer - by JaTochNietDan - 16.10.2010, 23:07
Re: Random Skins + Timer - by GaGlets(R) - 16.10.2010, 23:08
Re: Random Skins + Timer - by Ritchie999 - 16.10.2010, 23:24
Re: Random Skins + Timer - by JaTochNietDan - 16.10.2010, 23:28
Re: Random Skins + Timer - by mmrk - 16.10.2010, 23:29
Re: Random Skins + Timer - by Ritchie999 - 16.10.2010, 23:33
Re: Random Skins + Timer - by JaTochNietDan - 16.10.2010, 23:41
Re: Random Skins + Timer - by Ritchie999 - 16.10.2010, 23:44

Forum Jump:


Users browsing this thread: 4 Guest(s)