• Announcement:
    In order to download VIP files, you need to UPGRADE your account.

Metin2 Bulk Error Edits

Developer
Member
Mar
Threads
2
30
10
8
HubMoney
198
First of all, greetings to everyone,



As 55Games, we have terminated our Metin2 projects, so I will help you with the problems you are experiencing under this topic.

I will also share various error solutions with you under this topic.

I think to keep the topic constantly updated. I will not share all the arrangements at once, I will continue according to the interest in the subject.



I hope I can help our friends who will start new or enthusiastic about some things.



1st Arrangement:

Sudden client shutdown due to a TraceError command in ThingInstance.cpp (Crash)

Code:
void CGraphicThingInstance::RegisterModelThing

// Search

    if (!CheckModelThingIndex(iModelThing))
    {
        if (pModelThing)
            TraceError("CGraphicThingInstance::RegisterModelThing(iModelThing=%d, pModelThing=%s)\n", iModelThing, pModelThing->GetFileName());
        return;
    }
 
// Replace.

2. Arrangement



When the Client is compiled and run in Debug mode, CANNOT_FIND_PACK_FILE fills your syserr.txt / log.txt as .mss due to the game trying to read the sound file of all effects except the sound files.

The arrangement only hides .mss errors in order to see the real deficiencies. The solution can be applied by changing the reading logic of the sound files, but I will not share it. I have already reported the method and event here.

EterPackManager.cpp

Code:
#ifdef _DEBUG
    if (strFileName.find("mss") == std::string::npos)
        TraceError("CANNOT_FIND_PACK_FILE [%s]", strFileName.c_str());
#endif
// Replace.

3. Arrangement



The solution to the sudden client closure that can occur in very rare cases in the Up, Down, Over, Disable functions in the Button on PythonWindow.cpp (Crash)

Code:
    BOOL CButton::SetUpVisual(const char* c_szFileName)
    {
        CResource* pResource = CResourceManager::Instance().GetResourcePointer(c_szFileName);
        if (!pResource || !pResource->IsType(CGraphicImage::Type()))
            return FALSE;

        m_upVisual.SetImagePointer(static_cast<CGraphicImage*>(pResource));
        if (m_upVisual.IsEmpty())
            return FALSE;

        SetSize(m_upVisual.GetWidth(), m_upVisual.GetHeight());
        SetCurrentVisual(&m_upVisual);

        return TRUE;
    }
    BOOL CButton::SetOverVisual(const char* c_szFileName)
    {
        CResource* pResource = CResourceManager::Instance().GetResourcePointer(c_szFileName);
        if (!pResource || !pResource->IsType(CGraphicImage::Type()))
            return FALSE;

        m_overVisual.SetImagePointer(static_cast<CGraphicImage*>(pResource));
        if (m_overVisual.IsEmpty())
            return FALSE;

        SetSize(m_overVisual.GetWidth(), m_overVisual.GetHeight());

        return TRUE;
    }
    BOOL CButton::SetDownVisual(const char* c_szFileName)
    {
        CResource* pResource = CResourceManager::Instance().GetResourcePointer(c_szFileName);
        if (!pResource || !pResource->IsType(CGraphicImage::Type()))
            return FALSE;

        m_downVisual.SetImagePointer(static_cast<CGraphicImage*>(pResource));
        if (m_downVisual.IsEmpty())
            return FALSE;

        SetSize(m_downVisual.GetWidth(), m_downVisual.GetHeight());

        return TRUE;
    }
    BOOL CButton::SetDisableVisual(const char* c_szFileName)
    {
        CResource* pResource = CResourceManager::Instance().GetResourcePointer(c_szFileName);
        if (!pResource || !pResource->IsType(CGraphicImage::Type()))
            return FALSE;

        m_disableVisual.SetImagePointer(static_cast<CGraphicImage*>(pResource));
        if (m_downVisual.IsEmpty())
            return FALSE;

        SetSize(m_disableVisual.GetWidth(), m_disableVisual.GetHeight());

        return TRUE;
    }
// Replace.

4. Arrangement



Solution for sudden client closure due to null pointer in TextureSet.cpp ( Crash)

Code:
bool CTextureSet::SetTexture

// in

CResource* pResource = CResourceManager::Instance().GetResourcePointer(c_szFileName);

// Add the following code below.

    if (!pResource)
        return false;

/////////////////////////////////////////////////
bool CTextureSet::AddTexture

// in

CResource* pResource = CResourceManager::Instance().GetResourcePointer(c_szFileName);

// Add the following code below.

    if (!pResource)
        return false;
 
Last edited by a moderator:
Metin2Hub Bot
M2Hub Bot
Feb
Threads
65
1,624
1
660
113
HubMoney
1,025
Öncelikle herkese selamlar,

55Games olarak Metin2 projelerimizi sonlandırmış bulunmaktayız bundan dolayı bu konu altından hem yaşadığınız sorunlara yardımcı olacağım.
Hem de çeşitli hata çözümlerini bu konu altından sizlerle paylaşacağım.
Konuyu sürekli güncel tutmayı düşünüyorum. Tüm düzenlemeleri bir anda paylaşmayacağım konuya olan ilgiye göre devam edeceğim.

