コード例 #1
0
ファイル: MBINFile.cs プロジェクト: gregkwaste/MBINCompiler
        public void SetData(NMSTemplate template)
        {
            _io.Stream.SetLength(0x60);
            _io.Stream.Position = 0x60;

            _io.Writer.Write(template.SerializeBytes());
            Header.TemplateName = "c" + template.GetType().Name;
        }
コード例 #2
0
        public void SetData(NMSTemplate template)
        {
            _io.Stream.SetLength(0x60);
            _io.Stream.Position = 0x60;

            byte[] data = template.SerializeBytes();
            _io.Writer.Write(data);

            FileLength = (ulong)data.LongLength;

            Header.TemplateName = "c" + template.GetType().Name;
        }
コード例 #3
0
        public void SetData(NMSTemplate template)
        {
            _io.Stream.SetLength(0x60);
            _io.Stream.Position = 0x60;

            /*
             * // if we want to get the file size:
             * byte[] data = template.SerializeBytes();
             * _io.Writer.Write(data);
             *
             * this.FileLength = (ulong)data.LongLength;
             */

            // otherwise just do:
            _io.Writer.Write(template.SerializeBytes());

            Header.TemplateName = "c" + template.GetType().Name;
        }