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


C# IUnrealStream.ReadInt32方法代码示例

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


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

示例1: Deserialize

 public void Deserialize( IUnrealStream stream )
 {
     UncompressedOffset = stream.ReadInt32();
     UncompressedSize = stream.ReadInt32();
     CompressedOffset = stream.ReadInt32();
     CompressedSize = stream.ReadInt32();
 }
开发者ID:jjbott,项目名称:Unreal-Library,代码行数:7,代码来源:UnrealPackageCompression.cs

示例2: Deserialize

            public void Deserialize( IUnrealStream stream )
            {
                _StartU = stream.ReadInt32();
                _StartV = stream.ReadInt32();

                _USize = stream.ReadInt32();
                _VSize = stream.ReadInt32();

                _TextureIndex = stream.ReadByte();
            }
开发者ID:jjbott,项目名称:Unreal-Library,代码行数:10,代码来源:UFont.cs

示例3: Deserialize

        public void Deserialize( IUnrealStream stream )
        {
#if APB
            if( stream.Package.Build == UnrealPackage.GameBuild.BuildName.APB && stream.Package.LicenseeVersion >= 32 )
            {
                stream.Skip( 16 );
            }
#endif
            ExportsCount = stream.ReadInt32();
            NamesCount = stream.ReadInt32();
            if( stream.Version >= VNetObjectsCount )
            {
                NetObjectsCount = stream.ReadInt32();
            }
        }
开发者ID:jjbott,项目名称:Unreal-Library,代码行数:15,代码来源:UGenerationTableItem.cs

示例4: Deserialize

 public void Deserialize( IUnrealStream stream )
 {
     Console.WriteLine( "Reading import " + Index + " at " + stream.Position );
     PackageName         = stream.ReadNameReference();
     _ClassName          = stream.ReadNameReference();
     ClassIndex         = (int)_ClassName;
     OuterIndex          = stream.ReadInt32(); // ObjectIndex, though always written as 32bits regardless of build.
     ObjectName          = stream.ReadNameReference();
 }
开发者ID:jjbott,项目名称:Unreal-Library,代码行数:9,代码来源:UImportTableItem.cs

示例5: Deserialize

            public void Deserialize( IUnrealStream stream )
            {
                Class = stream.ReadObjectIndex();

                // Deep
                stream.ReadInt32();

                // ScriptTextCRC
                stream.ReadUInt32();
            }
开发者ID:jjbott,项目名称:Unreal-Library,代码行数:10,代码来源:UClass.cs

示例6: Deserialize

            public void Deserialize( IUnrealStream stream )
            {
                if( stream.Version >= 63 )
                {
                    // Offset to (Width = ...)
                    WidthOffset = stream.ReadUInt32();

                    long opos = stream.Position;
                    stream.Seek( WidthOffset, System.IO.SeekOrigin.Begin );
                    Width = stream.ReadUInt32();
                    Height = stream.ReadUInt32();
                    stream.Seek( opos, System.IO.SeekOrigin.Begin );
                }

                int mipMapSize = stream.ReadIndex();
                Pixels = new int[mipMapSize];
                switch( Owner._Format.Decompile().Substring( 6 ) )
                {
                    case "TEXF_RGBA8": case "5":
                        for( int i = 0; i < mipMapSize; ++ i )
                        {
                            Pixels[i] = stream.ReadInt32();
                        }
                        break;

                    case "TEXF_DXT1": case "3":
                        for( int i = 0; i < mipMapSize / 2; ++ i )
                        {
                            byte c = stream.ReadByte();
                            Pixels[i ++] = c & 0xF0;
                            Pixels[i] = c & 0x0F;
                        }

                        // PostProcess:
                        // 4x4 4bit per pixel, 16bit per color: 5bits red; 6bits green; 5bits blue.
                        //
                        break;
                }

                // Width, Height. See above!
                stream.Skip( 8 );
                BitsWidth = stream.ReadByte();
                BitsHeight = stream.ReadByte();
            }
开发者ID:jjbott,项目名称:Unreal-Library,代码行数:44,代码来源:UTexture.cs

示例7: Serialize

        //public Dictionary<int, int> Components;
        //public List<int> NetObjects;
        #endregion

        // @Warning - Only supports Official builds.
        public void Serialize( IUnrealStream stream )
        {
            stream.Write( ClassTable.Object );
            stream.Write( SuperTable.Object );
            stream.Write( (int)OuterTable.Object );

            stream.Write( ObjectName );

            if( stream.Version >= VArchetype )
            {
                ArchetypeIndex = stream.ReadInt32();
            }
            stream.UW.Write( stream.Version >= VObjectFlagsToULONG ? ObjectFlags : (uint)ObjectFlags );
            stream.WriteIndex( SerialSize );    // Assumes SerialSize has been updated to @Object's buffer size.
            if( SerialSize > 0 || stream.Version >= VSerialSizeConditionless )
            {
                // SerialOffset has to be set and written after this object has been serialized.
                stream.WriteIndex( SerialOffset );  // Assumes the same as @SerialSize comment.
            }

            // TODO: Continue.
        }
