Files
BluTac10-Xbox_Neo/Minecraft.Client/Common/UI/UIControl_EnchantmentButton.h
SevenToaster509 490ac0eed1 Feat: Updated Enchanting Mechanics
Updated in the ARC:
EnchantingMenu1080
SkinHDGraphicsInGame
SkinHDInGame

may have override other changes in the arc but it dont think so...
2026-04-10 13:18:42 +01:00

59 lines
1020 B
C++

#pragma once
#include "UIControl_Button.h"
class UIControl_EnchantmentButton : public UIControl_Button
{
private:
// Maps to values in AS
enum EState
{
eState_Inactive = 0,
eState_Active = 1,
eState_Selected = 2,
};
EState m_lastState;
int m_lastCost;
int m_index;
wstring m_enchantmentString;
bool m_bHasFocus;
IggyName m_funcChangeState;
IggyName m_CLevel;
IggyName m_CLevelU;
unsigned int m_textColour, m_textFocusColour, m_textDisabledColour;
class EnchantmentNames
{
public:
static EnchantmentNames instance;
private:
Random random;
vector<wstring> words;
EnchantmentNames();
public:
wstring getRandomName();
};
public:
UIControl_EnchantmentButton();
int m_BValue = 1;
virtual bool setupControl(UIScene *scene, IggyValuePath *parent, const string &controlName);
virtual void tick();
void init(int index);
void setLevel();
virtual void ReInit();
void render(IggyCustomDrawCallbackRegion *region);
void updateState();
virtual void setFocus(bool focus);
};