Exemple #1
0
        private void frmEditMap_Load(object sender, EventArgs e)
        {
            if (newmap)
            {
                Map                  = new Map();
                this.Text            = "Map";
                txtPID.Text          = MapParser.GetFreeMapPID(1).ToString();
                txtPID.Enabled       = true;
                btnAssignPID.Enabled = true;
            }
            else
            {
                this.Text            = "Map - " + Map.Name + " (" + Map.FileName + "), PID = " + Map.Pid;
                txtPID.Text          = Map.Pid.ToString();
                txtPID.Enabled       = false;
                btnAssignPID.Enabled = false;

                txtName.Text           = Map.Name;
                txtFileName.Text       = Map.FileName;
                txtScript.Text         = Map.ScriptName;
                lstBoxMusic.DataSource = Map.Music;
                txtSound.Text          = Map.SoundString;
                txtTime.Text           = Map.Time;
                chkNologout.Checked    = Map.NoLogout;
                chkAutomap.Checked     = Map.AutoMap;
            }
            save = false;
        }