БlyatMAN 14 Posted June 10 Share Posted June 10 somebody know how to make them stackable? I modified in all protos to be stackable but i think i need also some modification in source code and uiinventory.py...if somebody whiling to help me i'l be thankfull. they stack only if i drop them on the ground and pick them up... but in inventory i cant stack them one by one i hope i explained good Link to comment Share on other sites More sharing options...
Active+ Member Solution m2Ciaran 409 Posted June 10 Active+ Member Solution Share Posted June 10 Hello. You need something like this: uiInventory -> def __DropSrcItemToDestItemInInventory elif item.GetUseType(srcItemVID) in self.USE_TYPE_TUPLE: if player.GetItemIndex(dstItemSlotPos) == srcItemVID: self.__SendMoveItemPacket(srcItemSlotPos, dstItemSlotPos, 0) else: self.__SendUseItemToItemPacket(srcItemSlotPos, dstItemSlotPos) uiInventory -> def __IsUsableItemToItem(self, srcItemVNum, srcSlotPos): else: if item.GetUseType(srcItemVNum) in self.USE_TYPE_TUPLE: return True And make sure that USE_TYPE_TUPLE is defined at the beginning of InventoryWindow class: USE_TYPE_TUPLE = ("USE_CLEAN_SOCKET", "USE_CHANGE_ATTRIBUTE", "USE_ADD_ATTRIBUTE", "USE_ADD_ATTRIBUTE2", "USE_ADD_ACCESSORY_SOCKET", "USE_PUT_INTO_ACCESSORY_SOCKET", "USE_PUT_INTO_BELT_SOCKET", "USE_PUT_INTO_RING_SOCKET") Link to comment Share on other sites More sharing options...
БlyatMAN 14 Posted June 10 Author Share Posted June 10 11 hours ago, m2Ciaran said: Hello. You need something like this: uiInventory -> def __DropSrcItemToDestItemInInventory elif item.GetUseType(srcItemVID) in self.USE_TYPE_TUPLE: if player.GetItemIndex(dstItemSlotPos) == srcItemVID: self.__SendMoveItemPacket(srcItemSlotPos, dstItemSlotPos, 0) else: self.__SendUseItemToItemPacket(srcItemSlotPos, dstItemSlotPos) uiInventory -> def __IsUsableItemToItem(self, srcItemVNum, srcSlotPos): else: if item.GetUseType(srcItemVNum) in self.USE_TYPE_TUPLE: return True And make sure that USE_TYPE_TUPLE is defined at the beginning of InventoryWindow class: USE_TYPE_TUPLE = ("USE_CLEAN_SOCKET", "USE_CHANGE_ATTRIBUTE", "USE_ADD_ATTRIBUTE", "USE_ADD_ATTRIBUTE2", "USE_ADD_ACCESSORY_SOCKET", "USE_PUT_INTO_ACCESSORY_SOCKET", "USE_PUT_INTO_BELT_SOCKET", "USE_PUT_INTO_RING_SOCKET") Thanks for the answer i’l check later.I hope will work . Link to comment Share on other sites More sharing options...
Recommended Posts
Please sign in to comment
You will be able to leave a comment after signing in
Sign In Now