Jump to content

Skillbook drop name


Recommended Posts

  • Replies 6
  • Created
  • Last Reply

Top Posters In This Topic

Top Posters In This Topic

  • Premium

#include "../UserInterface/PythonSkill.h"
/*
stuff...
*/

const char * CItemData::GetName() const
{
    CPythonSkill::SSkillData * c_pSkillData;
    bool Skills = CPythonSkill::Instance().GetSkillData(GetSocket(0), &c_pSkillData)

    char szText[1024];
    
    switch (GetType())
    {
        case ITEM_TYPE_POLYMORPH:
            return m_ItemTable.szLocaleName;
            break;
        case ITEM_TYPE_SKILLBOOK:
        case ITEM_TYPE_SKILLFORGET:
            if(Skills)
            {
                sprintf(szText, "%s - %s", m_ItemTable.szLocaleName, c_pSkillData->strName.c_str());
                return szText;
            }
            else
                return m_ItemTable.szLocaleName;
            break;
        default:
            return m_ItemTable.szLocaleName;
            break;
    }

}


 

Link to comment
Share on other sites

28 minutes ago, .T4Ump said:

#include "../UserInterface/PythonSkill.h"
/*
stuff...
*/

const char * CItemData::GetName() const
{
    CPythonSkill::SSkillData * c_pSkillData;
    bool Skills = CPythonSkill::Instance().GetSkillData(GetSocket(0), &c_pSkillData)

    char szText[1024];
    
    switch (GetType())
    {
        case ITEM_TYPE_POLYMORPH:
            return m_ItemTable.szLocaleName;
            break;
        case ITEM_TYPE_SKILLBOOK:
        case ITEM_TYPE_SKILLFORGET:
            if(Skills)
            {
                sprintf(szText, "%s - %s", m_ItemTable.szLocaleName, c_pSkillData->strName.c_str());
                return szText;
            }
            else
                return m_ItemTable.szLocaleName;
            break;
        default:
            return m_ItemTable.szLocaleName;
            break;
    }

}

Not work :))

 

Link to comment
Share on other sites

  • 3 months later...

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now

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.