10.04.2016, 14:22
Код:
public HexToDec(hex[])
public HexToDec(hex[])
{
new st[1];
new result,Float:in;
result = 0;
in = 0;
while(strlen(hex) != 0)
{
//strins(st, hex[strlen(hex)-1], 0, 1);
strmid(st, hex, strlen(hex), strlen(hex));
strdel(hex,strlen(hex)-1,strlen(hex));
result = result + GetVal(st)*floatround(floatpower(16, in),floatround_ceil);
in = in+1;
}
return result;
}

