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!

[Release] Show uid and create date time in Item Info

Newbie Spellweaver
Joined
Oct 21, 2020
Messages
24
Reaction score
16
Hi all,

In this post i show you how i'm show item Uid and Create Datetime in Item Info
Hope it will help little for who need it:lol:


RD2diOo - [Release] Show uid and create date time in Item Info - RaGEZONE Forums


1. Add new define

Code:
#define STRITEM_INFO_UID         "\\eItem Uid: \\r%I64d\\r"  // for player
#define STRITEM_INFO_IDX         "\\eItem Uid: \\r%I64d (ID: %d)\\r" // show ID for GM


2.INFItemInfo.cpp

Code:
void CINFItemInfo::SetItemUnique(int nParameterIndex)
{
    if (COMPARE_RACE(g_pShuttleChild->m_myShuttleInfo.Race, RACE_OPERATION | RACE_GAMEMASTER)) 
    {
        wsprintf(m_strItemInfo[nParameterIndex], STRITEM_INFO_IDX, m_pRefItemInfo->UniqueNumber, m_pRefItemInfo->ItemNum);
    }
    else
    {
        wsprintf(m_strItemInfo[nParameterIndex], STRITEM_INFO_UID, m_pRefItemInfo->UniqueNumber);
    }
}

void CINFItemInfo::SetItemDate(int nParameterIndex)
{
     wsprintf(m_strItemInfo[nParameterIndex], STRITEM_INFO_TIME,
        m_pRefItemInfo->CreatedTime.Day, 
        m_pRefItemInfo->CreatedTime.Month, 
        m_pRefItemInfo->CreatedTime.Year,
        m_pRefItemInfo->CreatedTime.Hour,
        m_pRefItemInfo->CreatedTime.Minute,
        m_pRefItemInfo->CreatedTime.Second);
}

And all you need is call new function in all Set Attribute Function (SetPrimaryWeaponInfo, SetSecondaryWeaponInfo,..) like this and fix bug your self :eek:tt1:

Code:
SetItemUnique(index++);
SetItemDate(index++);
 

Attachments

You must be registered for see attachments list
Last edited:
Back
Top