Welcome!

Join our community of MMO enthusiasts and game developers! By registering, you'll gain access to discussions on the latest developments in MMO server files and collaborate with like-minded individuals. Join us today and unlock the potential of MMO server development!

Join Today!

[Small Share] GS Scrolling event issue while UI is open FIX

Junior Spellweaver
Joined
Mar 23, 2020
Messages
122
Reaction score
19
Look for GLControlBase::DefaultCameraUpdate and make the changes, just add the windows that I forgot. I'll try to fix the bugs on the GS release, and I'm looking for a friend, let's help together and fix the bugs :giggle:, leave me a DM.

C++:
void GLControlBase::DefaultCameraUpdate( float fTime, float fElapsedTime )
{
    GASSERT(m_pKeySetting);

    DxViewPort& cViewPort = DxViewPort::GetInstance();

    POINT ptCurPos;
    GetCursorPos ( &ptCurPos );
    BOOL bTARPOSWIN = cViewPort.GetMouseTargetPosWnd ( D3DXVECTOR3((float)ptCurPos.x,(float)ptCurPos.y,0) );

    BOOL bCURSOR_SHOW(TRUE);
    DxInputDevice &dxInputDev = DxInputDevice::GetInstance();

    DWORD dwKEY_DIRECTIONMODE(DXKEY_IDLE);
    DWORD dwKEY_ZOOMIN(DXKEY_IDLE), dwKEY_ZOOMOUT(DXKEY_IDLE);
    DWORD dwKEY_RIGHT(DXKEY_IDLE), dwKEY_LEFT(DXKEY_IDLE);
    DWORD dwKEY_UP(DXKEY_IDLE), dwKEY_DOWN(DXKEY_IDLE);

    int nKEY_ZOOM(0);
    int dx(0), dy(0), dz(0);

    //skill scroll issue test - Tatsuya
    //bool bZoomBlock = false;//GfxInterfaceBase::GetInstance()->IsMouseHitUI();
    bool bZoomBlock = m_pGaeaClient->GetInterface()->UiIsVisibleGroup(SKILL_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(QUEST_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(RENEW_SKILL_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(MAP_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(ITEM_MIX_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(STUDENTRECORD_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(CLUB_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(BUS_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(TAXI_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(POINT_SHOP_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(RENEW_SKILL_WINDOW);

    EngineDeviceMan* pDevice = m_pGaeaClient->GetEngineDevice();

    DXInputString* pInputString = pDevice->GetInputString();
    if ( !pInputString || pInputString->IsOn() ) bZoomBlock = true;

    if ( bTARPOSWIN )
    {
        m_pKeySetting->GetMouseMove ( dx, dy, dz );

        dwKEY_DIRECTIONMODE = m_pKeySetting->GetKeyState( EMSHORTCUTS_CAMERA_DIRECTIONMODE );

        // ¹æÇâÅ° Ä«¸Þ¶ó ȸÀü.
        if ( !IsKeyboardBlock(fTime, fElapsedTime) )
        {
            dwKEY_RIGHT   = m_pKeySetting->GetKeyState( EMSHORTCUTS_CAMERA_RIGHT,    FLAG_GETKEYSTATE_ONLY_KEYBOARD );
            dwKEY_LEFT    = m_pKeySetting->GetKeyState( EMSHORTCUTS_CAMERA_LEFT,    FLAG_GETKEYSTATE_ONLY_KEYBOARD );
            dwKEY_UP      = m_pKeySetting->GetKeyState( EMSHORTCUTS_CAMERA_UP,        FLAG_GETKEYSTATE_ONLY_KEYBOARD );
            dwKEY_DOWN      = m_pKeySetting->GetKeyState( EMSHORTCUTS_CAMERA_DOWN,    FLAG_GETKEYSTATE_ONLY_KEYBOARD );

            if ( !bZoomBlock )
            {
                dwKEY_ZOOMIN  = m_pKeySetting->GetKeyState( EMSHORTCUTS_CAMERA_ZOOMIN,  FLAG_GETKEYSTATE_ONLY_KEYBOARD );
                dwKEY_ZOOMOUT = m_pKeySetting->GetKeyState( EMSHORTCUTS_CAMERA_ZOOMOUT, FLAG_GETKEYSTATE_ONLY_KEYBOARD );
            }
        }

        if ( !bZoomBlock )
        {
            nKEY_ZOOM = m_pKeySetting->GetKeyAmount( EMSHORTCUTS_CAMERA_ZOOM );
        }
    }
 
Junior Spellweaver
Joined
Apr 2, 2019
Messages
137
Reaction score
26
Look for GLControlBase::DefaultCameraUpdate and make the changes, just add the windows that I forgot. I'll try to fix the bugs on the GS release, and I'm looking for a friend, let's help together and fix the bugs :giggle:, leave me a DM.

C++:
void GLControlBase::DefaultCameraUpdate( float fTime, float fElapsedTime )
{
    GASSERT(m_pKeySetting);

    DxViewPort& cViewPort = DxViewPort::GetInstance();

    POINT ptCurPos;
    GetCursorPos ( &ptCurPos );
    BOOL bTARPOSWIN = cViewPort.GetMouseTargetPosWnd ( D3DXVECTOR3((float)ptCurPos.x,(float)ptCurPos.y,0) );

    BOOL bCURSOR_SHOW(TRUE);
    DxInputDevice &dxInputDev = DxInputDevice::GetInstance();

    DWORD dwKEY_DIRECTIONMODE(DXKEY_IDLE);
    DWORD dwKEY_ZOOMIN(DXKEY_IDLE), dwKEY_ZOOMOUT(DXKEY_IDLE);
    DWORD dwKEY_RIGHT(DXKEY_IDLE), dwKEY_LEFT(DXKEY_IDLE);
    DWORD dwKEY_UP(DXKEY_IDLE), dwKEY_DOWN(DXKEY_IDLE);

    int nKEY_ZOOM(0);
    int dx(0), dy(0), dz(0);

    //skill scroll issue test - Tatsuya
    //bool bZoomBlock = false;//GfxInterfaceBase::GetInstance()->IsMouseHitUI();
    bool bZoomBlock = m_pGaeaClient->GetInterface()->UiIsVisibleGroup(SKILL_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(QUEST_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(RENEW_SKILL_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(MAP_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(ITEM_MIX_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(STUDENTRECORD_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(CLUB_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(BUS_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(TAXI_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(POINT_SHOP_WINDOW) ||
                    m_pGaeaClient->GetInterface()->UiIsVisibleGroup(RENEW_SKILL_WINDOW);

    EngineDeviceMan* pDevice = m_pGaeaClient->GetEngineDevice();

    DXInputString* pInputString = pDevice->GetInputString();
    if ( !pInputString || pInputString->IsOn() ) bZoomBlock = true;

    if ( bTARPOSWIN )
    {
        m_pKeySetting->GetMouseMove ( dx, dy, dz );

        dwKEY_DIRECTIONMODE = m_pKeySetting->GetKeyState( EMSHORTCUTS_CAMERA_DIRECTIONMODE );

        // ¹æÇâÅ° Ä«¸Þ¶ó ȸÀü.
        if ( !IsKeyboardBlock(fTime, fElapsedTime) )
        {
            dwKEY_RIGHT   = m_pKeySetting->GetKeyState( EMSHORTCUTS_CAMERA_RIGHT,    FLAG_GETKEYSTATE_ONLY_KEYBOARD );
            dwKEY_LEFT    = m_pKeySetting->GetKeyState( EMSHORTCUTS_CAMERA_LEFT,    FLAG_GETKEYSTATE_ONLY_KEYBOARD );
            dwKEY_UP      = m_pKeySetting->GetKeyState( EMSHORTCUTS_CAMERA_UP,        FLAG_GETKEYSTATE_ONLY_KEYBOARD );
            dwKEY_DOWN      = m_pKeySetting->GetKeyState( EMSHORTCUTS_CAMERA_DOWN,    FLAG_GETKEYSTATE_ONLY_KEYBOARD );

            if ( !bZoomBlock )
            {
                dwKEY_ZOOMIN  = m_pKeySetting->GetKeyState( EMSHORTCUTS_CAMERA_ZOOMIN,  FLAG_GETKEYSTATE_ONLY_KEYBOARD );
                dwKEY_ZOOMOUT = m_pKeySetting->GetKeyState( EMSHORTCUTS_CAMERA_ZOOMOUT, FLAG_GETKEYSTATE_ONLY_KEYBOARD );
            }
        }

        if ( !bZoomBlock )
        {
            nKEY_ZOOM = m_pKeySetting->GetKeyAmount( EMSHORTCUTS_CAMERA_ZOOM );
        }
    }


Thank you! 🫶
 
Back
Top