当前位置: 首页>>代码示例>>C#>>正文


C# MpqFileStream.ReadInt32方法代码示例

本文整理汇总了C#中CrystalMpq.MpqFileStream.ReadInt32方法的典型用法代码示例。如果您正苦于以下问题:C# MpqFileStream.ReadInt32方法的具体用法?C# MpqFileStream.ReadInt32怎么用?C# MpqFileStream.ReadInt32使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在CrystalMpq.MpqFileStream的用法示例。


在下文中一共展示了MpqFileStream.ReadInt32方法的12个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。

示例1: Header

	   public Header(MpqFileStream stream)
	   {
		   DeadBeef = stream.ReadInt32();
		   SnoType  = stream.ReadInt32();
		   unknown1 = stream.ReadInt32();
		   unknown2 = stream.ReadInt32();
	   }
开发者ID:fortenbt,项目名称:mooege,代码行数:7,代码来源:MpqDataTypes.cs

示例2: TagMap

		   public TagMap(MpqFileStream stream)
		   {
			   tagmapsize = stream.ReadInt32();
			   TagMapEntry = new TagMapEntry[tagmapsize];
			   for (int i = 0; i < tagmapsize; i++)
			   {
				   TagMapEntry[i] = new TagMapEntry(stream);
			   }
		   }
开发者ID:fortenbt,项目名称:mooege,代码行数:9,代码来源:MpqDataTypes.cs

示例3: Vector2D

 public Vector2D(MpqFileStream stream)
 {
     Field0 = stream.ReadInt32();
     FIeld1 = stream.ReadInt32();
 }
开发者ID:SaintNeo,项目名称:mooege,代码行数:5,代码来源:Actor.cs

示例4: SerializeData

 public SerializeData(MpqFileStream stream)
 {
     Offset = stream.ReadInt32();
     Size = stream.ReadInt32();
 }
开发者ID:SaintNeo,项目名称:mooege,代码行数:5,代码来源:Actor.cs

示例5: WeightedLook

            public WeightedLook(MpqFileStream stream)
            {
                byte[] buf = new byte[64];                
                stream.Read(buf, 0, 64); LookLink = Encoding.ASCII.GetString(buf);
                i0 = stream.ReadInt32();

            }
开发者ID:SaintNeo,项目名称:mooege,代码行数:7,代码来源:Actor.cs

示例6: NavZoneDef

            public NavZoneDef(MpqFileStream stream)
            {
                long x;
                int NavCellCount = stream.ReadInt32();
                stream.Position += 12;

                var serNavCells = new SerializeData(stream);
                x = stream.Position;
                stream.Position = serNavCells.Offset + 16;

                //Navcells
                NavCells = new NavCell[NavCellCount];
                for (int i = 0; i < NavCellCount; i++)
                {
                    NavCells[i] = new NavCell(stream);
                }
                stream.Position = x;

                //NavCellLookups
                int NeighbourCount = stream.ReadInt32();
                stream.Position += 12;
                var serNavCellNeighbours = new SerializeData(stream);
                x = stream.Position;
                stream.Position = serNavCellNeighbours.Offset + 16;
                NavCellNeighbours = new NavCellLookup[NeighbourCount];
                for (int i = 0; i < NeighbourCount; i++)
                {
                    NavCellNeighbours[i] = new NavCellLookup(stream);
                }
                stream.Position = x;

                //NavGridSquares
                float f0 = stream.ReadFloat();
                float f1 = stream.ReadFloat();
                int i2 = stream.ReadInt32();
                var v0 = new Vector2D(stream);
                stream.Position += 12;
                var serGridSquares = new SerializeData(stream);
                x = stream.Position;
                stream.Position = serGridSquares.Offset + 16;
                GridSquares = new NavGridSquare[serGridSquares.Size/6];
                for (int i = 0; i < serGridSquares.Size/6; i++)
                {
                    GridSquares[i] = new NavGridSquare(stream);
                }
                stream.Position = x;

                //cell lookups
                int i3 = stream.ReadInt32();
                stream.Position += 12;
                var serCellLookups = new SerializeData(stream);
                x = stream.Position;
                stream.Position = serCellLookups.Offset + 16;
                CellLookups = new NavCellLookup[serCellLookups.Size/4];
                for (int i = 0; i < serCellLookups.Size/4; i++)
                {
                    CellLookups[i] = new NavCellLookup(stream);
                }
                stream.Position = x;

                //borderdata
                int i4 = stream.ReadInt32();
                stream.Position += 12;
                var serBorderData = new SerializeData(stream);
                x = stream.Position;
                stream.Position = serBorderData.Offset + 16;
                BorderData = new NavCellBorderData[serBorderData.Size/4];
                for (int i = 0; i < serBorderData.Size/4; i++)
                {
                    BorderData[i] = new NavCellBorderData(stream);
                }
            }
