Esempio n. 1
0
        public void LoadBodySetup(int setup)
        {
            if (setup == -1)
            {
                return;
            }
            BodySetup = setup - 1;
            if (BodySetup < 0 || BodySetup >= Pcc.Header.ExportCount)
            {
                return;
            }
            byte[]       buff = Pcc.EntryToBuff(BodySetup);
            string       c    = Pcc.getClassName(Pcc.Export[BodySetup].Class);
            UnrealObject UOb  = new UnrealObject(buff, c, Pcc.names);
            string       l    = Path.GetDirectoryName(Application.ExecutablePath);

            if (File.Exists(l + "\\exec\\DefaultProp.xml"))
            {
                UOb.UUkn.UPR.ImportDefinitionsXML(l + "\\exec\\DefaultProp.xml");
            }
            List <UPropertyReader.Property> p = UOb.UUkn.Properties;

            for (int i = 0; i < p.Count; i++)
            {
            }
        }
Esempio n. 2
0
        public void ReadObjects(int off)
        {
            int count = BitConverter.ToInt32(memory, off);

            LObjects = new List <LevelObject>();
            int pos = off + 4;

            for (int i = 0; i < count; i++)
            {
                LevelObject l = new LevelObject();
                l.entry = BitConverter.ToInt32(memory, pos) - 1;
                l.cls   = "";
                l.name  = "";
                if (l.entry >= 0 && l.entry < pcc.Export.Length)
                {
                    l.name = pcc.names[pcc.Export[l.entry].Name];
                    l.cls  = pcc.getClassName(pcc.Export[l.entry].Class);
                }
                LObjects.Add(l);
                pos += 4;
            }
        }