how to fix this bug

Results 1 to 9 of 9
  1. #1
    Account Upgraded | Title Enabled! medotarek is offline
    MemberRank
    Apr 2012 Join Date
    Egypt/RageZoneLocation
    615Posts

    how to fix this bug

    hello guys
    how to fix Resolution bug in Gunz 1.5 Repack By jur13n


  2. #2
    Member thead74 is offline
    MemberRank
    Feb 2013 Join Date
    51Posts

    Re: how to fix this bug

    ZOptionInterface.cpp
    // ComboBox
    {
    MComboBox *pWidget = (MComboBox*)pResource->FindWidget("ScreenResolution");
    if(pWidget)
    {
    pWidget->RemoveAll();
    gDisplayMode.clear();

    int dmIndex = 0;
    char szBuf[256];

    D3DDISPLAYMODE ddm;

    D3DFORMAT format[2] = {
    D3DFMT_X8R8G8B8,
    D3DFMT_R5G6B5
    };

    for( int i=0;i<2;i++)
    {
    int nDM = RGetAdapterModeCount( format[i] );

    mlog("Number of Display mode : %d\n", nDM );

    for( int idm = 0 ; idm < nDM; ++idm )
    {
    if( REnumAdapterMode( D3DADAPTER_DEFAULT,format[i], idm, &ddm ))
    {
    if( ddm.Width < 640 || ddm.Height < 480 )
    continue;

    if( ((float)ddm.Height / (float)ddm.Width != 0.75f) &&
    ((float)ddm.Height / (float)ddm.Width != 0.625f) )
    continue;

    ddm.RefreshRate = DEFAULT_REFRESHRATE;

    if( ddm.Format == D3DFMT_X8R8G8B8 || ddm.Format == D3DFMT_R5G6B5 )
    {
    map<int, D3DDISPLAYMODE>::iterator iter_ = find_if( gDisplayMode.begin(), gDisplayMode.end(), value_equals<int, D3DDISPLAYMODE>(ddm));
    if( iter_ == gDisplayMode.end() )
    {
    gDisplayMode.insert( map<int, D3DDISPLAYMODE>::value_type( dmIndex++, ddm ) );
    sprintf( szBuf, "%d x %d %dbpp", ddm.Width, ddm.Height, ddm.Format==D3DFMT_X8R8G8B8?32:16 );
    pWidget->Add(szBuf);
    }
    }
    }
    }
    }

    // ¸¸¾à µî·ÏµÈ ÇØ»óµµ°¡ Çϳªµµ ¾øÀ»°æ¿ì °­Á¦·Î µî·Ï
    if( gDisplayMode.size() == 0 )
    {
    for( int i = 0 ; i < 10; ++i )
    {
    ddm.Width = widths[i/2];
    ddm.Height = heights[i/2];
    ddm.RefreshRate = DEFAULT_REFRESHRATE;
    ddm.Format = ( ( i%2 == 1) ? D3DFMT_X8R8G8B8 : D3DFMT_R5G6B5 );

    int bpp = (i%2 == 1)? 32 : 16;
    gDisplayMode.insert( map<int, D3DDISPLAYMODE>::value_type(i,ddm) );
    sprintf( szBuf, "%dx%d %d bpp", ddm.Width, ddm.Height, bpp );
    pWidget->Add( szBuf );
    }
    }
    ddm.Width = RGetScreenWidth();
    ddm.Height = RGetScreenHeight();
    ddm.RefreshRate = DEFAULT_REFRESHRATE;
    ddm.Format = RGetPixelFormat();
    map< int, D3DDISPLAYMODE>::iterator iter = find_if( gDisplayMode.begin(), gDisplayMode.end(), value_equals<int, D3DDISPLAYMODE>(ddm));
    pWidget->SetSelIndex( iter->first );
    }

  3. #3
    Account Upgraded | Title Enabled! medotarek is offline
    MemberRank
    Apr 2012 Join Date
    Egypt/RageZoneLocation
    615Posts

    Re: how to fix this bug

    Quote Originally Posted by thead74 View Post
    ZOptionInterface.cpp
    ty but now i don't have full resolution list

  4. #4
    Member thead74 is offline
    MemberRank
    Feb 2013 Join Date
    51Posts

    Re: how to fix this bug

    Quote Originally Posted by medotarek View Post
    ty but now i don't have full resolution list
    upload your ZOptionInterface.cpp for check this

  5. #5
    Account Upgraded | Title Enabled! medotarek is offline
    MemberRank
    Apr 2012 Join Date
    Egypt/RageZoneLocation
    615Posts

    Re: how to fix this bug


  6. #6
    Member thead74 is offline
    MemberRank
    Feb 2013 Join Date
    51Posts

    Re: how to fix this bug

    your have old for compare ?

  7. #7
    Account Upgraded | Title Enabled! medotarek is offline
    MemberRank
    Apr 2012 Join Date
    Egypt/RageZoneLocation
    615Posts

    Re: how to fix this bug

    Quote Originally Posted by thead74 View Post
    your have old for compare ?
    iam going to winmerg it and see

  8. #8
    Fuck Army. sahar042 is offline
    MemberRank
    Jul 2009 Join Date
    833Posts

    Re: how to fix this bug

    Quote Originally Posted by medotarek View Post
    iam going to winmerg it and see
    Than why you didn't did it before you opened this thread.?

  9. #9
    Account Upgraded | Title Enabled! medotarek is offline
    MemberRank
    Apr 2012 Join Date
    Egypt/RageZoneLocation
    615Posts

    Re: how to fix this bug

    Quote Originally Posted by sahar042 View Post
    Than why you didn't did it before you opened this thread.?
    lol sorry MR.Sahar ;)



Advertisement