コード例 #1
0
ファイル: CSManager.cs プロジェクト: THSJF/sjf
        public CSManager(Texture2D barrages_t, Texture2D mist_t, Texture2D dis_t)
        {
            this.csc         = new List <CrazyStorm>();
            this.esc         = new List <CrazyStorm>();
            this.barrages    = barrages_t;
            this.mist        = mist_t;
            this.dis         = dis_t;
            this.bgset       = new List <BarrageType>();
            this.conditions  = new Hashtable();
            this.results     = new Hashtable();
            this.type        = new Hashtable();
            this.conditions2 = new Hashtable();
            this.results2    = new Hashtable();
            this.results3    = new Hashtable();
            this.cconditions = new Hashtable();
            this.cresults    = new Hashtable();
            this.lconditions = new Hashtable();
            this.lresults    = new Hashtable();
            this.lresults2   = new Hashtable();
            this.type.Add((object)"正比", (object)0);
            this.type.Add((object)"固定", (object)1);
            this.type.Add((object)"正弦", (object)2);
            this.conditions.Add((object)"", (object)0);
            this.conditions.Add((object)"当前帧", (object)0);
            this.conditions.Add((object)"X坐标", (object)1);
            this.conditions.Add((object)"Y坐标", (object)2);
            this.conditions.Add((object)"半径", (object)3);
            this.conditions.Add((object)"半径方向", (object)4);
            this.conditions.Add((object)"条数", (object)5);
            this.conditions.Add((object)"周期", (object)6);
            this.conditions.Add((object)"角度", (object)7);
            this.conditions.Add((object)"范围", (object)8);
            this.conditions.Add((object)"宽比", (object)9);
            this.conditions.Add((object)"高比", (object)10);
            this.conditions.Add((object)"不透明度", (object)11);
            this.conditions.Add((object)"朝向", (object)12);
            this.results.Add((object)"X坐标", (object)0);
            this.results.Add((object)"Y坐标", (object)1);
            this.results.Add((object)"半径", (object)2);
            this.results.Add((object)"半径方向", (object)3);
            this.results.Add((object)"条数", (object)4);
            this.results.Add((object)"周期", (object)5);
            this.results.Add((object)"角度", (object)6);
            this.results.Add((object)"范围", (object)7);
            this.results.Add((object)"速度", (object)8);
            this.results.Add((object)"速度方向", (object)9);
            this.results.Add((object)"加速度", (object)10);
            this.results.Add((object)"加速度方向", (object)11);
            this.results.Add((object)"生命", (object)12);
            this.results.Add((object)"类型", (object)13);
            this.results.Add((object)"宽比", (object)14);
            this.results.Add((object)"高比", (object)15);
            this.results.Add((object)"R", (object)16);
            this.results.Add((object)"G", (object)17);
            this.results.Add((object)"B", (object)18);
            this.results.Add((object)"不透明度", (object)19);
            this.results.Add((object)"朝向", (object)20);
            this.results.Add((object)"子弹速度", (object)21);
            this.results.Add((object)"子弹速度方向", (object)22);
            this.results.Add((object)"子弹加速度", (object)23);
            this.results.Add((object)"子弹加速度方向", (object)24);
            this.results.Add((object)"横比", (object)25);
            this.results.Add((object)"纵比", (object)26);
            this.results.Add((object)"雾化效果", (object)27);
            this.results.Add((object)"消除效果", (object)28);
            this.results.Add((object)"高光效果", (object)29);
            this.results.Add((object)"拖影效果", (object)30);
            this.results.Add((object)"出屏即消", (object)31);
            this.results.Add((object)"无敌状态", (object)32);
            this.conditions2.Add((object)"", (object)0);
            this.conditions2.Add((object)"当前帧", (object)0);
            this.conditions2.Add((object)"X坐标", (object)1);
            this.conditions2.Add((object)"Y坐标", (object)2);
            this.results2.Add((object)"生命", (object)0);
            this.results2.Add((object)"类型", (object)1);
            this.results2.Add((object)"宽比", (object)2);
            this.results2.Add((object)"高比", (object)3);
            this.results2.Add((object)"R", (object)4);
            this.results2.Add((object)"G", (object)5);
            this.results2.Add((object)"B", (object)6);
            this.results2.Add((object)"不透明度", (object)7);
            this.results2.Add((object)"朝向", (object)8);
            this.results2.Add((object)"子弹速度", (object)9);
            this.results2.Add((object)"子弹速度方向", (object)10);
            this.results2.Add((object)"子弹加速度", (object)11);
            this.results2.Add((object)"子弹加速度方向", (object)12);
            this.results2.Add((object)"横比", (object)13);
            this.results2.Add((object)"纵比", (object)14);
            this.results2.Add((object)"雾化效果", (object)15);
            this.results2.Add((object)"消除效果", (object)16);
            this.results2.Add((object)"高光效果", (object)17);
            this.results2.Add((object)"拖影效果", (object)18);
            this.results2.Add((object)"出屏即消", (object)19);
            this.results2.Add((object)"无敌状态", (object)20);
            this.results3.Add((object)"速度", (object)0);
            this.results3.Add((object)"速度方向", (object)1);
            this.results3.Add((object)"加速度", (object)2);
            this.results3.Add((object)"加速度方向", (object)3);
            this.cconditions.Add((object)"", (object)0);
            this.cconditions.Add((object)"当前帧", (object)0);
            this.cconditions.Add((object)"X坐标", (object)1);
            this.cconditions.Add((object)"Y坐标", (object)2);
            this.cconditions.Add((object)"半宽", (object)3);
            this.cconditions.Add((object)"半高", (object)4);
            this.cresults.Add((object)"半宽", (object)0);
            this.cresults.Add((object)"半高", (object)1);
            this.cresults.Add((object)"启用圆形", (object)2);
            this.cresults.Add((object)"速度", (object)3);
            this.cresults.Add((object)"速度方向", (object)4);
            this.cresults.Add((object)"加速度", (object)5);
            this.cresults.Add((object)"加速度方向", (object)6);
            this.cresults.Add((object)"类型", (object)7);
            this.cresults.Add((object)"ID", (object)8);
            this.cresults.Add((object)"X坐标", (object)9);
            this.cresults.Add((object)"Y坐标", (object)10);
            this.lconditions.Add((object)"", (object)0);
            this.lconditions.Add((object)"当前帧", (object)0);
            this.lconditions.Add((object)"半径", (object)1);
            this.lconditions.Add((object)"半径方向", (object)2);
            this.lconditions.Add((object)"条数", (object)3);
            this.lconditions.Add((object)"周期", (object)4);
            this.lconditions.Add((object)"角度", (object)5);
            this.lconditions.Add((object)"范围", (object)6);
            this.lconditions.Add((object)"宽比", (object)7);
            this.lconditions.Add((object)"长度", (object)8);
            this.lconditions.Add((object)"不透明度", (object)9);
            this.lresults.Add((object)"半径", (object)0);
            this.lresults.Add((object)"半径方向", (object)1);
            this.lresults.Add((object)"条数", (object)2);
            this.lresults.Add((object)"周期", (object)3);
            this.lresults.Add((object)"角度", (object)4);
            this.lresults.Add((object)"范围", (object)5);
            this.lresults.Add((object)"速度", (object)6);
            this.lresults.Add((object)"速度方向", (object)7);
            this.lresults.Add((object)"加速度", (object)8);
            this.lresults.Add((object)"加速度方向", (object)9);
            this.lresults.Add((object)"生命", (object)10);
            this.lresults.Add((object)"类型", (object)11);
            this.lresults.Add((object)"宽比", (object)12);
            this.lresults.Add((object)"长度", (object)13);
            this.lresults.Add((object)"不透明度", (object)14);
            this.lresults.Add((object)"子弹速度", (object)15);
            this.lresults.Add((object)"子弹速度方向", (object)16);
            this.lresults.Add((object)"子弹加速度", (object)17);
            this.lresults.Add((object)"子弹加速度方向", (object)18);
            this.lresults.Add((object)"横比", (object)19);
            this.lresults.Add((object)"纵比", (object)20);
            this.lresults.Add((object)"高光效果", (object)21);
            this.lresults.Add((object)"出屏即消", (object)22);
            this.lresults.Add((object)"无敌状态", (object)23);
            this.lresults2.Add((object)"生命", (object)0);
            this.lresults2.Add((object)"类型", (object)1);
            this.lresults2.Add((object)"宽比", (object)2);
            this.lresults2.Add((object)"长度", (object)3);
            this.lresults2.Add((object)"不透明度", (object)4);
            this.lresults2.Add((object)"子弹速度", (object)5);
            this.lresults2.Add((object)"子弹速度方向", (object)6);
            this.lresults2.Add((object)"子弹加速度", (object)7);
            this.lresults2.Add((object)"子弹加速度方向", (object)8);
            this.lresults2.Add((object)"横比", (object)9);
            this.lresults2.Add((object)"纵比", (object)10);
            this.lresults2.Add((object)"高光效果", (object)11);
            this.lresults2.Add((object)"出屏即消", (object)12);
            this.lresults2.Add((object)"无敌状态", (object)13);
            StreamReader streamReader = new StreamReader(Cry.Decry("Content/Data/3.xna", 2));

            for (int index = 0; index < 228; ++index)
            {
                string      str         = streamReader.ReadLine();
                BarrageType barrageType = new BarrageType();
                barrageType.rect    = new Rectangle(int.Parse(str.Split('_')[1]), int.Parse(str.Split('_')[2]), int.Parse(str.Split('_')[3]), int.Parse(str.Split('_')[4]));
                barrageType.origin  = new Vector2((float)int.Parse(str.Split('_')[5]), (float)int.Parse(str.Split('_')[6]));
                barrageType.origin0 = new Vector2((float)int.Parse(str.Split('_')[5]), (float)int.Parse(str.Split('_')[6]));
                barrageType.pdr0    = (float)int.Parse(str.Split('_')[7]);
                if (str.Split('_')[8] != "")
                {
                    barrageType.color = int.Parse(str.Split('_')[8]);
                }
                else
                {
                    barrageType.color = -1;
                }
                this.bgset.Add(barrageType);
            }
            streamReader.Close();
        }