开发者ID:jjbott,项目名称:Unreal-Library,代码行数:27,代码来源:UExportTableItem.cs

示例8: Deserialize

 public override void Deserialize( IUnrealStream stream )
 {
     var label = String.Empty;
     int labelPos = -1;
     do
     {
         if( label != String.Empty )
         {
             Decompiler._Labels.Add
             (
                 new ULabelEntry
                 {
                     Name = label,
                     Position = labelPos
                 }
             );
         }
         label = stream.ReadName();
         Decompiler.AlignNameSize();
         labelPos = stream.ReadInt32();
         Decompiler.AlignSize( sizeof(int) );
     } while( String.Compare( label, "None", StringComparison.OrdinalIgnoreCase ) != 0 );
 }
开发者ID:hanfling,项目名称:Unreal-Library,代码行数:23,代码来源:JumpTokens.cs

示例9: Deserialize

        public void Deserialize( IUnrealStream stream )
        {
            ClassIndex      = stream.ReadObjectIndex();
            SuperIndex      = stream.ReadObjectIndex();
            OuterIndex      = stream.ReadInt32(); // ObjectIndex, though always written as 32bits regardless of build.
#if BIOSHOCK
            if( stream.Package.Build == UnrealPackage.GameBuild.BuildName.Bioshock && stream.Version >= 132 )
            {
                stream.Skip( sizeof(int) );
            }
#endif
            ObjectName  = stream.ReadNameReference();

            if( stream.Version >= VArchetype )
            {
                ArchetypeIndex = stream.ReadInt32();
            }

            _ObjectFlagsOffset = stream.Position;
            ObjectFlags = stream.ReadUInt32();
            if( stream.Version >= VObjectFlagsToULONG
#if BIOSHOCK
                || (stream.Package.Build == UnrealPackage.GameBuild.BuildName.Bioshock && stream.Package.LicenseeVersion >= 40)
#endif
                )
            {
                ObjectFlags = (ObjectFlags << 32) | stream.ReadUInt32();
            }

            SerialSize = stream.ReadIndex();
            if( SerialSize > 0 || stream.Version >= VSerialSizeConditionless )
            {
                SerialOffset = stream.ReadIndex();
            }
#if BIOSHOCK
            if( stream.Package.Build == UnrealPackage.GameBuild.BuildName.Bioshock && stream.Version >= 130 )
            {
                stream.Skip( sizeof(int) );
            }
#endif
            if( stream.Version < 220 )
                return;

            if( stream.Version < 543
#if ALPHAPROTOCOL
                && stream.Package.Build != UnrealPackage.GameBuild.BuildName.AlphaProtcol
#endif
#if TRANSFORMERS
                && (stream.Package.Build != UnrealPackage.GameBuild.BuildName.Transformers || stream.Package.LicenseeVersion < 37)
#endif
                )
            {
                int componentMapCount = stream.ReadInt32();
                stream.Skip( componentMapCount * 12 );
                //if( componentMapCount > 0 )
                //{
                //    Components = new Dictionary<int, int>( componentMapCount );
                //    for( int i = 0; i < componentMapCount; ++ i )
                //    {
                //        Components.Add( stream.ReadNameIndex(), stream.ReadObjectIndex() );
                //    }
                //}
            }

            if( stream.Version < 247 )
                return;

            ExportFlags = stream.ReadUInt32();
            if( stream.Version < 322 )
                return;
#if TRANSFORMERS
            if( stream.Package.Build == UnrealPackage.GameBuild.BuildName.Transformers && stream.Package.LicenseeVersion >= 116 )
            {
                var flag = stream.ReadByte();
                if( flag == 0 )
                {
                    return;
                }
            }
#endif
#if BIOSHOCK
            if( stream.Package.Build == UnrealPackage.GameBuild.BuildName.Bioshock_Infinite )
            {
                var unk = stream.ReadUInt32();
                if( unk == 1 )
                {
                    var flags = stream.ReadUInt32();
                    if( (flags & 1) != 0x0 )
                    {
                        stream.ReadUInt32();
                    }
                    stream.Skip( 16 );  // guid
                    stream.ReadUInt32();    // 01000020
                }
                return;
            }
#endif
#if MKKE
            if( stream.Package.Build != UnrealPackage.GameBuild.BuildName.MKKE )
            {            
//.........这里部分代码省略.........
开发者ID:jjbott,项目名称:Unreal-Library,代码行数:101,代码来源:UExportTableItem.cs

示例10: Deserialize

 public override void Deserialize( IUnrealStream stream )
 {
     // Version
     stream.ReadInt32();
     // Line
     stream.ReadInt32();
     // Pos
     stream.ReadInt32();
     // Code
     stream.ReadByte();
     Decompiler.AlignSize( 13 );
 }
开发者ID:Dybuk,项目名称:Unreal-Library,代码行数:12,代码来源:OtherTokens.cs

示例11: Deserialize

 public override void Deserialize( IUnrealStream stream )
 {
     Value = stream.ReadInt32();
     Decompiler.AlignSize( sizeof(int) );
 }
开发者ID:jjbott,项目名称:Unreal-Library,代码行数:5,代码来源:ConstTokens.cs


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