开发者ID:benracoon,项目名称:mooege,代码行数:72,代码来源:Scene.cs

示例7: NavCell

 public NavCell(MpqFileStream stream)
 {
     Min = new Vector3D(stream.ReadFloat(), stream.ReadFloat(), stream.ReadFloat());
     Max = new Vector3D(stream.ReadFloat(), stream.ReadFloat(), stream.ReadFloat());
     Flags = stream.ReadInt16();
     NeighbourCount = stream.ReadInt16();
     NeighborsIndex = stream.ReadInt32();
 }
开发者ID:benracoon,项目名称:mooege,代码行数:8,代码来源:Scene.cs

示例8: NavMeshDef

            public NavMeshDef(MpqFileStream stream)
            {
                SquaresCountX = stream.ReadInt32();
                SquaresCoountY = stream.ReadInt32();
                i0 = stream.ReadInt32();
                NavMeshSquareCount = stream.ReadInt32();
                f0 = stream.ReadFloat();
                serNavMeshArraySquares = new SerializeData(stream);
                long x = stream.Position;
                stream.Position = serNavMeshArraySquares.Offset + 16;

                NavMeshArraySquares = new NavMeshSquare[NavMeshSquareCount];
                for (int i = 0; i < NavMeshSquareCount; i++)
                {
                    NavMeshArraySquares[i] = new NavMeshSquare(stream);
                }

                stream.Position = x;
                stream.Position += 12;
                filename = new char[256];

                for (int i = 0; i < 256; i++)
                {
                    filename[i] = (char) stream.ReadByte(); // fix me / dark
                }
            }
开发者ID:benracoon,项目名称:mooege,代码行数:26,代码来源:Scene.cs

示例9: NavMeshSquare

 public NavMeshSquare(MpqFileStream stream)
 {
     f0 = stream.ReadFloat();
     Flags = stream.ReadInt32();
 }
开发者ID:benracoon,项目名称:mooege,代码行数:5,代码来源:Scene.cs

示例10: Marker

		   public Marker(MpqFileStream stream)
		   {
			   byte[] buf = new byte[128];
			   stream.Read(buf, 0, 128); Name = Encoding.ASCII.GetString(buf);
			   i0 = stream.ReadInt32();
			   PRTransform = new PRTransform(stream);
			   SNOName = new SNOName(stream);
			   serTagMap = new SerializeData(stream);
			   TagMap = stream.ReadInt32();
			   i1 = stream.ReadInt32();
			   i2 = stream.ReadInt32();
			   serMarkerLinks = new SerializeData(stream);
			   stream.Position += (3 * 4);
			   long x = stream.Position;
			   
			   if (serTagMap.Size > 0)
			   {
				   stream.Position = serTagMap.Offset + 16;
				   TM = new TagMap(stream);

			   }
			   stream.Position = x;
		   }
开发者ID:fortenbt,项目名称:mooege,代码行数:23,代码来源:MpqDataTypes.cs

示例11: TagMapEntry

		   public TagMapEntry(MpqFileStream stream)
		   {
			   i0 = stream.ReadInt32();
			   i1 = stream.ReadInt32();
			   f0 = stream.ReadFloat();
		   }
开发者ID:fortenbt,项目名称:mooege,代码行数:6,代码来源:MpqDataTypes.cs

示例12: SNOName

		   public SNOName(MpqFileStream stream)
		   {
			   int0 = stream.ReadInt32();
			   int1 = stream.ReadInt32();
		   }
开发者ID:fortenbt,项目名称:mooege,代码行数:5,代码来源:MpqDataTypes.cs


注:本文中的CrystalMpq.MpqFileStream.ReadInt32方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。