diff --git a/RootDesk/MyDesk/SlayDeckController.codeblock b/RootDesk/MyDesk/SlayDeckController.codeblock index 5f11163..7d9b3c1 100644 --- a/RootDesk/MyDesk/SlayDeckController.codeblock +++ b/RootDesk/MyDesk/SlayDeckController.codeblock @@ -4524,7 +4524,7 @@ "Name": "slot" } ], - "Code": "if self.DragSlot ~= nil and self.DragSlot > 0 then\n\treturn\nend\nlocal cardId = self.Hand[slot]\nif cardId == nil then\n\treturn\nend\nlocal e = _EntityService:GetEntityByPath(\"/ui/RunUIGroup/CardHand/Card\" .. tostring(slot))\nlocal tx = 0\nif e ~= nil and e.UITransformComponent ~= nil then\n\ttx = e.UITransformComponent.anchoredPosition.x\n\te.UITransformComponent.UIScale = Vector3(1.3, 1.3, 1)\nend\nlocal c = self.Cards[cardId]\nif c ~= nil then\n\tlocal tip = self:BuildCardKeywordTooltip(c)\n\tif tip ~= \"\" then\n\t\tlocal tipX = tx + 270\n\t\tif tx > 180 then tipX = tx - 270 end\n\t\tif tipX > 760 then tipX = tx - 270 end\n\t\tif tipX < -760 then tipX = tx + 270 end\n\t\tself:ShowTooltipAt(\"키워드\", tip, tipX, 90)\n\telse\n\t\tself:HideTooltip()\n\tend\nend", + "Code": "if self.DragSlot ~= nil and self.DragSlot > 0 then\n\treturn\nend\nif self.Hand == nil then\n\treturn\nend\nlocal cardId = self.Hand[slot]\nif cardId == nil then\n\treturn\nend\nlocal e = _EntityService:GetEntityByPath(\"/ui/RunUIGroup/CardHand/Card\" .. tostring(slot))\nlocal tx = 0\nif e ~= nil and e.UITransformComponent ~= nil then\n\ttx = e.UITransformComponent.anchoredPosition.x\n\te.UITransformComponent.UIScale = Vector3(1.3, 1.3, 1)\nend\nlocal c = self.Cards[cardId]\nif c ~= nil then\n\tlocal tip = self:BuildCardKeywordTooltip(c)\n\tif tip ~= \"\" then\n\t\tlocal tipX = tx + 270\n\t\tif tx > 180 then tipX = tx - 270 end\n\t\tif tipX > 760 then tipX = tx - 270 end\n\t\tif tipX < -760 then tipX = tx + 270 end\n\t\tself:ShowTooltipAt(\"키워드\", tip, tipX, 90)\n\telse\n\t\tself:HideTooltip()\n\tend\nend", "Scope": 2, "ExecSpace": 6, "Attributes": [], diff --git a/tools/deck/cb/tooltip.mjs b/tools/deck/cb/tooltip.mjs index 92709c2..244e4b9 100644 --- a/tools/deck/cb/tooltip.mjs +++ b/tools/deck/cb/tooltip.mjs @@ -105,6 +105,9 @@ return out`, [{ Type: 'any', DefaultValue: null, SyncDirection: 0, Attributes: [ method('HoverCard', `if self.DragSlot ~= nil and self.DragSlot > 0 then return end +if self.Hand == nil then + return +end local cardId = self.Hand[slot] if cardId == nil then return