Artık benden Metin2 işleri geçti umarım yeni başlayacak veya bazı şeylere heves eden arkadaşlarımıza yardımcı olabilirim.

1. Düzenleme

ThingInstance.cpp üzerindeki bir TraceError komutundan dolayı clientin aniden kapanması ( Crash )

Code:
void CGraphicThingInstance::RegisterModelThing

// Aratın

    if (!CheckModelThingIndex(iModelThing))
    {
        if (pModelThing)
            TraceError("CGraphicThingInstance::RegisterModelThing(iModelThing=%d, pModelThing=%s)\n", iModelThing, pModelThing->GetFileName());
        return;
    }
  
// Bu şekilde değiştirin.

2. Düzenleme

Client Debug modunda derlenip çalıştırıldığında CANNOT_FIND_PACK_FILE kısmında ses dosyalarının dışında tüm efektlerin ses dosyasını oyunun okumaya çalışmasından dolayı .mss diye syserr.txt / log.txt 'nizin dolması.
Yapılan düzenleme sadece gerçek eksikleri görebilmek için .mss hatalarını gizlemektedir. Ses dosyalarının okuma mantığı değiştirilerek çözüm uygulanabilir fakat bunu paylaşmayacağım. Yöntemi ve olayı burada bildirdim zaten.

EterPackManager.cpp

Code:
#ifdef _DEBUG
    if (strFileName.find("mss") == std::string::npos)
        TraceError("CANNOT_FIND_PACK_FILE [%s]", strFileName.c_str());
#endif
// Bu şekilde değiştirin.

3. Düzenleme

PythonWindow.cpp üzerinde Button 'daki Up, Down, Over, Disable fonksiyonlarındaki çok nadir durumlarda oluşabilen aniden client kapanmasının çözümü ( Crash )

Code:
    BOOL CButton::SetUpVisual(const char* c_szFileName)
    {
        CResource* pResource = CResourceManager::Instance().GetResourcePointer(c_szFileName);
        if (!pResource || !pResource->IsType(CGraphicImage::Type()))
            return FALSE;

        m_upVisual.SetImagePointer(static_cast<CGraphicImage*>(pResource));
        if (m_upVisual.IsEmpty())
            return FALSE;

        SetSize(m_upVisual.GetWidth(), m_upVisual.GetHeight());
        SetCurrentVisual(&m_upVisual);

        return TRUE;
    }
    BOOL CButton::SetOverVisual(const char* c_szFileName)
    {
        CResource* pResource = CResourceManager::Instance().GetResourcePointer(c_szFileName);
        if (!pResource || !pResource->IsType(CGraphicImage::Type()))
            return FALSE;

        m_overVisual.SetImagePointer(static_cast<CGraphicImage*>(pResource));
        if (m_overVisual.IsEmpty())
            return FALSE;

        SetSize(m_overVisual.GetWidth(), m_overVisual.GetHeight());

        return TRUE;
    }
    BOOL CButton::SetDownVisual(const char* c_szFileName)
    {
        CResource* pResource = CResourceManager::Instance().GetResourcePointer(c_szFileName);
        if (!pResource || !pResource->IsType(CGraphicImage::Type()))
            return FALSE;

        m_downVisual.SetImagePointer(static_cast<CGraphicImage*>(pResource));
        if (m_downVisual.IsEmpty())
            return FALSE;

        SetSize(m_downVisual.GetWidth(), m_downVisual.GetHeight());

        return TRUE;
    }
    BOOL CButton::SetDisableVisual(const char* c_szFileName)
    {
        CResource* pResource = CResourceManager::Instance().GetResourcePointer(c_szFileName);
        if (!pResource || !pResource->IsType(CGraphicImage::Type()))
            return FALSE;

        m_disableVisual.SetImagePointer(static_cast<CGraphicImage*>(pResource));
        if (m_downVisual.IsEmpty())
            return FALSE;

        SetSize(m_disableVisual.GetWidth(), m_disableVisual.GetHeight());

        return TRUE;
    }
// Bu kısmı direkt bu şekilde değiştirin.

4. Düzenleme

TextureSet.cpp üzerinde pointerin null gelmesinden dolayı oluşan aniden client kapanmasının çözümü ( Crash )

Code:
bool CTextureSet::SetTexture

// içerisinde

CResource* pResource = CResourceManager::Instance().GetResourcePointer(c_szFileName);

// Altına aşağıdaki kodu ekle.

    if (!pResource)
        return false;

/////////////////////////////////////////////////
bool CTextureSet::AddTexture

// içerisinde

CResource* pResource = CResourceManager::Instance().GetResourcePointer(c_szFileName);

// Altına aşağıdaki kodu ekle.

    if (!pResource)
        return false;

Hello dear user,

Your post will be under surveillance by bots for the next few hours.

Forum description : Metin2 private server, Metin2 download, Metin2 support, Metin2 Forum, Metin2 Pvp Servers, Errors, Bugs, Requests, Metin2 Pvp Forum, Everything About Metin2.
 
Top
AdBlock Detected

We get it, advertisements are annoying!

Sure, ad-blocking software does a great job at blocking ads, but it also blocks useful features of our website. For the best site experience please disable your AdBlocker.

I've Disabled AdBlock