Exemplo n.º 1
0
        public override void Build(MetaBuilder mb, bool isRoot = false)
        {
            if (this.Nodes != null)
            {
                this.MetaStructure.Nodes = mb.AddItemArrayPtr(MetaName.CScenarioChainingNode, this.Nodes.Select(e => { e.Build(mb); return(e.MetaStructure); }).ToArray());
            }
            MCScenarioChainingNode.AddEnumAndStructureInfo(mb);

            if (this.Edges != null)
            {
                this.MetaStructure.Edges = mb.AddItemArrayPtr(MetaName.CScenarioChainingEdge, this.Edges.Select(e => { e.Build(mb); return(e.MetaStructure); }).ToArray());
            }
            MCScenarioChainingEdge.AddEnumAndStructureInfo(mb);

            if (this.Chains != null)
            {
                this.MetaStructure.Chains = mb.AddItemArrayPtr(MetaName.CScenarioChain, this.Chains.Select(e => { e.Build(mb); return(e.MetaStructure); }).ToArray());
            }
            MCScenarioChain.AddEnumAndStructureInfo(mb);


            MUnk_4023740759.AddEnumAndStructureInfo(mb);

            if (isRoot)
            {
                mb.AddItem(this.MetaName, this.MetaStructure);

                this.Meta = mb.GetMeta();
            }
        }
Exemplo n.º 2
0
        public override void Build(MetaBuilder mb, bool isRoot = false)
        {
            this.MetaStructure.NodeIndexFrom = this.NodeIndexFrom;
            this.MetaStructure.NodeIndexTo   = this.NodeIndexTo;
            this.MetaStructure.Action        = this.Action;
            this.MetaStructure.NavMode       = this.NavMode;
            this.MetaStructure.NavSpeed      = this.NavSpeed;

            MCScenarioChainingEdge.AddEnumAndStructureInfo(mb);

            if (isRoot)
            {
                mb.AddItem(this.MetaName, this.MetaStructure);

                this.Meta = mb.GetMeta();
            }
        }
Exemplo n.º 3
0
        public override void Parse(MetaFile meta, Unk_4023740759 Unk_4023740759)
        {
            this.Meta          = meta;
            this.MetaStructure = Unk_4023740759;

            var Nodes = MetaUtils.ConvertDataArray <CScenarioChainingNode>(meta, Unk_4023740759.Nodes);

            this.Nodes = Nodes?.Select(e => { var msw = new MCScenarioChainingNode(); msw.Parse(meta, e); return(msw); }).ToList();

            var Edges = MetaUtils.ConvertDataArray <CScenarioChainingEdge>(meta, Unk_4023740759.Edges);

            this.Edges = Edges?.Select(e => { var msw = new MCScenarioChainingEdge(); msw.Parse(meta, e); return(msw); }).ToList();

            var Chains = MetaUtils.ConvertDataArray <CScenarioChain>(meta, Unk_4023740759.Chains);

            this.Chains = Chains?.Select(e => { var msw = new MCScenarioChain(); msw.Parse(meta, e); return(msw); }).ToList();
        }