ko4life-net / ko

Open source development of the game Knight Online. This is a reversed engineered old version of the game aiming to replicate the nostalgic experience we all once had <3
https://github.com/ko4life-net/ko
MIT License
55 stars 22 forks source link

Description needs to get added to UIImageTooltipDlg.cpp #264

Open UTengine opened 1 week ago

UTengine commented 1 week ago

Search before asking

Description

    m_pStr[iIndex]->SetStyle(UI_STR_TYPE_HALIGN, UISTYLE_STRING_ALIGNCENTER);
    sprintf(szBuff, spItem->pItemBasic->szRemark.c_str());

Description to unique, scrolls, stackable, quest items are missing in UIImageTooltipDlg.cpp I once added a check here once to see if the szRemark string had a size bigger than 0-1 then did index++. But since we want to stick to official behavior I will leave this to someone else.

image

Use case

Implement It's giving me ebola

Are you willing to work on and submit a PR to address the issue?

UTengine commented 1 week ago

if (!spItem->pItemBasic->szRemark.empty()) { // szRemark is not empty, proceed with setting it m_pStr[iIndex]->SetStyle(UI_STR_TYPE_HALIGN, UISTYLE_STRING_ALIGNCENTER); sprintf(szBuff, spItem->pItemBasic->szRemark.c_str()); m_pstdstr[iIndex] = szBuff; iIndex++; }