コード例 #2
0
        public CrazyStorm(
            GraphicsDevice g,
            CSManager csm_c,
            bool bansound_b,
            string filename,
            Vector2 Player)
        {
            shoot    = new List <byte>();
            id       = filename;
            bgset    = new List <BarrageType>();
            csm      = csm_c;
            bansound = bansound_b;
            layerm   = new LayerManager();
            center   = new Center();
            time     = new Time(csm, this, layerm);
            StreamReader streamReader = new StreamReader(Cry.Decry("Content/Data/" + filename + ".xna", 0));

            if (streamReader.ReadLine() == "Crazy Storm Data 1.01")
            {
                string source = streamReader.ReadLine();
                if (File.Exists("Content/Data/" + filename + ".dat"))
                {
                    tex = Texture2D.FromFile(g, Cry.Decry("Content/Data/" + filename + ".dat", 0));
                }
                if (source.Contains("Types"))
                {
                    int num = int.Parse(source.Split(' ')[0]);
                    for (int index = 0; index < num; ++index)
                    {
                        string      str         = streamReader.ReadLine();
                        BarrageType barrageType = new BarrageType {
                            name    = str.Split('_')[0],
                            rect    = new Rectangle(int.Parse(str.Split('_')[1]), int.Parse(str.Split('_')[2]), int.Parse(str.Split('_')[3]), int.Parse(str.Split('_')[4])),
                            origin  = new Vector2(int.Parse(str.Split('_')[5]), int.Parse(str.Split('_')[6])),
                            origin0 = new Vector2(int.Parse(str.Split('_')[5]), int.Parse(str.Split('_')[6])),
                            pdr0    = int.Parse(str.Split('_')[7])
                        };
                        if (str.Split('_')[8] != "")
                        {
                            barrageType.color = int.Parse(str.Split('_')[8]);
                        }
                        else
                        {
                            barrageType.color = -1;
                        }
                        bgset.Add(barrageType);
                    }
                    source = streamReader.ReadLine();
                }
                if (source.Contains("GlobalEvents"))
                {
                    int num1 = int.Parse(source.Split(' ')[0]);
                    for (int index = 0; index < num1; ++index)
                    {
                        string str = streamReader.ReadLine();
                        time.GEcount.Add(int.Parse(str.Split('_')[0]) - 1);
                        GlobalEvent globalEvent = new GlobalEvent {
                            gotocondition  = int.Parse(str.Split('_')[1]),
                            gotoopreator   = str.Split('_')[2],
                            gotocvalue     = int.Parse(str.Split('_')[3]),
                            isgoto         = (bool.Parse(str.Split('_')[4]) ? 1 : 0) != 0,
                            gototime       = int.Parse(str.Split('_')[5]),
                            gotowhere      = int.Parse(str.Split('_')[6]),
                            quakecondition = int.Parse(str.Split('_')[7]),
                            quakeopreator  = str.Split('_')[8],
                            quakecvalue    = int.Parse(str.Split('_')[9]),
                            isquake        = (bool.Parse(str.Split('_')[10]) ? 1 : 0) != 0,
                            quaketime      = int.Parse(str.Split('_')[11]),
                            quakelevel     = int.Parse(str.Split('_')[12]),
                            stopcondition  = int.Parse(str.Split('_')[13]),
                            stopopreator   = str.Split('_')[14],
                            stopcvalue     = int.Parse(str.Split('_')[15]),
                            isstop         = (bool.Parse(str.Split('_')[16]) ? 1 : 0) != 0,
                            stoptime       = int.Parse(str.Split('_')[17]),
                            stoplevel      = int.Parse(str.Split('_')[18])
                        };
                        if (time.GE.Count < int.Parse(str.Split('_')[0]))
                        {
                            int num2 = 0;
                            while (true)
                            {
                                if (num2 < int.Parse(str.Split('_')[0]))
                                {
                                    time.GE.Add(new GlobalEvent()
                                    {
                                        gotocondition  = -1,
                                        quakecondition = -1,
                                        stopcondition  = -1,
                                        stoplevel      = -1
                                    });
                                    ++num2;
                                }
                                else
                                {
                                    break;
                                }
                            }
                        }
                        time.GE[int.Parse(str.Split('_')[0]) - 1] = globalEvent;
                    }
                    source = streamReader.ReadLine();
                }
                if (source.Contains("Sounds"))
                {
                    int num = int.Parse(source.Split(' ')[0]);
                    for (int index = 0; index < num; ++index)
                    {
                        string str = streamReader.ReadLine();
                        csm.bgset[int.Parse(str.Split('_')[0]) - 1].sound = str.Split('_')[1];
                    }
                    source = streamReader.ReadLine();
                }
                if (source.Contains(','))
                {
                    center.Available = true;
                    center.x         = float.Parse(source.Split(':')[1].Split(',')[0]);
                    center.y         = float.Parse(source.Split(':')[1].Split(',')[1]);
                    if (source.Split(':')[1].Split(',').Length >= 7)
                    {
                        center.speed   = float.Parse(source.Split(':')[1].Split(',')[2]);
                        center.speedd  = float.Parse(source.Split(':')[1].Split(',')[3]);
                        center.aspeed  = float.Parse(source.Split(':')[1].Split(',')[4]);
                        center.aspeedd = float.Parse(source.Split(':')[1].Split(',')[5]);
                        int index = 0;
                        while (true)
                        {
                            if (index < source.Split(':')[1].Split(',')[6].Split(';').Length - 1)
                            {
                                center.events.Add(source.Split(':')[1].Split(',')[6].Split(';')[index]);
                                ++index;
                            }
                            else
                            {
                                break;
                            }
                        }
                    }
                }
                else
                {
                    center.Available = false;
                }
                time.total = int.Parse(streamReader.ReadLine().Split(',')[0].Split(':')[1]);
                for (int index1 = 0; index1 < 4; ++index1)
                {
                    string str1 = streamReader.ReadLine();
                    if (str1.Split(':')[1].Split(',')[0] != "empty")
                    {
                        Layer layer = new Layer(layerm, int.Parse(str1.Split(':')[1].Split(',')[1]), int.Parse(str1.Split(':')[1].Split(',')[2]));
                        int   num1  = int.Parse(str1.Split(':')[1].Split(',')[3]);
                        for (int index2 = 0; index2 < num1; ++index2)
                        {
                            string str2  = streamReader.ReadLine();
                            Batch  batch = new Batch(float.Parse(str2.Split(',')[6]), float.Parse(str2.Split(',')[7]), layerm)
                            {
                                id             = int.Parse(str2.Split(',')[0]),
                                parentid       = int.Parse(str2.Split(',')[1]),
                                Binding        = (bool.Parse(str2.Split(',')[2]) ? 1 : 0) != 0,
                                bindid         = int.Parse(str2.Split(',')[3]),
                                Bindwithspeedd = (bool.Parse(str2.Split(',')[4]) ? 1 : 0) != 0,
                                begin          = int.Parse(str2.Split(',')[8]),
                                life           = int.Parse(str2.Split(',')[9]),
                                fx             = float.Parse(str2.Split(',')[10]),
                                fy             = float.Parse(str2.Split(',')[11]),
                                r          = int.Parse(str2.Split(',')[12]),
                                rdirection = float.Parse(str2.Split(',')[13])
                            };
                            string str3 = str2.Split(',')[14].Replace("{", "").Replace("}", "");
                            batch.rdirections.X = float.Parse(str3.Split(' ')[0].Split(':')[1]);
                            batch.rdirections.Y = float.Parse(str3.Split(' ')[1].Split(':')[1]);
                            batch.tiao          = int.Parse(str2.Split(',')[15]);
                            batch.t             = int.Parse(str2.Split(',')[16]);
                            batch.fdirection    = float.Parse(str2.Split(',')[17]);
                            string str4 = str2.Split(',')[18].Replace("{", "").Replace("}", "");
                            batch.fdirections.X = float.Parse(str4.Split(' ')[0].Split(':')[1]);
                            batch.fdirections.Y = float.Parse(str4.Split(' ')[1].Split(':')[1]);
                            batch.range         = int.Parse(str2.Split(',')[19]);
                            batch.speed         = float.Parse(str2.Split(',')[20]);
                            batch.speedd        = float.Parse(str2.Split(',')[21]);
                            string str5 = str2.Split(',')[22].Replace("{", "").Replace("}", "");
                            batch.speedds.X = float.Parse(str5.Split(' ')[0].Split(':')[1]);
                            batch.speedds.Y = float.Parse(str5.Split(' ')[1].Split(':')[1]);
                            batch.aspeed    = float.Parse(str2.Split(',')[23]);
                            batch.aspeedd   = float.Parse(str2.Split(',')[24]);
                            string str6 = str2.Split(',')[25].Replace("{", "").Replace("}", "");
                            batch.aspeedds.X = float.Parse(str6.Split(' ')[0].Split(':')[1]);
                            batch.aspeedds.Y = float.Parse(str6.Split(' ')[1].Split(':')[1]);
                            batch.sonlife    = int.Parse(str2.Split(',')[26]);
                            batch.type       = int.Parse(str2.Split(',')[27]);
                            batch.wscale     = float.Parse(str2.Split(',')[28]);
                            batch.hscale     = float.Parse(str2.Split(',')[29]);
                            batch.colorR     = int.Parse(str2.Split(',')[30]);
                            batch.colorG     = int.Parse(str2.Split(',')[31]);
                            batch.colorB     = int.Parse(str2.Split(',')[32]);
                            batch.alpha      = int.Parse(str2.Split(',')[33]);
                            batch.head       = float.Parse(str2.Split(',')[34]);
                            string str7 = str2.Split(',')[35].Replace("{", "").Replace("}", "");
                            batch.heads.X    = float.Parse(str7.Split(' ')[0].Split(':')[1]);
                            batch.heads.Y    = float.Parse(str7.Split(' ')[1].Split(':')[1]);
                            batch.Withspeedd = (bool.Parse(str2.Split(',')[36]) ? 1 : 0) != 0;
                            batch.sonspeed   = float.Parse(str2.Split(',')[37]);
                            batch.sonspeedd  = float.Parse(str2.Split(',')[38]);
                            string str8 = str2.Split(',')[39].Replace("{", "").Replace("}", "");
                            batch.sonspeedds.X = float.Parse(str8.Split(' ')[0].Split(':')[1]);
                            batch.sonspeedds.Y = float.Parse(str8.Split(' ')[1].Split(':')[1]);
                            batch.sonaspeed    = float.Parse(str2.Split(',')[40]);
                            batch.sonaspeedd   = float.Parse(str2.Split(',')[41]);
                            string str9 = str2.Split(',')[42].Replace("{", "").Replace("}", "");
                            batch.sonaspeedds.X = float.Parse(str9.Split(' ')[0].Split(':')[1]);
                            batch.sonaspeedds.Y = float.Parse(str9.Split(' ')[1].Split(':')[1]);
                            batch.xscale        = float.Parse(str2.Split(',')[43]);
                            batch.yscale        = float.Parse(str2.Split(',')[44]);
                            batch.Mist          = (bool.Parse(str2.Split(',')[45]) ? 1 : 0) != 0;
                            batch.Dispel        = (bool.Parse(str2.Split(',')[46]) ? 1 : 0) != 0;
                            batch.Blend         = (bool.Parse(str2.Split(',')[47]) ? 1 : 0) != 0;
                            batch.Afterimage    = (bool.Parse(str2.Split(',')[48]) ? 1 : 0) != 0;
                            batch.Outdispel     = (bool.Parse(str2.Split(',')[49]) ? 1 : 0) != 0;
                            batch.Invincible    = (bool.Parse(str2.Split(',')[50]) ? 1 : 0) != 0;
                            string str10 = str2.Split(',')[51];
                            int    idx1  = 0;
                            while (true)
                            {
                                if (idx1 < str10.Split('&').Length - 1)
                                {
                                    string str11  = str10.Split('&')[idx1];
                                    Event  @event = new Event(idx1)
                                    {
                                        tag     = str11.Split('|')[0],
                                        t       = int.Parse(str11.Split('|')[1]),
                                        addtime = int.Parse(str11.Split('|')[2])
                                    };
                                    int index3 = 0;
                                    while (true)
                                    {
                                        if (index3 < str11.Split('|')[3].Split(';').Length - 1)
                                        {
                                            @event.events.Add(str11.Split('|')[3].Split(';')[index3]);
                                            ++index3;
                                        }
                                        else
                                        {
                                            break;
                                        }
                                    }
                                    batch.Parentevents.Add(@event);
                                    ++idx1;
                                }
                                else
                                {
                                    break;
                                }
                            }
                            string str12 = str2.Split(',')[52];
                            int    idx2  = 0;
                            while (true)
                            {
                                if (idx2 < str12.Split('&').Length - 1)
                                {
                                    string str11  = str12.Split('&')[idx2];
                                    Event  @event = new Event(idx2)
                                    {
                                        tag     = str11.Split('|')[0],
                                        t       = int.Parse(str11.Split('|')[1]),
                                        addtime = int.Parse(str11.Split('|')[2])
                                    };
                                    int index3 = 0;
                                    while (true)
                                    {
                                        if (index3 < str11.Split('|')[3].Split(';').Length - 1)
                                        {
                                            @event.events.Add(str11.Split('|')[3].Split(';')[index3]);
                                            ++index3;
                                        }
                                        else
                                        {
                                            break;
                                        }
                                    }
                                    batch.Sonevents.Add(@event);
                                    ++idx2;
                                }
                                else
                                {
                                    break;
                                }
                            }
                            batch.rand.fx         = float.Parse(str2.Split(',')[53]);
                            batch.rand.fy         = float.Parse(str2.Split(',')[54]);
                            batch.rand.r          = int.Parse(str2.Split(',')[55]);
                            batch.rand.rdirection = float.Parse(str2.Split(',')[56]);
                            batch.rand.tiao       = int.Parse(str2.Split(',')[57]);
                            batch.rand.t          = int.Parse(str2.Split(',')[58]);
                            batch.rand.fdirection = float.Parse(str2.Split(',')[59]);
                            batch.rand.range      = int.Parse(str2.Split(',')[60]);
                            batch.rand.speed      = float.Parse(str2.Split(',')[61]);
                            batch.rand.speedd     = float.Parse(str2.Split(',')[62]);
                            batch.rand.aspeed     = float.Parse(str2.Split(',')[63]);
                            batch.rand.aspeedd    = float.Parse(str2.Split(',')[64]);
                            batch.rand.head       = float.Parse(str2.Split(',')[65]);
                            batch.rand.sonspeed   = float.Parse(str2.Split(',')[66]);
                            batch.rand.sonspeedd  = float.Parse(str2.Split(',')[67]);
                            batch.rand.sonaspeed  = float.Parse(str2.Split(',')[68]);
                            batch.rand.sonaspeedd = float.Parse(str2.Split(',')[69]);
                            if (str2.Split(',').Length >= 72)
                            {
                                batch.Cover   = (bool.Parse(str2.Split(',')[70]) ? 1 : 0) != 0;
                                batch.Rebound = (bool.Parse(str2.Split(',')[71]) ? 1 : 0) != 0;
                                batch.Force   = (bool.Parse(str2.Split(',')[72]) ? 1 : 0) != 0;
                            }
                            if (str2.Split(',').Length >= 74)
                            {
                                batch.Deepbind = (bool.Parse(str2.Split(',')[73]) ? 1 : 0) != 0;
                            }
                            layerm.LayerArray[index1].BatchArray.Add(batch);
                        }
                        if (str1.Split(':')[1].Split(',').Length >= 7)
                        {
                            int num2 = int.Parse(str1.Split(':')[1].Split(',')[4]);
                            for (int index2 = 0; index2 < num2; ++index2)
                            {
                                string str2 = streamReader.ReadLine();
                                Lase   lase = new Lase(float.Parse(str2.Split(',')[6]), float.Parse(str2.Split(',')[7]), layerm)
                                {
                                    id             = int.Parse(str2.Split(',')[0]),
                                    parentid       = int.Parse(str2.Split(',')[1]),
                                    Binding        = (bool.Parse(str2.Split(',')[2]) ? 1 : 0) != 0,
                                    bindid         = int.Parse(str2.Split(',')[3]),
                                    Bindwithspeedd = (bool.Parse(str2.Split(',')[4]) ? 1 : 0) != 0,
                                    begin          = int.Parse(str2.Split(',')[8]),
                                    life           = int.Parse(str2.Split(',')[9]),
                                    r          = int.Parse(str2.Split(',')[10]),
                                    rdirection = float.Parse(str2.Split(',')[11])
                                };
                                string str3 = str2.Split(',')[12].Replace("{", "").Replace("}", "");
                                lase.rdirections.X = float.Parse(str3.Split(' ')[0].Split(':')[1]);
                                lase.rdirections.Y = float.Parse(str3.Split(' ')[1].Split(':')[1]);
                                lase.tiao          = int.Parse(str2.Split(',')[13]);
                                lase.t             = int.Parse(str2.Split(',')[14]);
                                lase.fdirection    = float.Parse(str2.Split(',')[15]);
                                string str4 = str2.Split(',')[16].Replace("{", "").Replace("}", "");
                                lase.fdirections.X = float.Parse(str4.Split(' ')[0].Split(':')[1]);
                                lase.fdirections.Y = float.Parse(str4.Split(' ')[1].Split(':')[1]);
                                lase.range         = int.Parse(str2.Split(',')[17]);
                                lase.speed         = float.Parse(str2.Split(',')[18]);
                                lase.speedd        = float.Parse(str2.Split(',')[19]);
                                string str5 = str2.Split(',')[20].Replace("{", "").Replace("}", "");
                                lase.speedds.X = float.Parse(str5.Split(' ')[0].Split(':')[1]);
                                lase.speedds.Y = float.Parse(str5.Split(' ')[1].Split(':')[1]);
                                lase.aspeed    = float.Parse(str2.Split(',')[21]);
                                lase.aspeedd   = float.Parse(str2.Split(',')[22]);
                                string str6 = str2.Split(',')[23].Replace("{", "").Replace("}", "");
                                lase.aspeedds.X = float.Parse(str6.Split(' ')[0].Split(':')[1]);
                                lase.aspeedds.Y = float.Parse(str6.Split(' ')[1].Split(':')[1]);
                                lase.sonlife    = int.Parse(str2.Split(',')[24]);
                                lase.type       = int.Parse(str2.Split(',')[25]);
                                lase.wscale     = float.Parse(str2.Split(',')[26]);
                                lase.longs      = float.Parse(str2.Split(',')[27]);
                                lase.alpha      = int.Parse(str2.Split(',')[28]);
                                lase.Ray        = (bool.Parse(str2.Split(',')[29]) ? 1 : 0) != 0;
                                lase.sonspeed   = float.Parse(str2.Split(',')[30]);
                                lase.sonspeedd  = float.Parse(str2.Split(',')[31]);
                                string str7 = str2.Split(',')[32].Replace("{", "").Replace("}", "");
                                lase.sonspeedds.X = float.Parse(str7.Split(' ')[0].Split(':')[1]);
                                lase.sonspeedds.Y = float.Parse(str7.Split(' ')[1].Split(':')[1]);
                                lase.sonaspeed    = float.Parse(str2.Split(',')[33]);
                                lase.sonaspeedd   = float.Parse(str2.Split(',')[34]);
                                string str8 = str2.Split(',')[35].Replace("{", "").Replace("}", "");
                                lase.sonaspeedds.X = float.Parse(str8.Split(' ')[0].Split(':')[1]);
                                lase.sonaspeedds.Y = float.Parse(str8.Split(' ')[1].Split(':')[1]);
                                lase.xscale        = float.Parse(str2.Split(',')[36]);
                                lase.yscale        = float.Parse(str2.Split(',')[37]);
                                lase.Blend         = (bool.Parse(str2.Split(',')[38]) ? 1 : 0) != 0;
                                lase.Outdispel     = (bool.Parse(str2.Split(',')[39]) ? 1 : 0) != 0;
                                lase.Invincible    = (bool.Parse(str2.Split(',')[40]) ? 1 : 0) != 0;
                                string str9 = str2.Split(',')[42];
                                int    idx1 = 0;
                                while (true)
                                {
                                    if (idx1 < str9.Split('&').Length - 1)
                                    {
                                        string str10  = str9.Split('&')[idx1];
                                        Event  @event = new Event(idx1)
                                        {
                                            tag     = str10.Split('|')[0],
                                            t       = int.Parse(str10.Split('|')[1]),
                                            addtime = int.Parse(str10.Split('|')[2])
                                        };
                                        int index3 = 0;
                                        while (true)
                                        {
                                            if (index3 < str10.Split('|')[3].Split(';').Length - 1)
                                            {
                                                @event.events.Add(str10.Split('|')[3].Split(';')[index3]);
                                                ++index3;
                                            }
                                            else
                                            {
                                                break;
                                            }
                                        }
                                        lase.Parentevents.Add(@event);
                                        ++idx1;
                                    }
                                    else
                                    {
                                        break;
                                    }
                                }
                                string str11 = str2.Split(',')[43];
                                int    idx2  = 0;
                                while (true)
                                {
                                    if (idx2 < str11.Split('&').Length - 1)
                                    {
                                        string str10  = str11.Split('&')[idx2];
                                        Event  @event = new Event(idx2)
                                        {
                                            tag     = str10.Split('|')[0],
                                            t       = int.Parse(str10.Split('|')[1]),
                                            addtime = int.Parse(str10.Split('|')[2])
                                        };
                                        int index3 = 0;
                                        while (true)
                                        {
                                            if (index3 < str10.Split('|')[3].Split(';').Length - 1)
                                            {
                                                @event.events.Add(str10.Split('|')[3].Split(';')[index3]);
                                                ++index3;
                                            }
                                            else
                                            {
                                                break;
                                            }
                                        }
                                        lase.Sonevents.Add(@event);
                                        ++idx2;
                                    }
                                    else
                                    {
                                        break;
                                    }
                                }
                                lase.rand.r          = int.Parse(str2.Split(',')[44]);
                                lase.rand.rdirection = float.Parse(str2.Split(',')[45]);
                                lase.rand.tiao       = int.Parse(str2.Split(',')[46]);
                                lase.rand.t          = int.Parse(str2.Split(',')[47]);
                                lase.rand.fdirection = float.Parse(str2.Split(',')[48]);
                                lase.rand.range      = int.Parse(str2.Split(',')[49]);
                                lase.rand.speed      = float.Parse(str2.Split(',')[50]);
                                lase.rand.speedd     = float.Parse(str2.Split(',')[51]);
                                lase.rand.aspeed     = float.Parse(str2.Split(',')[52]);
                                lase.rand.aspeedd    = float.Parse(str2.Split(',')[53]);
                                lase.rand.sonspeed   = float.Parse(str2.Split(',')[54]);
                                lase.rand.sonspeedd  = float.Parse(str2.Split(',')[55]);
                                lase.rand.sonaspeed  = float.Parse(str2.Split(',')[56]);
                                lase.rand.sonaspeedd = float.Parse(str2.Split(',')[57]);
                                if (str2.Split(',').Length >= 59)
                                {
                                    lase.Deepbind = (bool.Parse(str2.Split(',')[58]) ? 1 : 0) != 0;
                                }
                                layerm.LayerArray[index1].LaseArray.Add(lase);
                            }
                            int num3 = int.Parse(str1.Split(':')[1].Split(',')[5]);
                            for (int index2 = 0; index2 < num3; ++index2)
                            {
                                string str2  = streamReader.ReadLine();
                                Cover  cover = new Cover(float.Parse(str2.Split(',')[2]), float.Parse(str2.Split(',')[3]), layerm)
                                {
                                    id        = int.Parse(str2.Split(',')[0]),
                                    parentid  = int.Parse(str2.Split(',')[1]),
                                    begin     = int.Parse(str2.Split(',')[4]),
                                    life      = int.Parse(str2.Split(',')[5]),
                                    halfw     = int.Parse(str2.Split(',')[6]),
                                    halfh     = int.Parse(str2.Split(',')[7]),
                                    Circle    = (bool.Parse(str2.Split(',')[8]) ? 1 : 0) != 0,
                                    type      = int.Parse(str2.Split(',')[9]),
                                    controlid = int.Parse(str2.Split(',')[10]),
                                    speed     = float.Parse(str2.Split(',')[11]),
                                    speedd    = float.Parse(str2.Split(',')[12])
                                };
                                string str3 = str2.Split(',')[13].Replace("{", "").Replace("}", "");
                                cover.speedds.X = float.Parse(str3.Split(' ')[0].Split(':')[1]);
                                cover.speedds.Y = float.Parse(str3.Split(' ')[1].Split(':')[1]);
                                cover.aspeed    = float.Parse(str2.Split(',')[14]);
                                cover.aspeedd   = float.Parse(str2.Split(',')[15]);
                                string str4 = str2.Split(',')[16].Replace("{", "").Replace("}", "");
                                cover.aspeedds.X = float.Parse(str4.Split(' ')[0].Split(':')[1]);
                                cover.aspeedds.Y = float.Parse(str4.Split(' ')[1].Split(':')[1]);
                                string str5 = str2.Split(',')[17];
                                int    idx1 = 0;
                                while (true)
                                {
                                    if (idx1 < str5.Split('&').Length - 1)
                                    {
                                        string str6   = str5.Split('&')[idx1];
                                        Event  @event = new Event(idx1)
                                        {
                                            tag     = str6.Split('|')[0],
                                            t       = int.Parse(str6.Split('|')[1]),
                                            addtime = int.Parse(str6.Split('|')[2])
                                        };
                                        int index3 = 0;
                                        while (true)
                                        {
                                            if (index3 < str6.Split('|')[3].Split(';').Length - 1)
                                            {
                                                @event.events.Add(str6.Split('|')[3].Split(';')[index3]);
                                                ++index3;
                                            }
                                            else
                                            {
                                                break;
                                            }
                                        }
                                        cover.Parentevents.Add(@event);
                                        ++idx1;
                                    }
                                    else
                                    {
                                        break;
                                    }
                                }
                                string str7 = str2.Split(',')[18];
                                int    idx2 = 0;
                                while (true)
                                {
                                    if (idx2 < str7.Split('&').Length - 1)
                                    {
                                        string str6   = str7.Split('&')[idx2];
                                        Event  @event = new Event(idx2)
                                        {
                                            tag     = str6.Split('|')[0],
                                            t       = int.Parse(str6.Split('|')[1]),
                                            addtime = int.Parse(str6.Split('|')[2])
                                        };
                                        int index3 = 0;
                                        while (true)
                                        {
                                            if (index3 < str6.Split('|')[3].Split(';').Length - 1)
                                            {
                                                @event.events.Add(str6.Split('|')[3].Split(';')[index3]);
                                                ++index3;
                                            }
                                            else
                                            {
                                                break;
                                            }
                                        }
                                        cover.Sonevents.Add(@event);
                                        ++idx2;
                                    }
                                    else
                                    {
                                        break;
                                    }
                                }
                                cover.rand.speed   = float.Parse(str2.Split(',')[19]);
                                cover.rand.speedd  = float.Parse(str2.Split(',')[20]);
                                cover.rand.aspeed  = float.Parse(str2.Split(',')[21]);
                                cover.rand.aspeedd = float.Parse(str2.Split(',')[22]);
                                if (str2.Split(',').Length >= 24)
                                {
                                    cover.bindid = int.Parse(str2.Split(',')[23]);
                                }
                                if (str2.Split(',').Length >= 25)
                                {
                                    if (str2.Split(',')[24] != "")
                                    {
                                        cover.Deepbind = (bool.Parse(str2.Split(',')[24]) ? 1 : 0) != 0;
                                    }
                                }
                                layerm.LayerArray[index1].CoverArray.Add(cover);
                            }
                            int num4 = int.Parse(str1.Split(':')[1].Split(',')[6]);
                            for (int index2 = 0; index2 < num4; ++index2)
                            {
                                string  str2    = streamReader.ReadLine();
                                Rebound rebound = new Rebound(float.Parse(str2.Split(',')[2]), float.Parse(str2.Split(',')[3]), layerm)
                                {
                                    id       = int.Parse(str2.Split(',')[0]),
                                    parentid = int.Parse(str2.Split(',')[1]),
                                    begin    = int.Parse(str2.Split(',')[4]),
                                    life     = int.Parse(str2.Split(',')[5]),
                                    longs    = int.Parse(str2.Split(',')[6]),
                                    angle    = int.Parse(str2.Split(',')[7]),
                                    time     = int.Parse(str2.Split(',')[8]),
                                    speed    = float.Parse(str2.Split(',')[9]),
                                    speedd   = float.Parse(str2.Split(',')[10]),
                                    aspeed   = float.Parse(str2.Split(',')[11]),
                                    aspeedd  = float.Parse(str2.Split(',')[12])
                                };
                                string str3 = str2.Split(',')[13];
                                int    idx  = 0;
                                while (true)
                                {
                                    if (idx < str3.Split('&').Length - 1)
                                    {
                                        string str4 = str3.Split('&')[idx];
                                        rebound.Parentevents.Add(new Event(idx)
                                        {
                                            tag = str4
                                        });
                                        ++idx;
                                    }
                                    else
                                    {
                                        break;
                                    }
                                }
                                rebound.rand.speed   = float.Parse(str2.Split(',')[14]);
                                rebound.rand.speedd  = float.Parse(str2.Split(',')[15]);
                                rebound.rand.aspeed  = float.Parse(str2.Split(',')[16]);
                                rebound.rand.aspeedd = float.Parse(str2.Split(',')[17]);
                                layerm.LayerArray[index1].ReboundArray.Add(rebound);
                            }
                            int num5 = int.Parse(str1.Split(':')[1].Split(',')[7]);
                            for (int index2 = 0; index2 < num5; ++index2)
                            {
                                string str2 = streamReader.ReadLine();
                                layerm.LayerArray[index1].ForceArray.Add(new Force(float.Parse(str2.Split(',')[2]), float.Parse(str2.Split(',')[3]), layerm)
                                {
                                    id         = int.Parse(str2.Split(',')[0]),
                                    parentid   = int.Parse(str2.Split(',')[1]),
                                    begin      = int.Parse(str2.Split(',')[4]),
                                    life       = int.Parse(str2.Split(',')[5]),
                                    halfw      = int.Parse(str2.Split(',')[6]),
                                    halfh      = int.Parse(str2.Split(',')[7]),
                                    Circle     = (bool.Parse(str2.Split(',')[8]) ? 1 : 0) != 0,
                                    type       = int.Parse(str2.Split(',')[9]),
                                    controlid  = int.Parse(str2.Split(',')[10]),
                                    speed      = float.Parse(str2.Split(',')[11]),
                                    speedd     = float.Parse(str2.Split(',')[12]),
                                    aspeed     = float.Parse(str2.Split(',')[13]),
                                    aspeedd    = float.Parse(str2.Split(',')[14]),
                                    addaspeed  = float.Parse(str2.Split(',')[15]),
                                    addaspeedd = float.Parse(str2.Split(',')[16]),
                                    Suction    = (bool.Parse(str2.Split(',')[17]) ? 1 : 0) != 0,
                                    Repulsion  = (bool.Parse(str2.Split(',')[18]) ? 1 : 0) != 0,
                                    addspeed   = float.Parse(str2.Split(',')[19]),
                                    rand       =
                                    {
                                        speed   = float.Parse(str2.Split(',')[20]),
                                        speedd  = float.Parse(str2.Split(',')[21]),
                                        aspeed  = float.Parse(str2.Split(',')[22]),
                                        aspeedd = float.Parse(str2.Split(',')[23])
                                    }
                                });
                            }
                        }
                    }
                }
            }
            time.Init(Player);
        }