02.04.2018, 11:16
can anyone give me function IsValidCustomSkin pls?
or an example to store custom skin in an array and do if(CustomSkinArray ??
or an example to store custom skin in an array and do if(CustomSkinArray ??
error 002: only a single statement (or expression) can follow each "case" warning 215: expression has no effect warning 209: function "IsValidSkin" should return a value error 054: unmatched closing brace ("}")
IsValidSkin(skin) return (0 <= skin <= 311 && skin != 74);
error 002: only a single statement (or expression) can follow each "case"
warning 215: expression has no effect
warning 209: function "IsValidSkin" should return a value
error 054: unmatched closing brace ("}")
stock IsValidSkin(skinid)
{
switch(skinid)
{
case 0..73,75..311,25000..25007,26001..26011,27001: return true;
return false;
}
}
I got this error now
PHP код:
PHP код:
|
stock IsValidCustomSkin(skinid){ switch(skinid){ case 0..73,75..311,2000..30000: return true; } return false; }
stock IsValidSkin(skinid)
{
switch(skinid)
{
case 0..73,75..311,25000..25007,27001: return true;
case 26001..26011: //premium skins
{
if(Premium[playerid] < 2) return Error(playerid, "Can't use this skin");
}
}
return false;
}