What wrong with this ?
https://s10.postimg.org/yrd769j55/bug.jpg
https://s10.postimg.org/8nj2r0urt/bug2.jpg
@navirius
Please can you help me ?? i cant put any item.. and no option show up .. i already make it card but still nothing..
Printable View
What wrong with this ?
https://s10.postimg.org/yrd769j55/bug.jpg
https://s10.postimg.org/8nj2r0urt/bug2.jpg
@navirius
Please can you help me ?? i cant put any item.. and no option show up .. i already make it card but still nothing..
Find this code on ItemRebuild.cpp
follow ReqRebuildMoveSealedCard function, maybe different function on your source,PHP Code:if( dwMsg & UIMSG_LB_UP )
{
GLGaeaClient::GetInstance().GetCharacter()->ReqRebuildMoveSealedCard();
m_bSEAL = true;
}
your ReqRebuildMoveSealedCard must be like this
then you must follow that message to server, make sure you add this line to GLCharMsg.cpp function MsgProcessPHP Code:HRESULT GLCharacter::ReqRebuildMoveSealedCard()
{
GLMSG::SNET_REBUILD_MOVE_SEALED_CARD NetMsg;
if( m_sPreInventoryItem.VALID() )
{
SITEMCUSTOM sPreItem = GET_PREHOLD_ITEM();
SITEM* pItem = GLItemMan::GetInstance().GetItem( sPreItem.sNativeID );
if( pItem && pItem->sBasicOp.emItemType == ITEM_SEALED_CARD )
{
NetMsg.wPosX = m_sPreInventoryItem.wPosX;
NetMsg.wPosY = m_sPreInventoryItem.wPosY;
}
m_sPreInventoryItem.RESET();
}
NETSENDTOFIELD( &NetMsg );
return S_OK;
}
of course , you must have MsgReqRebuildMoveSealedCard function, if you follow instruction on original thread I think its okayPHP Code:case NET_MSG_REBUILD_SEALED_CARD: MsgReqRebuildMoveSealedCard(nmg); break;
@navirius
I already follow your post and post in sealed card.. Still no luck.. I already put all and check it.. May problem nothing appear random option
you can't place sealed card on slot or you can't see random option that need to be sealed?
I can put sealed card on slot but i can pud anything ang and i cant see random option ..
I think the problem is glcharactereq.. Can you share yours? @navirius
@navirius .. Can i add you in fb for more info about this problem.. Still no luck
I still on the way, if you cant put item, you must make sure that item have random option setting on item editor
random option will showed if item already have random option
Sent from my GT-I9300 using Tapatalk
http://i66.tinypic.com/2qmj0he.jpg
What about this @navirius ... still no ok i already make your instruction but still no luck... :(
that what i say, sealed card need optimize, because it has a bug,
I still mobile, I will check my code later for fixing and post it
Sent from my GT-I9300 using Tapatalk
@navirius tnx for helping .. im waiting to your fix Source for this matter tnx alot :)
okay, I tried to help a little with different approach of sealed card, you can try to learn this thing to fit your need or your like
find GLCharData.h, change
toPHP Code:int m_nRebuildOption;
find GLContrlInvenMsg.h, change this codePHP Code:BOOL m_bRebuildOption[SRANDOM_GEN::MAX_OPT];
toPHP Code:struct SNET_REBUILD_OPTION
{
NET_MSG_GENERIC nmg;
int nOption;
SNET_REBUILD_OPTION()
: nOption(-1)
{
nmg.dwSize = sizeof( SNET_REBUILD_OPTION );
nmg.nType = NET_MSG_REBUILD_OPTION;
GASSERT( nmg.dwSize <= NET_DATA_BUFSIZE );
}
};
find GLCharInvenMsg.cpp, replace HRESULT GLChar::MsgReqRebuildSetOption( NET_MSG_GENERIC* nmg ) function with this onePHP Code:struct SNET_REBUILD_OPTION
{
NET_MSG_GENERIC nmg;
int nOption;
BOOL bOptionStats;
SNET_REBUILD_OPTION()
: nOption(-1)
{
nmg.dwSize = sizeof( SNET_REBUILD_OPTION );
nmg.nType = NET_MSG_REBUILD_OPTION;
GASSERT( nmg.dwSize <= NET_DATA_BUFSIZE );
}
};
find GLCharacterMsg.cpp, synchronize part of your code with this one (inside MsgProcess function)PHP Code:HRESULT GLChar::MsgReqRebuildSetOption( NET_MSG_GENERIC* nmg )
{
GLMSG::SNET_REBUILD_OPTION* pNetMsg = (GLMSG::SNET_REBUILD_OPTION*)nmg;
GLMSG::SNET_REBUILD_OPTION NetMsg;
// m_nRebuildOption = -1;
if( pNetMsg->nOption != -1 )
{
NetMsg.nOption = pNetMsg->nOption;
//m_nRebuildOption = NetMsg.nOption;
m_bRebuildOption[pNetMsg->nOption] = pNetMsg->bOptionStats;
}
GLGaeaServer::GetInstance().SENDTOCLIENT( m_dwClientID, &NetMsg );
return S_OK;
}
find GLCharactorReq.cpp, replace ReqRebuildSetOption function with this onePHP Code:case NET_MSG_REBUILD_OPTION:
{
GLMSG::SNET_REBUILD_OPTION* pNetMsg = (GLMSG::SNET_REBUILD_OPTION*)nmg;
m_bRebuildOption[pNetMsg->nOption] = pNetMsg->bOptionStats;
//CInnerInterface::GetInstance().PrintConsoleText("Sealed Card Item Option: %d", m_nRebuildOption );
}
break;
find ItemRebuild.cpp, find TranslateUiMessage function and syncronize your code with this codePHP Code:HRESULT GLCharacter::ReqRebuildSetOption( int nOpt, BOOL bOptStats )
{
GLMSG::SNET_REBUILD_OPTION NetMsg;
SITEMCUSTOM sItemRebuild = GLGaeaClient::GetInstance().GetCharacter()->GET_REBUILD_ITEM();
SITEMCUSTOM sItemRebuildSealed = GLGaeaClient::GetInstance().GetCharacter()->GET_REBUILD_SEALED_CARD();
if( sItemRebuild.sNativeID != NATIVEID_NULL() && sItemRebuildSealed.sNativeID != NATIVEID_NULL() )
{
SITEMCUSTOM sPreItem = GET_REBUILD_SEALED_CARD();
SITEM* pItem = GLItemMan::GetInstance().GetItem( sPreItem.sNativeID );
if( pItem && pItem->sBasicOp.emItemType == ITEM_SEALED_CARD )
{
NetMsg.nOption = nOpt;
NetMsg.bOptionStats = bOptStats;
}
else
{
m_sPreInventoryItem.RESET();
m_sRebuildSealedCard.RESET();
}
}
NETSENDTOFIELD( &NetMsg );
return S_FALSE;
}
you must change MsgReqRebuildResult on GLCharInvenMsg.cpp code to fit this option, especially for pInvenItem->sItemCustom.GENERATE_RANDOM_OPT call, because my code already have heavy modification, I lost original modification for this sealed cardPHP Code:case ITEM_REBUILD_ITEM_OPTION00:
case ITEM_REBUILD_ITEM_OPTION01:
case ITEM_REBUILD_ITEM_OPTION02:
case ITEM_REBUILD_ITEM_OPTION03:
{
if ( CHECK_MOUSEIN_LBUPLIKE( dwMsg ) )
{
int nIndex = ControlID - ITEM_REBUILD_ITEM_OPTION00;
m_pItemOption[nIndex]->SetCheck();
m_nOption = nIndex;
//for(int i = 0; i < 4; i++)
//{
// if ( !m_pItemOption[i]->IsVisible() ) continue;
// if ( i == m_nOption ) continue;
// m_pItemOption[i]->HideCheckOption();
//}
if ( m_nOption != -1 )
{
//CInnerInterface::GetInstance().PrintConsoleText("Selected Option %d", m_nOption);
GLGaeaClient::GetInstance().GetCharacter()->ReqRebuildSetOption( m_nOption, m_pItemOption[m_nOption]->IsChecked() );
}
}
}
break;
for GENERATE_RANDOM_OPT, you can use original sealed card original sealed card instruction, but for me, it does not fit, because it can generate 2 same option, then I modification for GENERATE_RANDOM_OPT call parameter, and make new RESETOptVALUE with selected option,
(sorry, I cant explain with simple word, because code explain more than words)
@navirius what about declaring bOptionStats ?? cant find that code..
you must change the header file for corresponding function and cpp, thats why you need basic c++ programming
Sent from my GT-I9300 using Tapatalk
@navirius its working but the problem is.. when i rebuild the item... cant move the item that i rebuild.. even to loot item from mobs... whats wrong with that ?? i think got bug
GLCharData.cpp is that correct or not ?
Quote:
VOID SCHARDATA2::InitRebuildData()
{
m_sRebuildItem.RESET();
m_sPreInventoryItem.RESET();
m_i64RebuildCost = 0;
m_i64RebuildInput = 0;
m_sRebuildSealedCard.RESET(); // add sealed card
m_bRebuildOption [SRANDOM_GEN::MAX_OPT];
}
for that function add this line
PHP Code:for(int i=0;i<4;i++)
{
m_bRebuildOption[i]=FALSE;
}