/// <summary>
        /// This method decodes a message from a byte list
        /// </summary>
        /// <param name="bytes"></param>
        virtual public void Decode(ByteList bytes)
        {
            Int16 objType   = bytes.GetInt16();
            Int16 objLength = bytes.GetInt16();

            bytes.SetNewReadLimit(objLength);

            MessageNr      = bytes.GetDistributableObject() as MessageNumber;
            ConversationId = bytes.GetDistributableObject() as MessageNumber;

            bytes.RestorePreviosReadLimit();
        }
        override public void Decode(ByteList bytes)
        {
            Int16 objType   = bytes.GetInt16();
            Int16 objLength = bytes.GetInt16();

            bytes.SetNewReadLimit(objLength);

            base.Decode(bytes);

            ComponentId  = bytes.GetInt16();
            ToSquare     = bytes.GetDistributableObject() as FieldLocation;
            EnablingTick = bytes.GetDistributableObject() as Tick;

            bytes.RestorePreviosReadLimit();
        }
Exemple #3
0
        override public void Decode(ByteList bytes)
        {
            Int16 objType   = bytes.GetInt16();
            Int16 objLength = bytes.GetInt16();

            bytes.SetNewReadLimit(objLength);

            base.Decode(bytes);

            ThrowingBrilliantStudentId = bytes.GetInt16();
            Bomb          = bytes.GetDistributableObject() as Bomb;
            TowardsSquare = bytes.GetDistributableObject() as FieldLocation;
            EnablingTick  = bytes.GetDistributableObject() as Tick;

            bytes.RestorePreviosReadLimit();
        }
        override public void Decode(ByteList bytes)
        {
            Int16 objType   = bytes.GetInt16();
            Int16 objLength = bytes.GetInt16();

            bytes.SetNewReadLimit(objLength);

            base.Decode(bytes);

            Resource = bytes.GetDistributableObject();

            bytes.RestorePreviosReadLimit();
        }
Exemple #5
0
        override public void Decode(ByteList bytes)
        {
            Int16 objType   = bytes.GetInt16();
            Int16 objLength = bytes.GetInt16();

            bytes.SetNewReadLimit(objLength);

            base.Decode(bytes);

            ComponentId    = bytes.GetInt16();
            TickToValidate = bytes.GetDistributableObject() as Tick;

            bytes.RestorePreviosReadLimit();
        }
Exemple #6
0
        override public void Decode(ByteList bytes)
        {
            Int16 objType   = bytes.GetInt16();
            Int16 objLength = bytes.GetInt16();

            bytes.SetNewReadLimit(objLength);

            base.Decode(bytes);

            GameId  = bytes.GetInt16();
            Winners = bytes.GetDistributableObject() as AgentList;

            bytes.RestorePreviosReadLimit();
        }
Exemple #7
0
        override public void Decode(ByteList bytes)
        {
            Int16 objType   = bytes.GetInt16();
            Int16 objLength = bytes.GetInt16();

            bytes.SetNewReadLimit(objLength);

            base.Decode(bytes);

            ZombieId     = bytes.GetInt16();
            TargetId     = bytes.GetInt16();
            EnablingTick = bytes.GetDistributableObject() as Tick;

            bytes.RestorePreviosReadLimit();
        }
        override public void Decode(ByteList bytes)
        {
            Int16 objType   = bytes.GetInt16();
            Int16 objLength = bytes.GetInt16();

            bytes.SetNewReadLimit(objLength);

            base.Decode(bytes);

            GameId          = bytes.GetInt16();
            GetResourceType = (PossibleResourceType)bytes.GetByte();
            EnablingTick    = bytes.GetDistributableObject() as Tick;

            bytes.RestorePreviosReadLimit();
        }
        override public void Decode(ByteList bytes)
        {
            Int16 objType   = bytes.GetInt16();
            Int16 objLength = bytes.GetInt16();

            bytes.SetNewReadLimit(objLength);

            base.Decode(bytes);

            IntResult = bytes.GetInt32();
            ObjResult = bytes.GetDistributableObject();
            Message   = bytes.GetString();

            bytes.RestorePreviosReadLimit();
        }
Exemple #10
0
        override public void Decode(ByteList bytes)
        {
            log.Debug("Decoding JoinGame");
            Int16 objType   = bytes.GetInt16();
            Int16 objLength = bytes.GetInt16();

            log.DebugFormat("objType={0}, objLength={1}", objType, objLength);

            bytes.SetNewReadLimit(objLength);

            base.Decode(bytes);

            GameId = bytes.GetInt16();
            log.DebugFormat("GameId={0}", GameId);
            AgentInfo = bytes.GetDistributableObject() as AgentInfo;
            log.DebugFormat("AgentInfo.AgentType={0}, ANumber={1}, FirstName={2}, LastName={3}", AgentInfo.AgentType, AgentInfo.ANumber, AgentInfo.FirstName, AgentInfo.LastName);

            bytes.RestorePreviosReadLimit();
            log.DebugFormat("Decoding of JoinGame Complete");
        }