Jump to content

Fix Korean Errors #PART1


Recommended Posts

  • Premium

Fix Dungeon count monsters:

Dungeon.cpp

struct FCountMonster
{
    int n;
    FCountMonster() : n(0) {};
    void operator()(LPENTITY ent)
    {
        if (ent->IsType(ENTITY_CHARACTER))
        {
            LPCHARACTER ch = (LPCHARACTER) ent;
             if (ch->IsMonster() || ch->IsStone())//FIX
                n++;
        }
    }
};

(Function was keeping also NPC, it could make you ugly problems).

 

 

Fix Dungeon memory usage:

namespace
{
    struct FNotice
    {
        FNotice(const char * psz) : m_psz(psz)
        {
        }

        void operator() (LPENTITY ent)
        {
            if (ent->IsType(ENTITY_CHARACTER))
            {
                LPCHARACTER ch = (LPCHARACTER) ent;
                if (ch->IsPC()) //FIX
                    ch->ChatPacket(CHAT_TYPE_NOTICE, "%s", m_psz);
            }
        }

        const char * m_psz;
    };
}

 

Just 2 errors.
I hope that it'll be useful

Edited by WeedHex
  • Metin2 Dev 1
  • Love 26
Link to comment
Share on other sites

  • 9 months later...
  • 2 months later...

Announcements



×
×
  • Create New...

Important Information

Terms of Use / Privacy Policy / Guidelines / We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.