コード例 #1
0
        public void button11_Click(object sender, EventArgs e)
        {
            ChangeLabel(1);
            EditItems.Clear();
            AddItems.Clear();
            wts_structure wts = new wts_structure(@"Input\war3map.wts");

            /*
             * MessageBox.Show(wts.TrigStr.Count.ToString());
             * MessageBox.Show(((wts_structure.wtsS)wts.TrigStr[0]).S);
             * MessageBox.Show(((wts_structure.wtsS)wts.TrigStr[0]).TrigS);
             */
            for (int i = 0; i < BJ.substance.Count; i++)
            {
                if (BJ.substance[i].GetType() == typeof(string))
                {
                    for (int j = 0; j < wts.TrigStr.Count; j++)
                    {
                        string s = (string)BJ.substance[i];
                        s = s.Replace(((wts_structure.wtsS)wts.TrigStr[j]).S, ((wts_structure.wtsS)wts.TrigStr[j]).TrigS);
                        BJ.substance[i] = s;
                    }
                }
            }
            ListBJNew();
            ChangeLabel(0);
        }
コード例 #2
0
ファイル: Window.cs プロジェクト: Ev3nt/BJ_Edit
        public void button11_Click(object sender, EventArgs e)
        {
            ChangeLabel(1);
            EditItems.Clear();
            AddItems.Clear();
            Functions_count.Text        = "0";
            New_functions_count.Text    = "0";
            Edited_functions_count.Text = "0";
            wts_structure wts = new wts_structure(@"Input\war3map.wts");

            for (int i = 0; i < BJ.substance.Count; i++)
            {
                if (BJ.substance[i].GetType() == typeof(string))
                {
                    for (int j = 0; j < wts.TrigStr.Count; j++)
                    {
                        string s = (string)BJ.substance[i];
                        s = s.Replace(((wts_structure.wtsS)wts.TrigStr[j]).S, ((wts_structure.wtsS)wts.TrigStr[j]).TrigS);
                        BJ.substance[i] = s;
                    }
                }
            }

            ListBJNew();
            ChangeLabel(0);
            ShowChanges();
        }
コード例 #3
0
ファイル: Form1.cs プロジェクト: shawwwn/BJ_Edit
 public void button11_Click(object sender, EventArgs e)
 {
     ChangeLabel(1);
     EditItems.Clear();
     AddItems.Clear();
     wts_structure wts = new wts_structure(@"Input\war3map.wts");
     /*
     MessageBox.Show(wts.TrigStr.Count.ToString());
     MessageBox.Show(((wts_structure.wtsS)wts.TrigStr[0]).S);
     MessageBox.Show(((wts_structure.wtsS)wts.TrigStr[0]).TrigS);
     */
     for (int i = 0; i < BJ.substance.Count; i++)
     {
         if (BJ.substance[i].GetType() == typeof(string))
         {
             for (int j = 0; j < wts.TrigStr.Count; j++)
             {
                 string s =(string)BJ.substance[i];
                 s = s.Replace(((wts_structure.wtsS)wts.TrigStr[j]).S, ((wts_structure.wtsS)wts.TrigStr[j]).TrigS);
                 BJ.substance[i] = s;
             }
         }
     }
     ListBJNew();
     ChangeLabel(0);
 }