Jump to content

How To Fix Belt Inventory Bug 2


Rideas

Recommended Posts

Is Bug : https://www.youtube.com/watch?v=Sev7dsUrkdk&feature=youtu.be


Open char_item.cpp


Search:

 

const int ITEM_BROKEN_METIN_VNUM = 28960;



Add:

 

#define ERROR_MSG(exp, msg)  \
	if (true == (exp)) { \
			ChatPacket(CHAT_TYPE_INFO, msg); \
			return false; \
	}

Search:

 

bool CHARACTER::UseItem(TItemPos Cell, TItemPos DestCell)
{
    WORD wCell = Cell.cell;
    BYTE window_type = Cell.window_type;
    //WORD wDestCell = DestCell.cell;
    //BYTE bDestInven = DestCell.window_type;
    LPITEM item;

    if (!CanHandleItem())
        return false;
        

    if (!IsValidItemPosition(Cell) || !(item = GetItem(Cell)))
            return false;


Add:

 

	if (ITEM_BELT == item->GetType())
		ERROR_MSG(CBeltInventoryHelper::IsExistItemInBeltInventory(this), "Error text");






Best Regards Rideas.

Edited by Rideas
  • Love 7
Link to comment
Share on other sites

	if (ITEM_BELT == item->GetType())
		ERROR_MSG(CBeltInventoryHelper::IsExistItemInBeltInventory(this), "Error text");
if (item->GetType() == ITEM_BELT && CBeltInventoryHelper::IsExistItemInBeltInventory(this))
	ChatPacket(CHAT_TYPE_INFO, LC_TEXT("이는에러 메시지 이다"));

At first, ERROR_MSG define is useless here for me. This condition will be helpful for everyone.

Kind Regards ~ Ken

  • Love 1

Do not be sorry, be better.

Link to comment
Share on other sites

	if (ITEM_BELT == item->GetType())
		ERROR_MSG(CBeltInventoryHelper::IsExistItemInBeltInventory(this), "Error text");
if (item->GetType() == ITEM_BELT && CBeltInventoryHelper::IsExistItemInBeltInventory(this))
	ChatPacket(CHAT_TYPE_INFO, LC_TEXT("이는에러 메시지 이다"));

At first, ERROR_MSG define is useless here for me. This condition will be helpful for everyone.

Kind Regards ~ Ken

Thanks

Link to comment
Share on other sites

	if (ITEM_BELT == item->GetType())
		ERROR_MSG(CBeltInventoryHelper::IsExistItemInBeltInventory(this), "Error text");
if (item->GetType() == ITEM_BELT && CBeltInventoryHelper::IsExistItemInBeltInventory(this))
	ChatPacket(CHAT_TYPE_INFO, LC_TEXT("이는에러 메시지 이다"));

At first, ERROR_MSG define is useless here for me. This condition will be helpful for everyone.

Kind Regards ~ Ken

place the 1st or 2nd?

Link to comment
Share on other sites

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.