Process() 공개 메소드

public Process ( bool generateTexture = false, bool bUpdating = false ) : void
generateTexture bool
bUpdating bool
리턴 void
예제 #1
0
 public void BSVertEditor_Update(string ofd)
 {
     BattleStage bs = new BattleStage(ofd);
     listBox1.Items.Clear();
     bs.Process(false, true);
     BS_UpdateObjects(bs.GetArrayOfObjects(), ofd);
     Render3D();
 }
예제 #2
0
        private void openToolStripMenuItem_Click(object sender, EventArgs e)
        {
            OpenFileDialog ofd = new OpenFileDialog
            {
                Title = "Open FF8 .X stage model (a0stgXXX.x)",
                Filter = "Final Fantasy VIII stage (.x)|*.X"
            };
            if (ofd.ShowDialog() != DialogResult.OK) return;
            Console.WriteLine("BS: Opening file...");
            _state = StateBattleStageUv;
            exportToolStripMenuItem.Enabled = true;
            importToolStripMenuItem.Enabled = true;
            SetLines(false);
            BattleStage bs = new BattleStage(ofd.FileName);
            listBox1.Items.Clear();
            UpdateStatus(ofd.FileName);
            bs.Process(true);
            pictureBox1.Image = bs.GetTexture();
            pictureBox1.BackgroundImage = bs.GetTexture();
            _bmp = bs.GetTexture();
            _bmp2 = bs.GetTexture(); 
            _lastKnownPath = ofd.FileName;
            _lastKnownTim = bs.GetLastTim();
            _pathModels = new List<string>();
            foreach (int i in bs.GetArrayOfObjects())
            {
                listBox1.Items.Add(i.ToString());
                var pathOfd = Path.GetDirectoryName(ofd.FileName);
                pathOfd += $@"\{Path.GetFileNameWithoutExtension(ofd.FileName)}_{i.ToString()}_t.obj";
                if (File.Exists(pathOfd))
                    _pathModels.Add(pathOfd);

                string pathOfd2 = Path.GetDirectoryName(ofd.FileName);
                pathOfd2 += $@"\{Path.GetFileNameWithoutExtension(ofd.FileName)}_{i.ToString()}_q.obj";
                if (File.Exists(pathOfd2))
                    _pathModels.Add(pathOfd2);

                if (File.Exists(pathOfd) && File.Exists(pathOfd2))
                    listBox1.Items.Add(i.ToString());
            }
            Render3D();
            BattleStage_listbox(true);
            pictureBox1.BackgroundImage = null;
        }