added some kbm stuff

This commit is contained in:
qloak committed 2026-09-13 18:02:29 -07:00
1 parent 82e802873f
commit 42fd7414e4
218 files changed
+3758 -258

No files matched your search

@@ -5,6 +5,7 @@
UIControl_SlotList::UIControl_SlotList()
{
m_lastHighlighted = -1;
m_iSlotSize = 0;
}
bool UIControl_SlotList::setupControl(UIScene *scene, IggyValuePath *parent, const string &controlName)
@@ -16,8 +17,10 @@ bool UIControl_SlotList::setupControl(UIScene *scene, IggyValuePath *parent, con
m_addSlotFunc = registerFastName(L"addSlot");
m_setRedBoxFunc = registerFastName(L"SetSlotRedBox");
m_setHighlightFunc = registerFastName(L"SetSlotHighlight");
m_slotSizeFunc = registerFastName(L"m_iSlotSize");
m_lastHighlighted = 0;
m_iSlotSize = 0;
return success;
}
@@ -27,6 +30,32 @@ void UIControl_SlotList::ReInit()
UIControl_Base::ReInit();
m_lastHighlighted = -1;
m_iSlotSize = 0;
}
S32 UIControl_SlotList::GetSlotSize()
{
if (m_iSlotSize <= 0)
{
S32 iSlotSize = 0;
IggyValueGetS32RS(getIggyValuePath(), m_slotSizeFunc, NULL, &iSlotSize);
m_iSlotSize = iSlotSize;
if (m_iSlotSize <= 0)
{
m_iSlotSize = 50;
}
}
return m_iSlotSize;
}
S32 UIControl_SlotList::GetFlashSlotCount()
{
S32 iCount = -1;
IggyName slotsName = registerFastName(L"m_aSlots");
IggyValueGetArrayLengthRS(getIggyValuePath(), slotsName, NULL, &iCount);
return iCount;
}
void UIControl_SlotList::addSlot(int id)
@@ -65,6 +94,15 @@ void UIControl_SlotList::setHighlightSlot(int index)
}
}
void UIControl_SlotList::clearHighlight()
{
if(m_lastHighlighted != -1)
{
setSlotHighlighted(m_lastHighlighted, false);
m_lastHighlighted = -1;
}
}
void UIControl_SlotList::setSlotHighlighted(int index, bool highlight)
{
IggyDataValue result;