
Originally Posted by
quskevel
Kundun Trash Item (from event item bag) Count and Kundun Ancient Drop Item Count (Static)
Go to your server and open CommonServer.cfg:
find KundunHPLogSaveTime, type enter and paste this:
KundunDropItemCount = 7
KundunDropAncItemCount = 1
Your CommonServer.cfg like this:
KundunMarkDropRate = 15
KundunRefillHPSec = 600
KundunRefillHP = 30000
KundunRefillHPTime = 600
KundunHPLogSaveTime = 120
KundunDropItemCount = 7
KundunDropAncItemCount = 1
Go to your source code and open it.
Open FileName - gObjMonster.cpp and find int iMaxNumOfRewardItem = 3; (or int iMaxNumOfRewardItem)
change it to int iMaxNumOfRewardItem = g_bKalimaKundunItemCount;
After this type enter and add new line:
int iMaxNumOfAncientItem = g_bKalimaKundunAncItemCount;
Your source look like this:
int iMaxNumOfRewardItem = g_bKalimaKundunItemCount;
int iMaxNumOfAncientItem = g_bKalimaKundunAncItemCount;
Below it find
MakeRewardSetItem(MaxHitUser, cDropX, cDropY, 1, lpObj->MapNumber);
and delete from it all code about SetItem:
Your source look like this:
for ( int i=0; i < iMaxNumOfRewardItem; i++ )
{
BYTE cDropX = lpObj->X;
BYTE cDropY = lpObj->Y;
if ( CHECK_LIMIT(MaxHitUser, OBJMAX) )
{
LogAddTD("[ЎЪKundun EVENT] In KALIMA(7), ItemDrop MaxHitUser [%d][%s][%s]",
i, gObj[MaxHitUser].AccountID, gObj[MaxHitUser].Name);
KUNDUN_EVENT_LOG.Output("[ЎЪKundun EVENT] In KALIMA(7), ItemDrop MaxHitUser [%d][%s][%s]",
i, gObj[MaxHitUser].AccountID, gObj[MaxHitUser].Name);
}
else
{
LogAddTD("[ЎЪKundun EVENT] In KALIMA(7), ItemDrop MaxHitUser [%d][%s][%s]",
i, lpTargetObj->AccountID, lpTargetObj->Name);
KUNDUN_EVENT_LOG.Output("[ЎЪKundun EVENT] In KALIMA(7), ItemDrop MaxHitUser [%d][%s][%s]",
i, lpTargetObj->AccountID, lpTargetObj->Name);
}
if ( !gObjGetRandomItemDropLocation(lpObj->MapNumber, cDropX, cDropY, 4, 4, 10))
{
cDropX = lpObj->X;
cDropY = lpObj->Y;
}
if ( OBJMAX_RANGE(MaxHitUser ))
{
LogAddTD("[ЎЫKundun EVENT] Drop Item [%d][%s][%s]",
i, gObj[MaxHitUser].AccountID, gObj[MaxHitUser].Name);
KUNDUN_EVENT_LOG.Output("[ЎЫKundun EVENT] Drop Item [%d][%s][%s]",
i, gObj[MaxHitUser].AccountID, gObj[MaxHitUser].Name);
}
else
{
LogAddTD("[ЎЫKundun EVENT] Drop Item [%d][%s][%s]",
i, lpTargetObj->AccountID, lpTargetObj->Name);
KUNDUN_EVENT_LOG.Output("[ЎЫKundun EVENT] Drop Item [%d][%s][%s]",
i, lpTargetObj->AccountID, lpTargetObj->Name);
}
KundunEventItemBoxOpen(lpTargetObj, lpObj->MapNumber, cDropX, cDropY);
}
after it:
add below new code - new code:
for ( int i=0; i < iMaxNumOfAncientItem; i++ )
{
BYTE cDropX = lpObj->X;
BYTE cDropY = lpObj->Y;
if ( !gObjGetRandomItemDropLocation(lpObj->MapNumber, cDropX, cDropY, 4, 4, 10))
{
cDropX = lpObj->X;
cDropY = lpObj->Y;
}
if ( lpObj->Class == 275 )
{
MakeRewardSetItem(MaxHitUser, cDropX, cDropY, 1, lpObj->MapNumber);
LogAddTD("[ЎЫKundun EVENT] Drop SetItem ");
KUNDUN_EVENT_LOG.Output("[ЎЫKundun EVENT] Drop SetItem ");
continue;
}
}
so ok we are create all function, but need read it from config.
Go to GameMain.h
and add it:
extern int g_bKalimaKundunItemCount;
extern int g_bKalimaKundunAncItemCount;
after this:
extern int g_iBlockRaklionMapEnter;
Go to GameMain.cpp
and add it:
int g_bKalimaKundunItemCount;
int g_bKalimaKundunAncItemCount;
after this:
BOOL g_bRaklionSelupanDropZen;
so,
add it:
g_bKalimaKundunItemCount = GetPrivateProfileInt("GameServerInfo","KundunDropItemCount",20, gDirPath.GetNewPath("commonserver.cfg"));
g_bKalimaKundunAncItemCount = GetPrivateProfileInt("GameServerInfo","KundunDropAncItemCount",1, gDirPath.GetNewPath("commonserver.cfg"));
after this:
g_iBlockRaklionMapEnter = GetPrivateProfileInt("GameServerInfo","BlockRaklionMapEnter",0, gDirPath.GetNewPath("commonserver.cfg"));
And Congulation you have full config kundun drop (how many items from it drop(Anc/normal))