there are many packets have been proto now such as
2500
10014
10010
10017
1004
1110
i can get the uint offets and its okay with meh
but like packet 2500 its gonna be a shit of 00(zeros)00 bec after converting or shifting whatever with these
PHP Code:
public static uint[] Read7BitEncodedInt(byte[] buffer)
{
List<uint> ptr2 = new List<uint>();
for (int i = 0; i < buffer.Length; )
{
if (i + 2 <= buffer.Length)
{
int tmp = buffer[i++];
if (tmp % 8 == 0)
while (true)
{
if (i + 1 > buffer.Length) break;
tmp = buffer[i++];
if (tmp < 128)
{
ptr2.Add((uint)tmp);
break;
}
else
{
int result = tmp & 0x7f;
if ((tmp = buffer[i++]) < 128)
{
result |= tmp << 7;
ptr2.Add((uint)result);
break;
}
else
{
result |= (tmp & 0x7f) << 7;
if ((tmp = buffer[i++]) < 128)
{
result |= tmp << 14;
ptr2.Add((uint)result);
break;
}
else
{
result |= (tmp & 0x7f) << 14;
if ((tmp = buffer[i++]) < 128)
{
result |= tmp << 21;
ptr2.Add((uint)result);
break;
}
else
{
result |= (tmp & 0x7f) << 21;
result |= (tmp = buffer[i++]) << 28;
ptr2.Add((uint)result);
break;
}
}
}
}
}
}
else break;
}
return ptr2.ToArray();
i hope anyone can help me with that xD








