mirror of
https://github.com/electronicarts/CNC_TS_and_RA2_Mission_Editor.git
synced 2025-07-17 19:56:38 -04:00
MinPlayer option (#113)
* let minplayers to inherit from ini . using enum to define preview save options .
This commit is contained in:
parent
6364362bd3
commit
18c1956d68
5 changed files with 64 additions and 38 deletions
|
@ -42,7 +42,8 @@ CSaveMapOptionsDlg::CSaveMapOptionsDlg(CWnd* pParent /*=NULL*/)
|
|||
{
|
||||
//{{AFX_DATA_INIT(CSaveMapOptionsDlg)
|
||||
m_Compress = 1;
|
||||
m_PreviewMode = 0;
|
||||
m_PreviewMode = PREVIEW_MINIMAP;
|
||||
m_MinPlayers = 2;
|
||||
m_MapName = _T("");
|
||||
m_AirWar = FALSE;
|
||||
m_Cooperative = FALSE;
|
||||
|
@ -56,10 +57,12 @@ CSaveMapOptionsDlg::CSaveMapOptionsDlg(CWnd* pParent /*=NULL*/)
|
|||
//}}AFX_DATA_INIT
|
||||
|
||||
CIniFile& ini = Map->GetIniFile();
|
||||
if (!Map->IsMultiplayer())
|
||||
m_PreviewMode = 1;
|
||||
if (!Map->IsMultiplayer()) {
|
||||
m_PreviewMode = PREVIEW_DONT_CHANGE;
|
||||
}
|
||||
|
||||
m_MapName = ini.GetString("Basic", "Name");
|
||||
m_MinPlayers = ini.GetInteger("Basic", "MinPlayer");
|
||||
}
|
||||
|
||||
|
||||
|
@ -67,9 +70,9 @@ void CSaveMapOptionsDlg::DoDataExchange(CDataExchange* pDX)
|
|||
{
|
||||
CDialog::DoDataExchange(pDX);
|
||||
//{{AFX_DATA_MAP(CSaveMapOptionsDlg)
|
||||
DDX_Radio(pDX, IDC_COMPRESS, m_Compress);
|
||||
DDX_Radio(pDX, IDC_PREVIEWMODE, m_PreviewMode);
|
||||
DDX_Radio(pDX, IDC_PREVIEWMODE, reinterpret_cast<int&>(m_PreviewMode));
|
||||
DDX_Text(pDX, IDC_MAPNAME, m_MapName);
|
||||
DDX_Text(pDX, IDC_SAVE_OPT_M_PLAYERS, m_MinPlayers);
|
||||
#ifdef RA2_MODE
|
||||
DDX_Check(pDX, IDC_AIRWAR, m_AirWar);
|
||||
DDX_Check(pDX, IDC_COOPERATIVE, m_Cooperative);
|
||||
|
@ -119,3 +122,8 @@ BOOL CSaveMapOptionsDlg::OnInitDialog()
|
|||
return TRUE; // return TRUE unless you set the focus to a control
|
||||
// EXCEPTION: OCX-Eigenschaftenseiten sollten FALSE zurückgeben
|
||||
}
|
||||
|
||||
void translateUI()
|
||||
{
|
||||
//IDC_SAVE_OPT_MP_TXT;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue