void CWndOptSound::OnInitialUpdate() { CWndNeuz::OnInitialUpdate(); CRect rectRoot = m_pWndRoot->GetLayoutRect(); CRect rectWindow = GetWindowRect(); CPoint point( rectRoot.right - rectWindow.Width(), 110 ); Move( point ); MoveParentCenter(); CWndButton* pWndButton[ 3 ]; pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_VOICEON ); pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_VOICEOFF ); if( ::GetLanguage() == LANG_JAP ) { pWndButton[ 1 ]->SetGroup( TRUE ); pWndButton[ g_Option.m_bVoice ]->SetCheck( TRUE ); } else { CWndStatic* pWndVoice = (CWndStatic*)GetDlgItem(WIDC_STATIC2); pWndVoice->SetVisible(FALSE); pWndButton[ 1 ]->SetVisible(FALSE); pWndButton[ 0 ]->SetVisible(FALSE); } m_Texture.LoadTexture( g_Neuz.GetDevice(), MakePath( DIR_THEME, "WndVolumeBar.tga" ), 0xffff00ff, TRUE ); m_TexturePt.LoadTexture( g_Neuz.GetDevice(), MakePath( DIR_THEME, "ButtSpin.tga" ), 0xffffffff, TRUE ); #if __VER < 12 // __UPDATE_OPT pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_MSHIGH ); pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_MSMID ); pWndButton[ 2 ] = (CWndButton*)GetDlgItem( WIDC_MSLOW ); pWndButton[ 0 ]->SetGroup( TRUE ); pWndButton[ g_Option.m_MouseSpeed ]->SetCheck( TRUE ); #endif m_nStep[0] = (int)( g_Option.m_fEffectVolume * 10 ); m_nStep[1] = (int)( g_Option.m_fBGMVolume * 10 ); }
void CWndOptionGame::OnInitialUpdate() { CWndNeuz::OnInitialUpdate(); // 여기에 코딩하세요 CWndButton* pWndButton[ 2 ]; pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_RADIO1 ); pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_RADIO2 ); pWndButton[ 0 ]->SetGroup( TRUE ); pWndButton[ !(g_Option.m_bTrade) ]->SetCheck( TRUE ); pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_RADIO3 ); pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_RADIO4 ); pWndButton[ 0 ]->SetGroup( TRUE ); pWndButton[ !(g_Option.m_bSay) ]->SetCheck( TRUE ); pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_RADIO5 ); pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_RADIO6 ); pWndButton[ 0 ]->SetGroup( TRUE ); pWndButton[ !(g_Option.m_bParty) ]->SetCheck( TRUE ); #if __VER >= 12 // __UPDATE_OPT m_Texture.LoadTexture( g_Neuz.GetDevice(), MakePath( DIR_THEME, "WndVolumeBar.tga" ), 0xffff00ff, TRUE ); m_TexturePt.LoadTexture( g_Neuz.GetDevice(), MakePath( DIR_THEME, "ButtSpin.tga" ), 0xffffffff, TRUE ); m_nStep[0] = (int)( g_Option.m_fEffectVolume * 10 ); m_nStep[1] = (int)( g_Option.m_fBGMVolume * 10 ); CWndButton* pWndHelp = (CWndButton*)GetDlgItem( WIDC_CHECK1 ); pWndHelp->SetCheck( g_Option.m_nInstantHelp ); CWndButton* pWndCheck = (CWndButton*)GetDlgItem( WIDC_CHECK2 ); if(*g_Option.m_pGuide > 0) pWndCheck->SetCheck( FALSE ); else pWndCheck->SetCheck( TRUE ); CWndButton* pWndAlpha = (CWndButton*)GetDlgItem( WIDC_CHECK3 ); pWndAlpha->SetCheck( g_Option.m_nWindowAlpha == 255 ? FALSE : TRUE); #if __VER >= 15 // __IMPROVE_SYSTEM_VER15 CWndButton* pWndCheckBattleBGM = (CWndButton*)GetDlgItem( WIDC_CHECK_BATTLE_BGM ); pWndCheckBattleBGM->SetCheck( g_Option.m_bBattleBGM ? TRUE : FALSE ); #endif // __IMPROVE_SYSTEM_VER15 #ifdef __GAME_GRADE_SYSTEM CWndButton* pWndCheckGameGrade = (CWndButton*)GetDlgItem( WIDC_CHECK_GAME_GRADE ); if( pWndCheckGameGrade ) { if( ::GetLanguage() == LANG_KOR ) { pWndCheckGameGrade->SetCheck( g_Option.m_bGameGradeRendering ? TRUE : FALSE ); } else { pWndCheckGameGrade->SetVisible( FALSE ); } } #endif // __GAME_GRADE_SYSTEM pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_RADIO7 ); pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_RADIO8 ); pWndButton[ 0 ]->SetGroup( TRUE ); pWndButton[ !(g_Option.m_bMessengerJoin) ]->SetCheck( TRUE ); #else pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_SHOUT_ON ); pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_SHOUT_OFF ); pWndButton[ 0 ]->SetGroup( TRUE ); pWndButton[ !(g_Option.m_bShout) ]->SetCheck( TRUE ); pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_MESSENGERJOIN_ON ); pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_MESSENGERJOIN_OFF ); pWndButton[ 0 ]->SetGroup( TRUE ); pWndButton[ !(g_Option.m_bMessengerJoin) ]->SetCheck( TRUE ); #endif pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_MESSENGER_ON ); pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_MESSENGER_OFF ); pWndButton[ 0 ]->SetGroup( TRUE ); pWndButton[ !(g_Option.m_bMessenger) ]->SetCheck( TRUE ); #if __VER >= 9 // __CSC_VER9_REMOVE_PKSETTING CRect rect; LPWNDCTRL lpWndCtrl; // 자동 PK 모드 옵션 제거 pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_AUTOPK_ON ); pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_AUTOPK_OFF ); pWndButton[ 0 ]->EnableWindow(FALSE); pWndButton[ 0 ]->SetVisible(FALSE); pWndButton[ 1 ]->EnableWindow(FALSE); pWndButton[ 1 ]->SetVisible(FALSE); CWndStatic* pStatic = (CWndStatic*)GetDlgItem( WIDC_STATIC8 ); pStatic->EnableWindow(FALSE); pStatic->SetVisible(FALSE); // 옵션 위치 제조정 lpWndCtrl = GetWndCtrl( WIDC_STATIC8 ); rect = lpWndCtrl->rect; pStatic = (CWndStatic*)GetDlgItem( WIDC_STATIC9 ); pStatic->Move(rect.TopLeft().x, rect.TopLeft().y); pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_ACCEPTPVP_ON ); lpWndCtrl = GetWndCtrl( WIDC_AUTOPK_ON ); rect = lpWndCtrl->rect; pWndButton[ 0 ]->Move(rect.TopLeft().x, rect.TopLeft().y); pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_ACCEPTPVP_OFF ); lpWndCtrl = GetWndCtrl( WIDC_AUTOPK_OFF ); rect = lpWndCtrl->rect; pWndButton[ 1 ]->Move(rect.TopLeft().x, rect.TopLeft().y); #else //__CSC_VER9_REMOVE_PKSETTING pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_AUTOPK_ON ); pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_AUTOPK_OFF ); pWndButton[ 0 ]->SetGroup( TRUE ); if( g_pPlayer ) pWndButton[ !(g_pPlayer->IsMode( FREEPK_MODE ) ) ]->SetCheck( TRUE ); else pWndButton[ 1 ]->SetCheck( TRUE ); #endif //__CSC_VER9_REMOVE_PKSETTING pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_ACCEPTPVP_ON ); pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_ACCEPTPVP_OFF ); pWndButton[ 0 ]->SetGroup( TRUE ); if( g_pPlayer ) pWndButton[ g_pPlayer->IsMode( PVPCONFIRM_MODE ) ]->SetCheck( TRUE ); else pWndButton[ 0 ]->SetCheck( TRUE ); pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_RADIO12 ); pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_RADIO13 ); pWndButton[ 0 ]->SetGroup( TRUE ); if( g_pPlayer->IsMode( EQUIP_DENIAL_MODE ) ) pWndButton[ 1 ]->SetCheck( TRUE ); else pWndButton[ 0 ]->SetCheck( TRUE ); pWndButton[ 0 ] = (CWndButton*)GetDlgItem( WIDC_RADIO14 ); pWndButton[ 1 ] = (CWndButton*)GetDlgItem( WIDC_RADIO15 ); pWndButton[ 0 ]->SetGroup( TRUE ); if( g_Option.m_bAutoAttack ) pWndButton[ 0 ]->SetCheck( TRUE ); else pWndButton[ 1 ]->SetCheck( TRUE ); // 윈도를 중앙으로 옮기는 부분. CRect rectRoot = m_pWndRoot->GetLayoutRect(); CRect rectWindow = GetWindowRect(); CPoint point( rectRoot.right - rectWindow.Width(), 110 ); Move( point ); MoveParentCenter(); }