예제 #1
0
        public MoveMultipleBuildingsCommand(PacketReader br)
        {
            m_vBuildingsToMove = new List <BuildingToMove>();
            var buildingCount = br.ReadInt32WithEndian();

            for (var i = 0; i < buildingCount; i++)
            {
                var buildingToMove = new BuildingToMove();
                buildingToMove.X            = br.ReadInt32WithEndian();
                buildingToMove.Y            = br.ReadInt32WithEndian();
                buildingToMove.GameObjectId = br.ReadInt32WithEndian();
                m_vBuildingsToMove.Add(buildingToMove);
            }
            br.ReadInt32WithEndian();
        }
예제 #2
0
        internal override void Decode()
        {
            this.m_vBuildingsToMove = new List <BuildingToMove>();
            var buildingCount = this.Reader.ReadInt32();

            for (var i = 0; i < buildingCount; i++)
            {
                var buildingToMove = new BuildingToMove
                {
                    X            = this.Reader.ReadInt32(),
                    Y            = this.Reader.ReadInt32(),
                    GameObjectId = this.Reader.ReadInt32()
                };
                this.m_vBuildingsToMove.Add(buildingToMove);
            }
            this.Reader.ReadInt32();
        }