Ejemplo n.º 1
0
    internal static Class16 smethod_0(BinaryReader A_0, Class16 A_1)
    {
        if (A_1 == null)
        {
            A_1 = new Class16();
        }
        int num = A_0.ReadUInt16();

        A_1.method_61(Class624.smethod_1(((Word97Color)num) & (Word97Color.LightGray | Word97Color.DarkGray)));
        A_1.method_57(Class624.smethod_1((Word97Color)((num & 0x3e0) >> 5)));
        A_1.method_63((TextureStyle)((num & 0xfc00) >> 10));
        return(A_1);
    }
Ejemplo n.º 2
0
    internal static void smethod_1(Class581 A_0, CharacterFormat A_1)
    {
        int num = 6;

        if (A_1 == null)
        {
            A_1 = new CharacterFormat(A_0.Interface50.imethod_0());
        }
        Class394 class2 = A_0.imethod_1();

        while (class2.method_19())
        {
            string str;
            if (((str = class2.method_1()) != null) && (str != BookmarkStart.b("師崭夯嘱瀳匵吷", num)))
            {
                if (!(str == BookmarkStart.b("師崭夯嘱昳", num)))
                {
                    if (str == BookmarkStart.b("師崭夯嘱昳昵䨷", num))
                    {
                        int num3 = Class114.smethod_7(class2.method_3());
                        if (num3 != -2147483648)
                        {
                            A_1.SetAttr(30, num3);
                        }
                    }
                }
                else
                {
                    int num2 = Class114.smethod_7(class2.method_3());
                    if ((num2 != -2147483648) && (num2 != class2.method_58()))
                    {
                        A_1.SetAttr(40, num2);
                    }
                }
            }
        }
        smethod_2(A_0, A_1);
        smethod_4(A_0, A_1);
    }
Ejemplo n.º 3
0
    internal static Class16 smethod_1(BinaryReader A_0, Class16 A_1)
    {
        Color empty;

        if (A_1 == null)
        {
            A_1 = new Class16();
        }
        int num = A_0.ReadInt32();

        if (num == -16777216)
        {
            empty = Color.Empty;
        }
        else
        {
            empty = Class624.smethod_7(num);
        }
        A_1.method_61(empty);
        num = A_0.ReadInt32();
        if (num == -16777216)
        {
            empty = Color.Empty;
        }
        else
        {
            empty = Class624.smethod_7(num);
        }
        A_1.method_57(empty);
        A_1.method_63(Class955.smethod_12((TextureStyle)A_0.ReadUInt16()));
        if (A_1.method_62() == TextureStyle.TextureNil)
        {
            A_1.method_57(Color.Empty);
            A_1.method_61(Color.Empty);
        }
        return(A_1);
    }
Ejemplo n.º 4
0
        public void a(Stream A_0, Stream A_1)
        {
            byte[] array = new byte[A_0.Length];
            A_0.Read(array, 0, array.Length);               // array.Length --> .vlt FileSize
            this.ms2       = new MemoryStream(array);
            this.genc0list = new List <UnknownC0>();
            BinaryReader a_ = new BinaryReader(this.ms2);
            UnknownC0    c;

            while ((c = this.a(a_)) != null)
            {
                this.genc0list.Add(c);
            }

            this.Trim();

            UnknownDH dh = this.a(VLTOtherValue.TABLE_START) as UnknownDH;

            for (int i = 0; i < dh.asa1.Length; ++i)
            {
                dh.asa1[i].b(a_);                   // TODO read vs b? b, DEFINITELY b
            }
            if (A_1 == null)
            {
                DirectoryInfo directoryInfo = new DirectoryInfo(this.directory);
                UnknownBA     ba            = this.a(VLTOtherValue.VLTMAGIC) as UnknownBA;
                string        text          = ba.sa1[1];
                FileInfo[]    files         = directoryInfo.GetFiles(text);
                if (files.Length == 0)
                {
                    throw new Exception("Required file " + text + " was not found.");
                }
                A_1   = new FileStream(files[0].FullName, FileMode.Open, FileAccess.ReadWrite);
                array = new byte[A_1.Length];
                A_1.Read(array, 0, array.Length);
                A_1.Close();
            }
            else
            {
                array = new byte[A_1.Length];
                A_1.Read(array, 0, array.Length);
            }
            this.ms1 = new MemoryStream(array);
            a_       = new BinaryReader(this.ms1);
            this.ms1.Seek(0L, SeekOrigin.Begin);
            c = this.a(a_);
            c.e1.seekToDataStart(this.ms1);
            if (c.e1.ce1 == VLTOtherValue.BINMAGIC)
            {
                long num = this.ms1.Position + c.e1.dataSize();
                while (this.ms1.Position < num)
                {
                    string text2 = UnknownAP.a(a_);
                    if (text2 != "")
                    {
                        HashTracker.addHashFromVLTDB(text2);
                    }
                }
            }
            UnknownA8 a = this.a(VLTOtherValue.TABLE_END) as UnknownA8;

            a.a(this.ms1);
        }