diff --git a/README.md b/README.md index 06dcefaf..fc203550 100644 --- a/README.md +++ b/README.md @@ -2,28 +2,9 @@ This repository contains all client-side data, including locale files, configurations, and descriptive text used by the game client. -## Changelog 📋 - -### 🐛 Bug Fixes -* **Skill 19:** Applied the correct `MOV_SPEED` value fix for Skill 19 across all locales. -* **Messenger - UI:** Fixed a critical UI issue where the name of a recently removed friend would sometimes appear on top of the next name in the list, or the "Empty" string, if it was selected during the removal process. +## 📋 Changelog ### ⬆️ Feature Improvements -* **Messenger System:** - * **Live Status Updates:** Live updates for adding/removing friend for both parties. - * **Auto-Deselect:** When a player removes a friend, or is removed by one, the entry is automatically deselected in the Messenger window. - * **Early Initialization:** The Messenger window is now automatically initialized (without visually opening the window) upon starting the game phase, allowing it to receive real-time updates from the very beginning. - * **Request Handling:** Pressing the `Escape` key while the request dialog is open now denies the request normally. - * **Button State:** The Whisper and Delete buttons are automatically disabled when removing/getting removed by a friend with the Messenger window open. - * **Target board:** The "Friend" button dynamically updates upon adding/removing a friend for both parties, if target is focused. -* **Inventory Management:** Inventory calculations are now correctly designed to handle togglable item activation effects across any number of inventory pages by calculating `page total slots * total pages`. -* **Skill Cooldowns and States:** A massive update to ensure reliability across various scenarios: - * **Window/Taskbar Persistence:** Cooldowns and active slot effects are now correctly maintained and updated in the Character Window and Taskbar during actions such as: repositioning skills, leveling up, changing skill grades (including Perfect), mounting/unmounting, changing Character Window pages, switching Skill View tabs, closing/reopening the window, and relogging. Supports togglable, non-togglable, and togglable-with-cooldown skills. - * **Level Reset Clearing:** Skill cooldowns and active slot states are properly cleared when the skill level is reset to 0. - * **Support togglables:** Combo automatically deactivates if its level is changed to 0 (e.g., via `/setsk`). - * **Horse Skill Cooldowns:** Horse skill cooldowns are cleared if their level is changed to 0. - * **Horse Skill View Logic:** The Horse skills page now correctly appears when the riding skill (Skill 130) reaches **level 21+** (not 20+). - * **Taskbar Sync:** Horse skills are automatically removed from the Taskbar, and the Skill View switches pages automatically, if the riding skill level drops below 21 (e.g., via `/setsk`). - * **Skill group 0 support for Horse page:** The Horse skill page is now visible even if there are no skills assigned to that group, provided the riding skill level is high enough. - * **Support skill levels:** Support and Horse skill states are correctly maintained when the character's skill group is reset. -* **.gitignore file:** Ignoring all files and directories ending in `_BAK` or `.BAK` (case-insensitive) +* **Quickslot Definitions:** The maximum number of quickslot slots is now explicitly defined for python scripts to improve consistency. +* **Alchemy Deck Toggling:** Alchemy decks can now be toggled via hotkeys: CTRL+C for the first deck and CTRL+D for the second. Activating one deck will automatically disable the other (if active). +* **Taskbar Item Swapping:** Improved taskbar logic: dragging an item to a non-empty slot now swaps positions with the existing item if it already exists on the taskbar, rather than replacing it. diff --git a/assets/locale_en/locale/en/locale_game.txt b/assets/locale_en/locale/en/locale_game.txt index 404ee5a5..57ed6cc4 100644 --- a/assets/locale_en/locale/en/locale_game.txt +++ b/assets/locale_en/locale/en/locale_game.txt @@ -330,9 +330,9 @@ PARTY_BREAK_UP Delete Group PARTY_DO_YOU_ACCEPT would like to join the Group. PARTY_DO_YOU_JOIN has invited you to join his group. Accept? PARTY_EXP_DISTRIBUTION_MODE EXP Distribution -PARTY_EXP_DISTRIBUTION_MODE_LEVEL Level dependant +PARTY_EXP_DISTRIBUTION_MODE_LEVEL Level-dependent PARTY_EXP_DISTRIBUTION_MODE_LEVEL_TOOLTIP Higher level group members receive more EXP. -PARTY_EXP_DISTRIBUTION_MODE_PARITY even +PARTY_EXP_DISTRIBUTION_MODE_PARITY Even PARTY_EXP_DISTRIBUTION_MODE_PARITY_TOOLTIP All Group members receive the same EXP. PARTY_HEAL_ALL_MEMBER Restore everything. PARTY_INCREASE_AREA_150 Range of the group heightened of the factor 1.5 . SNA @@ -529,7 +529,7 @@ STAT_TOOLTIP_INT Increases SP, magic attack and defence STAT_TOOLTIP_STR Increases attack value and damage SYMBOLLIST_TITLE Register Guild flag SYSTEM_OPTION_CPU_TILING_1 CPU Tiling Mode can upgrade the speed of a weaker PC. -SYSTEM_OPTION_CPU_TILING_2 If there are problem with the graphics choose either ,Systemoption or ,CONFIG.exe +SYSTEM_OPTION_CPU_TILING_2 If there are problem with the graphics choose either ,Systemoption or ,CONFIG.exe SYSTEM_OPTION_CPU_TILING_3 and change to GPU Tiling Mode. SYSTEM_OPTION_GPU_TILING_1 GPU Tiling Mode can run slow on a weaker PC. SYSTEM_OPTION_GPU_TILING_2 If there are problems with the graphics choose either 'System Options' or 'CONFIG.exe' diff --git a/assets/root/constinfo.py b/assets/root/constinfo.py index 187fb7d7..d18988d8 100644 --- a/assets/root/constinfo.py +++ b/assets/root/constinfo.py @@ -54,6 +54,10 @@ LOGIN_COUNT_LIMIT_ENABLE = 0 PVPMODE_PROTECTED_LEVEL = 15 TWO_HANDED_WEAPON_ATT_SPEED_DECREASE_VALUE = 10 +# MR-3: Define max quickslot slots number for scripts +QUICKSLOT_MAX_NUM = 36 +# MR-3: -- END OF -- Define max quickslot slots number for scripts + isItemQuestionDialog = 0 def GET_ITEM_QUESTION_DIALOG_STATUS(): @@ -202,36 +206,36 @@ def GET_ACCESSORY_MATERIAL_VNUM(vnum, subType): return ACCESSORY_MATERIAL_LIST[type] ################################################################## -## ߰ 'Ʈ' Ÿ԰, Ʈ Ͽ .. -## Ʈ Ͻý Ǽ ϱ , Ǽ ϵڵó ̷ ۿ .. +## ���� �߰��� '��Ʈ' ������ Ÿ�԰�, ��Ʈ�� ���Ͽ� ���� ������ ����.. +## ��Ʈ�� ���Ͻý����� �Ǽ������� �����ϱ� ������, �� �Ǽ����� ���� �ϵ��ڵ�ó�� �̷������� �� ���ۿ� ����.. def GET_BELT_MATERIAL_VNUM(vnum, subType = 0): - # Ʈ ϳ (#18900) + # ����� ��� ��Ʈ���� �ϳ��� ������(#18900)�� ���� ���� return 18900 ################################################################## -## ڵ (HP: #72723 ~ #72726, SP: #72727 ~ #72730) +## �ڵ����� (HP: #72723 ~ #72726, SP: #72727 ~ #72730) -# ش vnum ڵΰ? +# �ش� vnum�� �ڵ������ΰ�? def IS_AUTO_POTION(itemVnum): return IS_AUTO_POTION_HP(itemVnum) or IS_AUTO_POTION_SP(itemVnum) -# ش vnum HP ڵΰ? +# �ش� vnum�� HP �ڵ������ΰ�? def IS_AUTO_POTION_HP(itemVnum): if 72723 <= itemVnum and 72726 >= itemVnum: return 1 - elif itemVnum >= 76021 and itemVnum <= 76022: ##  ȭ ູ + elif itemVnum >= 76021 and itemVnum <= 76022: ## ���� �� ������ ȭ���� �ູ return 1 elif itemVnum == 79012: return 1 return 0 -# ش vnum SP ڵΰ? +# �ش� vnum�� SP �ڵ������ΰ�? def IS_AUTO_POTION_SP(itemVnum): if 72727 <= itemVnum and 72730 >= itemVnum: return 1 - elif itemVnum >= 76004 and itemVnum <= 76005: ##  ູ + elif itemVnum >= 76004 and itemVnum <= 76005: ## ���� �� ������ ������ �ູ return 1 elif itemVnum == 79013: return 1 diff --git a/assets/root/game.py b/assets/root/game.py index 895f6ae3..795275b0 100644 --- a/assets/root/game.py +++ b/assets/root/game.py @@ -345,7 +345,12 @@ class GameWindow(ui.ScriptWindow): onPressKeyDict[app.DIK_W] = lambda : self.MoveUp() onPressKeyDict[app.DIK_S] = lambda : self.MoveDown() onPressKeyDict[app.DIK_A] = lambda : self.MoveLeft() - onPressKeyDict[app.DIK_D] = lambda : self.MoveRight() + # MR-3: Keyboard-enabled deck toggling + onPressKeyDict[app.DIK_D] = lambda : ( + self.MoveRight() if not (app.IsPressed(app.DIK_LCONTROL) or app.IsPressed(app.DIK_RCONTROL)) + else (self.interface.wndDragonSoul and self.interface.wndDragonSoul.ActivateButtonClick(1)) + ) + # MR-3: -- END OF -- Keyboard-enabled deck toggling onPressKeyDict[app.DIK_E] = lambda: app.RotateCamera(app.CAMERA_TO_POSITIVE) onPressKeyDict[app.DIK_R] = lambda: app.ZoomCamera(app.CAMERA_TO_NEGATIVE) @@ -363,7 +368,12 @@ class GameWindow(ui.ScriptWindow): onPressKeyDict[app.DIK_NUMPAD2] = lambda: app.MoviePitchCamera(app.CAMERA_TO_POSITIVE) onPressKeyDict[app.DIK_GRAVE] = lambda : self.PickUpItem() onPressKeyDict[app.DIK_Z] = lambda : self.PickUpItem() - onPressKeyDict[app.DIK_C] = lambda state = "STATUS": self.interface.ToggleCharacterWindow(state) + # MR-3: Keyboard-enabled deck toggling + onPressKeyDict[app.DIK_C] = lambda state = "STATUS": ( + self.interface.ToggleCharacterWindow(state) if not (app.IsPressed(app.DIK_LCONTROL) or app.IsPressed(app.DIK_RCONTROL)) + else (self.interface.wndDragonSoul and self.interface.wndDragonSoul.ActivateButtonClick(0)) + ) + # MR-3: -- END OF -- Keyboard-enabled deck toggling onPressKeyDict[app.DIK_V] = lambda state = "SKILL": self.interface.ToggleCharacterWindow(state) #onPressKeyDict[app.DIK_B] = lambda state = "EMOTICON": self.interface.ToggleCharacterWindow(state) onPressKeyDict[app.DIK_N] = lambda state = "QUEST": self.interface.ToggleCharacterWindow(state) diff --git a/assets/root/uicharacter.py b/assets/root/uicharacter.py index ade64a50..94c83fd6 100644 --- a/assets/root/uicharacter.py +++ b/assets/root/uicharacter.py @@ -1255,7 +1255,6 @@ class CharacterWindow(ui.ScriptWindow): if self.__CanUseHorseSkill(): self.activeSkillGroupName.Hide() self.skillGroupButton1.SetText(nameList.get(group, "Noname")) - self.skillGroupButton3.SetText(localeInfo.SKILL_GROUP_HORSE) self.skillGroupButton1.Show() self.skillGroupButton2.Hide() diff --git a/assets/root/uidragonsoul.py b/assets/root/uidragonsoul.py index c90668d4..47b68477 100644 --- a/assets/root/uidragonsoul.py +++ b/assets/root/uidragonsoul.py @@ -20,11 +20,11 @@ import uiInventory import sys ITEM_FLAG_APPLICABLE = 1 << 14 -# ȥ Vnum comment -# ITEM VNUM 10 ڸ, FEDCBA Ѵٸ -# FE : ȥ . D : -# C : ܰ B : ȭ -# A : ȣ... +# ��ȥ�� Vnum�� ���� comment +# ITEM VNUM�� 10�� �ڸ�����, FEDCBA��� �Ѵٸ� +# FE : ��ȥ�� ����. D : ��� +# C : �ܰ� B : ��ȭ +# A : ������ ��ȣ��... class DragonSoulWindow(ui.ScriptWindow): KIND_TAP_TITLES = [uiScriptLocale.DRAGONSOUL_TAP_TITLE_1, uiScriptLocale.DRAGONSOUL_TAP_TITLE_2, @@ -226,9 +226,9 @@ class DragonSoulWindow(ui.ScriptWindow): for j in xrange(item.LIMIT_MAX_NUM): (limitType, limitValue) = item.GetLimit(j) - # ؿ remain_time 0 üũ ϱ ʱȭ + # �ؿ��� remain_time�� 0�������� üũ �ϱ� ������ ������ ����� �ʱ�ȭ remain_time = 999 - # ϴ Ÿ̸Ӵ ̴. + # �ϴ� ���� Ÿ�̸Ӵ� �� ���� ���̴�. if item.LIMIT_REAL_TIME == limitType: remain_time = player.GetItemMetinSocket(player.INVENTORY, slotNumber, 0) - app.GetGlobalTimeStamp() elif item.LIMIT_REAL_TIME_START_FIRST_USE == limitType: @@ -275,7 +275,7 @@ class DragonSoulWindow(ui.ScriptWindow): for j in xrange(item.LIMIT_MAX_NUM): (limitType, limitValue) = item.GetLimit(j) - # ؿ remain_time üũ ϱ ʱȭ + # �ؿ��� remain_time�� �������� üũ �ϱ� ������ ������ ����� �ʱ�ȭ remain_time = 999 if item.LIMIT_REAL_TIME == limitType: remain_time = player.GetItemMetinSocket(player.DRAGON_SOUL_INVENTORY, slotNumber, 0) @@ -306,7 +306,7 @@ class DragonSoulWindow(ui.ScriptWindow): if None != self.tooltipItem: self.tooltipItem.SetTop() - # item slot Լ + # item slot ���� �Լ� def OverOutItem(self): self.wndItem.SetUsableItem(False) if None != self.tooltipItem: @@ -359,7 +359,7 @@ class DragonSoulWindow(ui.ScriptWindow): mouseModule.mouseController.DeattachObject() else: - ## ȵ ߰ + ## �������� �ȵ��� �߰� ## 20140220 curCursorNum = app.GetCursor() @@ -377,8 +377,8 @@ class DragonSoulWindow(ui.ScriptWindow): self.wndItem.SetUseMode(False) snd.PlaySound("sound/ui/pick.wav") - ## ȱ - ## 2014.02.20 ߰ + ## ������ �ȱ� + ## 2014.02.20 �߰� def __SellItem(self, itemSlotPos): if not player.IsDSEquipmentSlot(player.DRAGON_SOUL_INVENTORY, itemSlotPos): self.sellingSlotNumber = itemSlotPos @@ -412,21 +412,21 @@ class DragonSoulWindow(ui.ScriptWindow): self.questionDialog.Open() self.questionDialog.count = itemCount - ## ȱ + ## ������ �ȱ� def SellItem(self): net.SendShopSellPacketNew(self.sellingSlotNumber, self.questionDialog.count, player.DRAGON_SOUL_INVENTORY) snd.PlaySound("sound/ui/money.wav") self.OnCloseQuestionDialog() - ## ȱ + ## ������ �ȱ� def OnCloseQuestionDialog(self): if self.questionDialog: self.questionDialog.Close() self.questionDialog = None - ## ȱ + ## ������ �ȱ� def __OnClosePopupDialog(self): self.pop = None @@ -478,7 +478,7 @@ class DragonSoulWindow(ui.ScriptWindow): return slotIndex = self.__InventoryLocalSlotPosToGlobalSlotPos(player.DRAGON_SOUL_INVENTORY, slotIndex) try: - # ȥ ȭâ , Ŭ ڵ ȭâ . + # ��ȥ�� ��ȭâ�� ����������, ������ ��Ŭ�� �� �ڵ����� ��ȭâ���� ��. if self.wndDragonSoulRefine.IsShow(): if uiPrivateShopBuilder.IsBuildingPrivateShop(): chat.AppendChat(chat.CHAT_TYPE_INFO, localeInfo.MOVE_ITEM_FAILURE_PRIVATE_SHOP) @@ -500,7 +500,7 @@ class DragonSoulWindow(ui.ScriptWindow): net.SendItemMovePacket(srcSlotWindow , srcSlotPos, dstSlotWindow, dstSlotPos, srcItemCount) - # equip Լ. + # equip ���� ���� �Լ���. def OverOutEquipItem(self): self.OverOutItem() @@ -529,7 +529,7 @@ class DragonSoulWindow(ui.ScriptWindow): def SelectEquipItemSlot(self, itemSlotIndex): - ## 콺 ư sell buy üũ ؼ return + ## ���콺 ��ư�� sell buy üũ �ؼ� return curCursorNum = app.GetCursor() if app.SELL == curCursorNum: return @@ -545,7 +545,7 @@ class DragonSoulWindow(ui.ScriptWindow): if mouseModule.mouseController.isAttached(): attachedSlotType = mouseModule.mouseController.GetAttachedType() attachedSlotPos = mouseModule.mouseController.GetAttachedSlotNumber() - # ڱ ڽ ڱ ڽſ 巡ϴ + # �ڱ� �ڽ��� �ڱ� �ڽſ��� �巡���ϴ� ��� if player.SLOT_TYPE_INVENTORY == attachedSlotType and itemSlotIndex == attachedSlotPos: return @@ -592,9 +592,9 @@ class DragonSoulWindow(ui.ScriptWindow): self.__OpenQuestionDialog(True, srcItemPos, dstItemPos) mouseModule.mouseController.DeattachObject() - # equip Լ . + # equip ���� ���� �Լ��� ��. - # â + # ���â ���� def __OpenQuestionDialog(self, Equip, srcItemPos, dstItemPos): self.srcItemPos = srcItemPos self.dstItemPos = dstItemPos @@ -623,7 +623,7 @@ class DragonSoulWindow(ui.ScriptWindow): self.dstItemPos = (0, 0) self.dlgQuestion.Close() - # â + # ���â ���� �� def SetDSKindIndex(self, kindIndex): if self.DSKindIndex != kindIndex: @@ -656,7 +656,7 @@ class DragonSoulWindow(ui.ScriptWindow): self.RefreshEquipSlotWindow() - # ȥ Ȱȭ + # ��ȥ�� Ȱ��ȭ ���� def ActivateDragonSoulByExtern(self, deck): self.isActivated = True self.activateButton.Down() @@ -669,16 +669,25 @@ class DragonSoulWindow(ui.ScriptWindow): self.isActivated = False self.activateButton.SetUp() - def ActivateButtonClick(self): - self.isActivated = self.isActivated ^ True - if self.isActivated: + # MR-3: Keyboard-enabled deck toggling + def ActivateButtonClick(self, deckIndex = None): + # If deckIndex is not specified, use the current deckPageIndex + if deckIndex is None: + deckIndex = self.deckPageIndex + + if not self.isActivated or self.deckPageIndex != deckIndex: if self.__CanActivateDeck(): - net.SendChatPacket("/dragon_soul activate " + str(self.deckPageIndex)) + net.SendChatPacket("/dragon_soul activate " + str(deckIndex)) + self.isActivated = True + self.activateButton.Down() else: self.isActivated = False self.activateButton.SetUp() else: net.SendChatPacket("/dragon_soul deactivate") + self.isActivated = False + self.activateButton.SetUp() + # MR-3: -- END OF -- Keyboard-enabled deck toggling def __CanActivateDeck(self): canActiveNum = 0 @@ -692,24 +701,24 @@ class DragonSoulWindow(ui.ScriptWindow): for i in xrange(item.LIMIT_MAX_NUM): (limitType, limitValue) = item.GetLimit(i) - # LIMIT_TIMER_BASED_ON_WEAR 0 ð ڴ´. - # LIMIT_REAL_TIME ð Ǹ Ƿ ʿ䰡 . - # LIMIT_REAL_TIME_START_FIRST_USE ǵ ʾ ϴ д. + # LIMIT_TIMER_BASED_ON_WEAR�� ����0�� ���� �ð��� �ڴ´�. + # LIMIT_REAL_TIME�� �ð� �� �Ǹ� �������� ������Ƿ� �� �ʿ䰡 ����. + # LIMIT_REAL_TIME_START_FIRST_USE�� ������ ����� ���ǵ��� �ʾ� �ϴ� ���д�. if item.LIMIT_TIMER_BASED_ON_WEAR == limitType: isNoLimit = False remain_time = player.GetItemMetinSocket(player.INVENTORY, slotNumber, 0) if 0 != remain_time: canActiveNum += 1 break - # Ÿ̸Ӱ ٸ Activate ִ ȥ. + # Ÿ�̸Ӱ� ���ٸ� Activate�� �� �ִ� ��ȥ��. if isNoLimit: canActiveNum += 1 return canActiveNum > 0 - # Ȱȭ + # Ȱ��ȭ ���� �� - # highlight + # ���� highlight ���� def __HighlightSlot_ClearCurrentPage(self): for i in xrange(self.wndItem.GetSlotCount()): slotNumber = self.__InventoryLocalSlotPosToGlobalSlotPos(player.DRAGON_SOUL_INVENTORY, i) @@ -726,14 +735,14 @@ class DragonSoulWindow(ui.ScriptWindow): def HighlightSlot(self, slot): if not slot in self.listHighlightedSlot: self.listHighlightedSlot.append (slot) - # highlight + # ���� highlight ���� �� def SetDragonSoulRefineWindow(self, wndDragonSoulRefine): if app.ENABLE_DRAGON_SOUL_SYSTEM: from _weakref import proxy self.wndDragonSoulRefine = proxy(wndDragonSoulRefine) -## ȭ +## ��ȭ�� �� ���� ��� ������ ���� #class DragonSoulRefineException(Exception): #pass @@ -870,7 +879,7 @@ class DragonSoulRefineWindow(ui.ScriptWindow): def SetItemToolTip(self, tooltipItem): self.tooltipItem = tooltipItem - # ư ִ ¸ ȭâ ʱȭ. + # ��ư ���� �ִ� ���¸� ������ ��� ��ȭâ ���� �������� �ʱ�ȭ. def __Initialize(self): self.currentRecipe = {} self.refineItemInfo = {} @@ -888,7 +897,7 @@ class DragonSoulRefineWindow(ui.ScriptWindow): def __FlushRefineItemSlot(self): ## Item slot settings - # κ īƮ ȸ + # ���� �κ��� ������ ī��Ʈ ȸ�� for invenType, invenPos, itemCount in self.refineItemInfo.values(): remainCount = player.GetItemCount(invenType, invenPos) player.SetItemCount(invenType, invenPos, remainCount + itemCount) @@ -939,33 +948,33 @@ class DragonSoulRefineWindow(ui.ScriptWindow): raise Exception, ("Invalid attachedItemCount(%d). (base pos (%d, %d), base itemCount(%d))" % (itemCount, invenType, invenPos, maxCount)) #return False - # strength ȭ , 0 ȭ, 1 ȥ . + # strength ��ȭ�� ���, 0���� ��ȭ��, 1���� ��ȥ���� ������ ������. if DragonSoulRefineWindow.REFINE_TYPE_STRENGTH == self.currentRefineType: if self.__IsDragonSoul(itemVnum): dstSlotIndex = 1 else: dstSlotIndex = 0 - # ̾. + # �� �����̾����. if dstSlotIndex in self.refineItemInfo: return False - # ȭâ ø ִ ˻. + # ��ȭâ�� �ø� �� �ִ� ���������� �˻�. if False == self.__CheckCanRefine(itemVnum): return False - # īƮŭ ڸ īƮ + # ����� ���� ������ ī��Ʈ��ŭ ���� �ڸ��� ������ ī��Ʈ ���� player.SetItemCount(invenType, invenPos, maxCount - itemCount) self.refineItemInfo[dstSlotIndex] = (invenType, invenPos, itemCount) self.Refresh() return True - # ȭ üũ - # ȥ ȭ ȭ Ǹ س ϴ ƴ϶, - # ó ȭâ ø ȥ ȭ ǰ ȴ. - # ׷ __CanRefineGrade, __CanRefineStep, __CanRefineStrength Լ - # ȭ ǰ ٸ(ó ø ̶), ȭ Ǹ ִ ҵ Ѵ. + # ��ȭ ������ ���������� üũ + # ��ȥ�� ��ȭ�� ��ȭ �����Ǹ� ���س��� �����ϴ� ���� �ƴ϶�, + # ó���� ��ȭâ�� �ø� ��ȥ���� ���� ��ȭ �����ǰ� �����ȴ�. + # �׷��� __CanRefineGrade, __CanRefineStep, __CanRefineStrength �Լ����� + # ��ȭ �����ǰ� ���ٸ�(ó�� �ø��� �������̶��), ��ȭ �����Ǹ� �������ִ� ���ҵ� �Ѵ�. def __CheckCanRefine(self, vnum): if self.REFINE_TYPE_GRADE == self.currentRefineType: return self.__CanRefineGrade(vnum) @@ -992,10 +1001,10 @@ class DragonSoulRefineWindow(ui.ScriptWindow): if not (cur_refine_ds_type == ds_type and cur_refine_grade == grade): self.__PopUp(localeInfo.DRAGON_SOUL_INVALID_DRAGON_SOUL) return False - # ȭ â ó ø , ȭ ῡ . - # ȥ ȭ, Ǹ ϴ ƴ϶, ȭâ ó ø ̳Ŀ , - # ȭϰ, ᰡ ( ) . - # ǰ ٸ, ó ø ̶ ϰ, vnum Ǹ . + # ��ȭ â�� ó�� �������� �ø��� ���, ��ȭ ��ῡ ���� ������ ����. + # ��ȥ�� ��ȭ��, �����Ǹ� ������ �����ϴ� ���� �ƴ϶�, ��ȭâ�� ó�� �ø��� �������� �����̳Ŀ� ����, + # ������ ��ȭ�ϰ�, ��ᰡ ��������(���� ������)�� ��������. + # �����ǰ� ���ٸ�, ó�� �ø� �������̶� �����ϰ�, vnum�� �������� �����Ǹ� ����. else: self.currentRecipe = self.__GetRefineGradeRecipe(vnum) @@ -1004,7 +1013,7 @@ class DragonSoulRefineWindow(ui.ScriptWindow): self.wndMoney.SetText(localeInfo.NumberToMoneyString(self.currentRecipe["fee"])) return True else: - # ȭ ÿ ϸ ø Ǵ. + # ��ȭ ���� ���ÿ� �����ϸ� �ø� �� ���� ���������� �Ǵ�. self.__PopUp(localeInfo.DRAGON_SOUL_CANNOT_REFINE) return False @@ -1021,10 +1030,10 @@ class DragonSoulRefineWindow(ui.ScriptWindow): if not (cur_refine_ds_type == ds_type and cur_refine_grade == grade and cur_refine_step == step): self.__PopUp(localeInfo.DRAGON_SOUL_INVALID_DRAGON_SOUL) return False - # ȭ â ó ø , ῡ . - # ȥ ȭ, Ǹ ϴ ƴ϶, ȭâ ó ø ̳Ŀ , - # ȭϰ, ᰡ ( ) . - # ǰ ٸ, ó ø ̶ ϰ, vnum Ǹ . + # ��ȭ â�� ó�� �������� �ø��� ���, ��ῡ ���� ������ ����. + # ��ȥ�� ��ȭ��, �����Ǹ� ������ �����ϴ� ���� �ƴ϶�, ��ȭâ�� ó�� �ø��� �������� �����̳Ŀ� ����, + # ������ ��ȭ�ϰ�, ��ᰡ ��������(���� ������)�� ��������. + # �����ǰ� ���ٸ�, ó�� �ø� �������̶� �����ϰ�, vnum�� �������� �����Ǹ� ����. else: self.currentRecipe = self.__GetRefineStepRecipe(vnum) @@ -1034,12 +1043,12 @@ class DragonSoulRefineWindow(ui.ScriptWindow): return True else: - # ȭ ÿ ϸ ø Ǵ. + # ��ȭ ���� ���ÿ� �����ϸ� �ø� �� ���� ���������� �Ǵ�. self.__PopUp(localeInfo.DRAGON_SOUL_CANNOT_REFINE) return False def __CanRefineStrength (self, vnum): - # ȥ , ̻ strength ȭ üũؾ. + # ��ȥ���� ���, �� �̻� strength ��ȭ�� �� �� ������ üũ�ؾ���. if self.__IsDragonSoul(vnum): ds_type, grade, step, strength = self.__GetDragonSoulTypeInfo(vnum) @@ -1051,10 +1060,10 @@ class DragonSoulRefineWindow(ui.ScriptWindow): else: return True - # strength ȭ , refine_recipe ȥ ƴ, ȭ ޶. - # ȥ ƴ϶, - # ̹ ǰ ִ , ȭ ȭâ ִٴ ̹Ƿ, return False - # ǰ , ȭ Ȯϰ, Ǹ Ѵ. + # strength ��ȭ�� ���, refine_recipe�� ��ȥ���� ������ �ƴ�, ��ȭ���� ������ ���� �޶�����. + # ���� ��ȥ���� �ƴ϶��, + # �̹� �����ǰ� �ִ� ����, ��ȭ���� ��ȭâ�� �ִٴ� ���̹Ƿ�, return False + # �����ǰ� ���� ����, ��ȭ������ Ȯ���ϰ�, �����Ǹ� �����Ѵ�. else: if self.currentRecipe: self.__PopUp(localeInfo.DRAGON_SOUL_IS_NOT_DRAGON_SOUL) @@ -1066,7 +1075,7 @@ class DragonSoulRefineWindow(ui.ScriptWindow): self.wndMoney.SetText(localeInfo.NumberToMoneyString(self.currentRecipe["fee"])) return True else: - # Ǹ + # �����Ǹ� ������ �� ���� ��� self.__PopUp(localeInfo.DRAGON_SOUL_NOT_DRAGON_SOUL_REFINE_STONE) return False @@ -1096,11 +1105,11 @@ class DragonSoulRefineWindow(ui.ScriptWindow): except: return None - # strength ȭ , refineInfo ȭ ޶. + # strength ��ȭ�� ���, refineInfo�� ��ȭ���� ���� �޶�����. def __GetRefineStrengthInfo (self, itemVnum): try: - # ̳ ġ .... - # ȭ ƴϸ ȵ. + # �̳��� ��ġ�� ��������.... + # ��ȭ���� �ƴϸ� �ȵ�. item.SelectItem(itemVnum) if not (item.ITEM_TYPE_MATERIAL == item.GetItemType() \ and (item.MATERIAL_DS_REFINE_NORMAL <= item.GetItemSubType() and item.GetItemSubType() <= item.MATERIAL_DS_REFINE_HOLLY)): @@ -1115,11 +1124,11 @@ class DragonSoulRefineWindow(ui.ScriptWindow): item.SelectItem(vnum) return item.GetItemType() == item.ITEM_TYPE_DS - # ȥ Vnum comment - # ITEM VNUM 10 ڸ, FEDCBA Ѵٸ - # FE : ȥ . D : - # C : ܰ B : ȭ - # A : ȣ... + # ��ȥ�� Vnum�� ���� comment + # ITEM VNUM�� 10�� �ڸ�����, FEDCBA��� �Ѵٸ� + # FE : ��ȥ�� ����. D : ��� + # C : �ܰ� B : ��ȭ + # A : ������ ��ȣ��... def __GetDragonSoulTypeInfo(self, vnum): if not self.__IsDragonSoul(vnum): return DragonSoulRefineWindow.INVALID_DRAGON_SOUL_INFO @@ -1133,7 +1142,7 @@ class DragonSoulRefineWindow(ui.ScriptWindow): def __MakeDragonSoulVnum(self, ds_type, grade, step, strength): return ds_type * 10000 + grade * 1000 + step * 100 + strength * 10 - ## Event + ## �� ���� ���� Event def __SelectRefineEmptySlot(self, selectedSlotPos): try: if constInfo.GET_ITEM_QUESTION_DIALOG_STATUS() == 1: @@ -1168,14 +1177,14 @@ class DragonSoulRefineWindow(ui.ScriptWindow): import dbg dbg.TraceError("Exception : __SelectRefineEmptySlot, %s" % e) - # Ŭ Կ . + # Ŭ������ ���Կ��� ����. def __SelectRefineItemSlot(self, selectedSlotPos): if constInfo.GET_ITEM_QUESTION_DIALOG_STATUS() == 1: return try: if not selectedSlotPos in self.refineItemInfo: - # ο ȭâ ø ۾. + # ���ο� �������� ��ȭâ�� �ø��� �۾�. if mouseModule.mouseController.isAttached(): attachedSlotType = mouseModule.mouseController.GetAttachedType() attachedSlotPos = mouseModule.mouseController.GetAttachedSlotNumber() @@ -1203,25 +1212,25 @@ class DragonSoulRefineWindow(ui.ScriptWindow): attachedInvenType, attachedSlotPos, attachedItemCount = self.refineItemInfo[selectedSlotPos] selectedItemVnum = player.GetItemIndex(attachedInvenType, attachedSlotPos) - # ȭâ κ īƮ ȸ + # ��ȭâ���� ���� �� ���� �κ��� ������ ī��Ʈ ȸ�� invenType, invenPos, itemCount = self.refineItemInfo[selectedSlotPos] remainCount = player.GetItemCount(invenType, invenPos) player.SetItemCount(invenType, invenPos, remainCount + itemCount) del self.refineItemInfo[selectedSlotPos] - # ȭâ ٸ, ʱȭ + # ��ȭâ�� ����ٸ�, �ʱ�ȭ if not self.refineItemInfo: self.__Initialize() else: item.SelectItem(selectedItemVnum) - # ȭ̾ٸ ȭ ǽ ʱȭ + # ���� �������� ��ȭ���̾��ٸ� ��ȭ ���ǽ� �ʱ�ȭ if (item.ITEM_TYPE_MATERIAL == item.GetItemType() \ and (item.MATERIAL_DS_REFINE_NORMAL <= item.GetItemSubType() and item.GetItemSubType() <= item.MATERIAL_DS_REFINE_HOLLY)): self.currentRecipe = {} self.wndMoney.SetText(localeInfo.NumberToMoneyString(0)) - # ȥ̾ٸ, - # strengthȭ ƴ , ȭâ ٸ ȥ Ƿ, Ǹ ʱȭϸ ȵ. - # strengthȭ , ȭ Ǵ ȭ ӵ ̹Ƿ ٸ ó ʿ䰡 . + # ��ȥ���̾��ٸ�, + # strength��ȭ�� �ƴ� ���, ��ȭâ�� �ٸ� ��ȥ���� ���������Ƿ�, �����Ǹ� �ʱ�ȭ�ϸ� �ȵ�. + # strength��ȭ�� ���, ��ȭ �����Ǵ� ��ȭ���� ���ӵ� ���̹Ƿ� �ٸ� ó���� �ʿ䰡 ����. else: pass @@ -1268,10 +1277,10 @@ class DragonSoulRefineWindow(ui.ScriptWindow): for slotPos in xrange(self.wndRefineSlot.GetSlotCount()): self.wndRefineSlot.ClearSlot(slotPos) if slotPos < self.refineSlotLockStartIndex: - # self.refineItemInfo[slotPos] Ȯ - # ( ϴ Ȯ) - # -> Կ . - # -> Ƿ ȭâ . + # self.refineItemInfo[slotPos]�� ����Ȯ�� + # (������ �������� �����ϴ��� Ȯ��) + # ���� -> ������ �������� ���Կ� ����. + # ������ -> �������� �����Ƿ� ��ȭâ���� ����. if slotPos in self.refineItemInfo: invenType, invenPos, itemCount = self.refineItemInfo[slotPos] itemVnum = player.GetItemIndex(invenType, invenPos) @@ -1282,12 +1291,12 @@ class DragonSoulRefineWindow(ui.ScriptWindow): else: del self.refineItemInfo[slotPos] - # Կ reference alpha 0.5 . + # �� ���Կ� reference �������� alpha 0.5�� ����. if not slotPos in self.refineItemInfo: try: reference_vnum = 0 - # strength ȭ , - # 0 Կ ȭ, 1 Կ ȥ ´. + # strength ��ȭ�� ����, + # 0�� ���Կ� ��ȭ����, 1�� ���Կ� ��ȥ���� ���´�. if DragonSoulRefineWindow.REFINE_TYPE_STRENGTH == self.currentRefineType: if DragonSoulRefineWindow.REFINE_STONE_SLOT == slotPos: reference_vnum = 100300 @@ -1298,28 +1307,28 @@ class DragonSoulRefineWindow(ui.ScriptWindow): itemIcon = item.GetIconImage() (width, height) = item.GetItemSize() self.wndRefineSlot.SetSlot(slotPos, 0, width, height, itemIcon, (1.0, 1.0, 1.0, 0.5)) - # slot ϴܿ ߸ ... + # slot ���� �ϴܿ� ���� �߸� �� ����... self.wndRefineSlot.SetSlotCount(slotPos, 0) except: pass - # refineSlotLockStartIndex ̹ ָ ȵ. + # refineSlotLockStartIndex ���� ���� ������ ���� �̹����� �����ָ� �ȵ�. self.wndRefineSlot.HideSlotBaseImage(slotPos) # slotPos >= self.refineSlotLockStartIndex: else: - # if  , - # (ʿ ε refineSlotLockStartIndex ̻ Կ ϰ ߱ ) - # Ȥ . + # �������� ����� �� if���� �� ���� ��������, + # (���ʿ� �ε����� refineSlotLockStartIndex �̻��� ���Կ��� �������� ���� ���ϰ� �߱� ����) + # Ȥ�� �� ������ �����. if slotPos in self.refineItemInfo: invenType, invenPos, itemCount = self.refineItemInfo[slotPos] remainCount = player.GetItemCount(invenType, invenPos) player.SetItemCount(invenType, invenPos, remainCount + itemCount) del self.refineItemInfo[slotPos] - # refineSlotLockStartIndex ̻ ̹ . + # refineSlotLockStartIndex �̻��� ������ ���� �̹����� ���������. self.wndRefineSlot.ShowSlotBaseImage(slotPos) - # ȭâ ƹ ٸ, ʱȭ. - # ߰ ߰ "del self.refineItemInfo[slotPos]" ߱ , - # ⼭ ѹ üũ. + # ��ȭâ�� �ƹ��� �������� ���ٸ�, �ʱ�ȭ����. + # ������ �߰� �߰��� "del self.refineItemInfo[slotPos]"�� �߱� ������, + # ���⼭ �ѹ� üũ�������. if not self.refineItemInfo: self.__Initialize() @@ -1329,8 +1338,8 @@ class DragonSoulRefineWindow(ui.ScriptWindow): dbg.TraceError("Exception : __RefreshRefineItemSlot, %s" % e) def __GetEmptySlot(self, itemVnum = 0): - # STRENGTH ȭ , ȥ ԰ ȭ еǾֱ - # vnum ˾ƾ Ѵ. + # STRENGTH ��ȭ�� ���, ��ȥ�� ���԰� ��ȭ�� ������ ���еǾ��ֱ� ������ + # vnum�� �˾ƾ� �Ѵ�. if DragonSoulRefineWindow.REFINE_TYPE_STRENGTH == self.currentRefineType: if 0 == itemVnum: return -1 diff --git a/assets/root/uitaskbar.py b/assets/root/uitaskbar.py index 3c45bb5a..55806227 100644 --- a/assets/root/uitaskbar.py +++ b/assets/root/uitaskbar.py @@ -762,11 +762,10 @@ class TaskBar(ui.ScriptWindow): pass startNumber = 0 + for slot in self.quickslot: - for i in xrange(4): - - slotNumber = i+startNumber + slotNumber = i + startNumber (Type, Position) = player.GetLocalQuickSlot(slotNumber) @@ -775,12 +774,14 @@ class TaskBar(ui.ScriptWindow): continue if player.SLOT_TYPE_INVENTORY == Type: - itemIndex = player.GetItemIndex(Position) itemCount = player.GetItemCount(Position) + if itemCount <= 1: itemCount = 0 + slot.SetItemSlot(slotNumber, itemIndex, itemCount) + ## �ڵ����� (#72723, #72724) Ư��ó�� - �������ε��� ���Կ� Ȱ��ȭ/��Ȱ��ȭ ǥ�ø� ���� �۾��� - [hyo] if constInfo.IS_AUTO_POTION(itemIndex): # metinSocket - [0] : Ȱ��ȭ ����, [1] : ����� ��, [2] : �ִ� �뷮 @@ -790,8 +791,6 @@ class TaskBar(ui.ScriptWindow): slot.ActivateSlot(slotNumber) else: slot.DeactivateSlot(slotNumber) - - slot.SetItemSlot(slotNumber, itemIndex, itemCount) elif player.SLOT_TYPE_SKILL == Type: skillIndex = player.GetSkillIndex(Position) @@ -855,6 +854,19 @@ class TaskBar(ui.ScriptWindow): AttachedSlotNumber = mouseModule.mouseController.GetAttachedSlotNumber() AttachedItemIndex = mouseModule.mouseController.GetAttachedItemIndex() + # MR-3: Swap slots if dragging an item from another window already exists in quickslots and tries to replace another one + if AttachedSlotType != player.SLOT_TYPE_QUICK_SLOT: + # Search for the same item/skill/emotion in quickslots + for slotIdx in range(constInfo.QUICKSLOT_MAX_NUM): # Use your actual max quickslot count + (Type, Position) = player.GetLocalQuickSlot(slotIdx) + if Type == AttachedSlotType and Position == AttachedSlotNumber: + # Found, swap instead of replace + player.RequestMoveGlobalQuickSlotToLocalQuickSlot(slotIdx, localSlotIndex) + mouseModule.mouseController.DeattachObject() + self.RefreshQuickSlot() + return + # MR-3: -- END OF -- Swap slots if dragging an item from another window already exists in quickslots and tries to replace another one + if player.SLOT_TYPE_QUICK_SLOT == AttachedSlotType: player.RequestMoveGlobalQuickSlotToLocalQuickSlot(AttachedSlotNumber, localSlotIndex)