/*-------------------------------------------------------------------*/
/*-------------------------------------------------------------------*/
private byte[] processIncomingPacket(byte[] data)
{
ClientPacket currentPacket;
Sequence sequenceOne = null;
Sequence sequenceTwo = null;
int length = 0;
sequenceOne = new Sequence(data);
if(sequenceOne.intValue() == 0x7fffffff && sequenceOne.isReliable())
return data;
else
{
serverSequence = sequenceOne;
sequenceTwo = new Sequence(data, 4);
if(serverSequence.isReliable())
{
if(serverSequence.intValue() > lastReliableSequence.intValue())
{
lastReliableSequence = new Sequence(serverSequence.intValue());
serverBit = serverBit ^ true;
}
}
if(sequenceTwo.isReliable() != clientBit)
{
clientBit = sequenceTwo.isReliable();
reliableReceived = true;
}
}
return data;