Various widget constructor stubs and factories

This commit is contained in:
Jack Andersen 2016-03-11 18:58:56 -10:00
parent b952b80e22
commit d81c9698ff
27 changed files with 512 additions and 74 deletions

View File

@ -192,10 +192,10 @@ void FRME::Widget::TXPNInfo::read(athena::io::IStreamReader& __dna_reader)
unk1 = __dna_reader.readBool();
/* unk2 */
unk2 = __dna_reader.readBool();
/* unk3 */
unk3 = __dna_reader.readUint32Big();
/* unk4 */
unk4 = __dna_reader.readUint32Big();
/* justification */
justification = Justification(__dna_reader.readUint32Big());
/* verticalJustification */
verticalJustification = VerticalJustification(__dna_reader.readUint32Big());
/* fillColor */
fillColor = __dna_reader.readVec4fBig();
/* outlineColor */
@ -232,10 +232,10 @@ void FRME::Widget::TXPNInfo::write(athena::io::IStreamWriter& __dna_writer) cons
__dna_writer.writeBool(unk1);
/* unk2 */
__dna_writer.writeBool(unk2);
/* unk3 */
__dna_writer.writeUint32Big(unk3);
/* unk4 */
__dna_writer.writeUint32Big(unk4);
/* justification */
__dna_writer.writeUint32Big(atUint32(justification));
/* verticalJustification */
__dna_writer.writeUint32Big(atUint32(verticalJustification));
/* fillColor */
__dna_writer.writeVec4fBig(fillColor);
/* outlineColor */

View File

@ -183,6 +183,14 @@ struct FRME : BigDNA
struct TXPNInfo : IWidgetInfo
{
enum class Justification
{
};
enum class VerticalJustification
{
};
DECL_EXPLICIT_DNA
atUint32 version = 0;
TXPNInfo() {}
@ -193,8 +201,8 @@ struct FRME : BigDNA
UniqueID32 font;
Value<bool> unk1;
Value<bool> unk2;
Value<atUint32> unk3;
Value<atUint32> unk4;
Value<Justification> justification;
Value<VerticalJustification> verticalJustification;
Value<atVec4f> fillColor;
Value<atVec4f> outlineColor;
Value<atVec2f> pointScale;

View File

@ -0,0 +1,18 @@
#include "CAuiEnergyBarT01.hpp"
namespace urde
{
CAuiEnergyBarT01::CAuiEnergyBarT01(const CGuiWidgetParms& parms, u32)
: CGuiWidget(parms)
{
}
CAuiEnergyBarT01* CAuiEnergyBarT01::Create(CGuiFrame* frame, CInputStream& in, bool flag)
{
CGuiWidgetParms parms = ReadWidgetHeader(frame, in, flag);
u32 a = in.readUint32Big();
return new CAuiEnergyBarT01(parms, a);
}
}

View File

@ -8,6 +8,9 @@ namespace urde
class CAuiEnergyBarT01 : public CGuiWidget
{
public:
CAuiEnergyBarT01(const CGuiWidgetParms& parms, u32);
static CAuiEnergyBarT01* Create(CGuiFrame* frame, CInputStream& in, bool);
};
}

View File

@ -0,0 +1,32 @@
#include "CGuiBackground.hpp"
namespace urde
{
CGuiBackground::CGuiBackground(const CGuiWidgetParms& parms, float a, float b, const zeus::CVector3f& c,
EGuiTextureClampModeHorz horz, EGuiTextureClampModeVert vert,
CGuiStaticImage::EMaterialType mt, u32 d, u32 e,
std::vector<float>&& rect, bool flag)
: CGuiStaticImage(parms, a, b, c, horz, vert, mt, d, e, std::move(rect), flag)
{
}
CGuiBackground* CGuiBackground::Create(CGuiFrame* frame, CInputStream& in, bool flag)
{
CGuiWidgetParms parms = ReadWidgetHeader(frame, in, flag);
float a = in.readFloatBig();
float b = in.readFloatBig();
float c = in.readFloatBig();
float d = in.readFloatBig();
std::vector<float> floats = {a, b, a, d, c, b, c, d};
zeus::CVector3f vec;
vec.read(in);
in.readUint32Big();
in.readUint32Big();
in.readUint32Big();
in.readUint32Big();
}
}

View File

@ -0,0 +1,22 @@
#ifndef __URDE_CGUIBACKGROUND_HPP__
#define __URDE_CGUIBACKGROUND_HPP__
#include "CGuiWidget.hpp"
#include "CGuiStaticImage.hpp"
namespace urde
{
class CGuiBackground : public CGuiStaticImage
{
public:
CGuiBackground(const CGuiWidgetParms& parms, float a, float b, const zeus::CVector3f& c,
EGuiTextureClampModeHorz horz, EGuiTextureClampModeVert vert,
CGuiStaticImage::EMaterialType mt, u32 d, u32 e,
std::vector<float>&& rect, bool flag);
static CGuiBackground* Create(CGuiFrame* frame, CInputStream& in, bool);
};
}
#endif // __URDE_CGUIBACKGROUND_HPP__

View File

@ -0,0 +1,55 @@
#include "CGuiCamera.hpp"
#include "CGuiFrame.hpp"
namespace urde
{
CGuiCamera::CGuiCamera(const CGuiWidgetParms& parms,
float left, float right,
float top, float bottom,
float znear, float zfar)
: CGuiWidget(parms)
{
}
CGuiCamera::CGuiCamera(const CGuiWidgetParms& parms,
float fov, float aspect,
float znear, float zfar)
: CGuiWidget(parms)
{
}
CGuiCamera* CGuiCamera::Create(CGuiFrame* frame, CInputStream& in, bool flag)
{
CGuiWidgetParms parms = ReadWidgetHeader(frame, in, flag);
Projection proj = Projection(in.readUint32Big());
CGuiCamera* ret = nullptr;
switch (proj)
{
case Projection::Perspective:
{
float fov = in.readFloatBig();
float aspect = in.readFloatBig();
float znear = in.readFloatBig();
float zfar = in.readFloatBig();
ret = new CGuiCamera(parms, fov, aspect, znear, zfar);
break;
}
case Projection::Orthographic:
{
float left = in.readFloatBig();
float right = in.readFloatBig();
float top = in.readFloatBig();
float bottom = in.readFloatBig();
float znear = in.readFloatBig();
float zfar = in.readFloatBig();
ret = new CGuiCamera(parms, left, right, top, bottom, znear, zfar);
break;
}
break;
}
frame->SetFrameCamera(ret);
return ret;
}
}

View File

@ -6,6 +6,21 @@
namespace urde
{
class CGuiCamera : public CGuiWidget
{
public:
enum class Projection
{
Perspective,
Orthographic
};
private:
Projection xf8_proj;
public:
CGuiCamera(const CGuiWidgetParms& parms, float, float, float, float, float, float);
CGuiCamera(const CGuiWidgetParms& parms, float fov, float aspect, float znear, float zfar);
static CGuiCamera* Create(CGuiFrame* frame, CInputStream& in, bool flag);
};
}

View File

@ -10,11 +10,33 @@ CGuiFrame::CGuiFrame(u32 id, const std::string& name, CGuiSys& sys, int a, int b
: x4_name(name), x14_id(id), x1c_transitionOpts(EFrameTransitionOptions::Zero),
x3c_guiSys(sys), xb0_a(a), xb4_b(b), xb8_c(c), xbc_24_flag1(false)
{
xa0_.resize(8);
xa0_lights.resize(8);
x48_rootWidget.reset(new CGuiWidget(
CGuiWidget::CGuiWidgetParms(this, false, 0, 0, false, false, false, zeus::CColor::skWhite,
CGuiWidget::EGuiModelDrawFlags::Two, false,
x3c_guiSys.x2c_mode != CGuiSys::EUsageMode::Zero)));
}
CGuiWidget* CGuiFrame::FindWidget(const std::string& name) const
{
s16 id = x64_idDB.FindWidgetID(name);
if (id == -1)
return nullptr;
return FindWidget(id);
}
CGuiWidget* CGuiFrame::FindWidget(s16 id) const
{
return x48_rootWidget->FindWidget(id);
}
void CGuiFrame::ResetControllerStatus()
{
x0_controllerStatus[0] = false;
x0_controllerStatus[1] = false;
x0_controllerStatus[2] = false;
x0_controllerStatus[3] = false;
}
}

View File

@ -48,6 +48,7 @@ public:
{
};
private:
bool x0_controllerStatus[4] = {};
std::string x4_name;
u32 x14_id;
CGuiFrameTransitionOptions x1c_transitionOpts;
@ -55,15 +56,15 @@ private:
u32 x38_ = 0;
CGuiSys& x3c_guiSys;
u32 x40_ = 0;
u32 x44_ = 0;
CGuiHeadWidget* x44_headWidget = nullptr;
std::unique_ptr<CGuiWidget> x48_rootWidget;
u32 x4c_ = 0;
u32 x50_ = 0;
CGuiCamera* x4c_camera = nullptr;
CGuiWidget* x50_background = nullptr;
zeus::CQuaternion x54_;
CGuiWidgetIdDB x64_idDB;
std::unordered_map<u32, u32> x7c_;
std::vector<u32> x90_;
std::vector<u32> xa0_;
std::vector<CGuiLight*> xa0_lights;
int xb0_a;
int xb4_b;
int xb8_c;
@ -73,15 +74,16 @@ private:
public:
CGuiFrame(u32 id, const std::string& name, CGuiSys& sys, int a, int b, int c);
CGuiLight* GetFrameLight(int);
CGuiWidget* FindWidget(const char* name) const;
CGuiSys& GetGuiSys() {return x3c_guiSys;}
CGuiLight* GetFrameLight(int idx) {return xa0_lights[idx];}
CGuiWidget* FindWidget(const std::string& name) const;
CGuiWidget* FindWidget(s16 id) const;
void ResetControllerStatus();
void SetControllerStatus(int, bool);
void SetFrameBackground(CGuiWidget* widget);
void SetFrameCamera(CGuiCamera* camr);
void SetHeadWidget(CGuiHeadWidget* hwig);
void SetControllerStatus(int idx, bool set) {x0_controllerStatus[idx] = set;}
void SetFrameBackground(CGuiWidget* bg) {x50_background = bg;}
void SetFrameCamera(CGuiCamera* camr) {x4c_camera = camr;}
void SetHeadWidget(CGuiHeadWidget* hwig) {x44_headWidget = hwig;}
void InterpretGUIControllerState(const CFinalInput& input,
CGuiPhysicalMsg::PhysicalMap& state,
char&, char&, char&, char&);

View File

@ -0,0 +1,18 @@
#include "CGuiLight.hpp"
namespace urde
{
CGuiLight::CGuiLight(const CGuiWidgetParms& parms, const CLight& light)
: CGuiWidget(parms)
{
}
CGuiLight* CGuiLight::Create(CGuiFrame* frame, CInputStream& in, bool flag)
{
CGuiWidgetParms parms = ReadWidgetHeader(frame, in, flag);
}
}

View File

@ -2,10 +2,17 @@
#define __URDE_CGUILIGHT_HPP__
#include "CGuiWidget.hpp"
#include "Graphics/CLight.hpp"
namespace urde
{
class CGuiLight : public CGuiWidget
{
public:
CGuiLight(const CGuiWidgetParms& parms, const CLight& light);
static CGuiLight* Create(CGuiFrame* frame, CInputStream& in, bool);
};
}

View File

@ -1,18 +0,0 @@
#include "CGuiMenuRadial.hpp"
namespace urde
{
typedef bool(CGuiMenuRadial::*FMAF)(CGuiFunctionDef* def, CGuiControllerInfo* info);
static std::unordered_map<u32, FMAF> WidgetFnMap;
void CGuiMenuRadial::LoadWidgetFnMap()
{
WidgetFnMap.emplace(std::make_pair(34, &CGuiMenuRadial::MAF_SelectWithStick));
}
bool CGuiMenuRadial::MAF_SelectWithStick(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
}

View File

@ -1,19 +0,0 @@
#ifndef __URDE_CGUIMENURADIAL_HPP__
#define __URDE_CGUIMENURADIAL_HPP__
#include "CGuiTableGroup.hpp"
namespace urde
{
class CGuiMenuRadial : public CGuiTableGroup
{
public:
static void LoadWidgetFnMap();
bool MAF_SelectWithStick(CGuiFunctionDef* def, CGuiControllerInfo* info);
};
}
#endif // __URDE_CGUIMENURADIAL_HPP__

View File

@ -0,0 +1,32 @@
#include "CGuiModel.hpp"
#include "CGuiFrame.hpp"
#include "CGuiSys.hpp"
#include "CSimplePool.hpp"
namespace urde
{
CGuiModel::CGuiModel(const CGuiWidgetParms& parms, TResId modelId, u32 lightMode, bool flag)
: CGuiWidget(parms), x108_modelId(modelId), x10c_lightMode(lightMode)
{
if (!flag || (modelId & 0xffff) == 0xffff ||
parms.x0_frame->GetGuiSys().GetUsageMode() == CGuiSys::EUsageMode::Two)
return;
xf8_model = parms.x0_frame->GetGuiSys().GetResStore().GetObj({SBIG('CMDL'), modelId});
}
CGuiModel* CGuiModel::Create(CGuiFrame* frame, CInputStream& in, bool flag)
{
CGuiWidgetParms parms = ReadWidgetHeader(frame, in, flag);
TResId model = in.readUint32Big();
in.readUint32Big();
u32 lightMode = in.readUint32Big();
CGuiModel* ret = new CGuiModel(parms, model, lightMode, flag);
ret->ParseBaseInfo(frame, in, parms);
return ret;
}
}

View File

@ -2,10 +2,21 @@
#define __URDE_CGUIMODEL_HPP__
#include "CGuiWidget.hpp"
#include "CToken.hpp"
#include "Graphics/CModel.hpp"
namespace urde
{
class CGuiModel : public CGuiWidget
{
TLockedToken<CModel> xf8_model;
TResId x108_modelId;
u32 x10c_lightMode;
public:
CGuiModel(const CGuiWidgetParms& parms, TResId modelId, u32 lightMode, bool flag);
static CGuiModel* Create(CGuiFrame* frame, CInputStream& in, bool);
};
}

View File

@ -0,0 +1,22 @@
#include "CGuiPane.hpp"
namespace urde
{
CGuiPane::CGuiPane(const CGuiWidgetParms& parms, float a, float b, const zeus::CVector3f& vec)
: CGuiWidget(parms), xf8_a(a), xfc_b(b), x108_vec(vec)
{
InitializeBuffers();
}
CGuiPane* CGuiPane::Create(CGuiFrame* frame, CInputStream& in, bool flag)
{
CGuiWidgetParms parms = ReadWidgetHeader(frame, in, flag);
float a = in.readFloatBig();
float b = in.readFloatBig();
zeus::CVector3f vec;
vec.read(in);
return new CGuiPane(parms, a, b, vec);
}
}

View File

@ -0,0 +1,29 @@
#ifndef __URDE_CGUIPANE_HPP__
#define __URDE_CGUIPANE_HPP__
#include "CGuiWidget.hpp"
namespace urde
{
class CGuiPane : public CGuiWidget
{
float xf8_a;
float xfc_b;
u32 x100_ = 0;
u32 x104_ = 4;
zeus::CVector3f x108_vec;
public:
CGuiPane(const CGuiWidgetParms& parms, float a, float b, const zeus::CVector3f& vec);
static CGuiPane* Create(CGuiFrame* frame, CInputStream& in, bool);
virtual void ScaleDimensions(const zeus::CVector3f& scale);
virtual void SetDimensions(const zeus::CVector2f& dim, bool flag);
virtual const zeus::CVector3f& GetDimensions() const;
virtual void InitializeBuffers();
virtual void WriteData(COutputStream& out, bool flag) const;
};
}
#endif // __URDE_CGUIPANE_HPP__

View File

@ -0,0 +1,32 @@
#include "CGuiStaticImage.hpp"
namespace urde
{
CGuiStaticImage::CGuiStaticImage
(const CGuiWidgetParms& parms, float a, float b, const zeus::CVector3f& c,
EGuiTextureClampModeHorz, EGuiTextureClampModeVert,
CGuiStaticImage::EMaterialType, u32, u32,
std::vector<float>&&, bool)
: CGuiPane(parms, a, b, c)
{
}
CGuiStaticImage* CGuiStaticImage::Create(CGuiFrame* frame, CInputStream& in, bool flag)
{
CGuiWidgetParms parms = ReadWidgetHeader(frame, in, flag);
float a = in.readFloatBig();
float b = in.readFloatBig();
float c = in.readFloatBig();
float d = in.readFloatBig();
std::vector<float> floats = {a, b, a, d, c, b, c, d};
zeus::CVector3f vec;
vec.read(in);
u32 e = in.readUint32Big();
u32 f = in.readUint32Big();
u32 g = in.readUint32Big();
}
}

View File

@ -1,9 +1,23 @@
#ifndef __URDE_CGUISTATICIMAGE_HPP__
#define __URDE_CGUISTATICIMAGE_HPP__
#include "CGuiPane.hpp"
namespace urde
{
class CGuiStaticImage : public CGuiPane
{
public:
enum class EMaterialType
{
};
CGuiStaticImage(const CGuiWidgetParms& parms, float, float, const zeus::CVector3f&,
EGuiTextureClampModeHorz, EGuiTextureClampModeVert,
CGuiStaticImage::EMaterialType, u32, u32,
std::vector<float>&&, bool);
static CGuiStaticImage* Create(CGuiFrame* frame, CInputStream& in, bool flag);
};
}

View File

@ -1,4 +1,19 @@
#include "CGuiSys.hpp"
#include "CGuiWidget.hpp"
#include "CGuiHeadWidget.hpp"
#include "CGuiBackground.hpp"
#include "CGuiLight.hpp"
#include "CGuiCamera.hpp"
#include "CGuiGroup.hpp"
#include "CGuiStaticImage.hpp"
#include "CGuiPane.hpp"
#include "CAuiImagePane.hpp"
#include "CAuiMeter.hpp"
#include "CGuiModel.hpp"
#include "CGuiTableGroup.hpp"
#include "CGuiSliderGroup.hpp"
#include "CGuiTextPane.hpp"
#include "CAuiEnergyBarT01.hpp"
namespace urde
{
@ -12,6 +27,45 @@ void CGuiSys::LoadWidgetFunctions()
{
}
CGuiWidget* CGuiSys::CreateWidgetInGame(hecl::FourCC type, CInputStream& in, CGuiFrame* frame)
{
switch (type)
{
case SBIG('BWIG'):
return CGuiWidget::Create(frame, in, false);
case SBIG('HWIG'):
return CGuiHeadWidget::Create(frame, in, false);
case SBIG('BGND'):
return CGuiBackground::Create(frame, in, false);
case SBIG('LITE'):
return CGuiLight::Create(frame, in, false);
case SBIG('CAMR'):
return CGuiCamera::Create(frame, in, false);
case SBIG('GRUP'):
return CGuiGroup::Create(frame, in, false);
case SBIG('IMAG'):
return CGuiStaticImage::Create(frame, in, false);
case SBIG('PANE'):
return CGuiPane::Create(frame, in, false);
case SBIG('IMGP'):
return CAuiImagePane::Create(frame, in, false);
case SBIG('METR'):
return CAuiMeter::Create(frame, in, false);
case SBIG('MODL'):
return CGuiModel::Create(frame, in, false);
case SBIG('TBGP'):
return CGuiTableGroup::Create(frame, in, false);
case SBIG('SLGP'):
return CGuiSliderGroup::Create(frame, in, false);
case SBIG('TXPN'):
return CGuiTextPane::Create(frame, in, false);
case SBIG('ENRG'):
return CAuiEnergyBarT01::Create(frame, in, false);
default: break;
}
return nullptr;
}
CGuiSys::CGuiSys(IFactory& resFactory, CSimplePool& resStore, EUsageMode mode)
: x0_resFactory(resFactory), x4_resStore(resStore), x2c_mode(mode),
x38_frameFactoryParams(new TObjOwnerParam<CGuiResFrameData>(CGuiResFrameData(*this))),

View File

@ -8,6 +8,7 @@
#include <chrono>
#include "CGuiAutoRepeatData.hpp"
#include "CSaveableState.hpp"
#include "IOStreams.hpp"
namespace urde
{
@ -16,6 +17,8 @@ class CVParamTransfer;
class SObjectTag;
class IFactory;
class CSimplePool;
class CGuiWidget;
class CGuiFrame;
typedef CGuiObject*(*FGuiFactoryFunc)(const SObjectTag&, const CVParamTransfer&);
@ -36,7 +39,9 @@ class CGuiSys
public:
enum class EUsageMode
{
Zero
Zero,
One,
Two
};
private:
IFactory& x0_resFactory;
@ -44,14 +49,18 @@ private:
CGuiFactoryMgr x8_factoryMgr;
std::unordered_map<EPhysicalControllerID, CGuiAutoRepeatData> x18_repeatMap;
EUsageMode x2c_mode;
std::stack<CSaveableState, std::vector<CSaveableState>> x28_saveStack;
std::stack<CSaveableState, std::vector<CSaveableState>> x30_saveStack;
CVParamTransfer x38_frameFactoryParams;
std::chrono::time_point<std::chrono::steady_clock> x40_constructTime;
void AddFactories(EUsageMode mode);
void LoadWidgetFunctions();
CGuiWidget* CreateWidgetInGame(hecl::FourCC type, CInputStream& in, CGuiFrame* frame);
public:
CGuiSys(IFactory& resFactory, CSimplePool& resStore, EUsageMode mode);
CSimplePool& GetResStore() {return x4_resStore;}
EUsageMode GetUsageMode() const {return x2c_mode;}
};
/** Parameter pack for FRME factory */

View File

@ -0,0 +1,36 @@
#include "CGuiTextPane.hpp"
namespace urde
{
CGuiTextPane::CGuiTextPane(const CGuiWidgetParms& parms, float a, float b,
const zeus::CVector3f& vec, u32 c, const CGuiTextProperties& props,
const zeus::CColor& col1, const zeus::CColor& col2,
int, int)
: CGuiPane(parms, a, b, vec)
{
}
CGuiTextPane* CGuiTextPane::Create(CGuiFrame* frame, CInputStream& in, bool flag)
{
CGuiWidgetParms parms = ReadWidgetHeader(frame, in, flag);
float a = in.readFloatBig();
float b = in.readFloatBig();
zeus::CVector3f vec;
vec.read(in);
u32 c = in.readUint32Big();
bool d = in.readBool();
bool e = in.readBool();
EJustification justification = EJustification(in.readUint32Big());
EVerticalJustification vJustification = EVerticalJustification(in.readUint32Big());
CGuiTextProperties props(d, e, 0, justification, vJustification);
zeus::CColor col1;
col1.readRGBA(in);
zeus::CColor col2;
col2.readRGBA(in);
int f = in.readFloatBig();
int g = in.readFloatBig();
return new CGuiTextPane(parms, a, b, vec, c, props, col1, col2, f, g);
}
}

View File

@ -1,11 +1,41 @@
#ifndef __URDE_CGUITEXTPANE_HPP__
#define __URDE_CGUITEXTPANE_HPP__
#include "CGuiWidget.hpp"
#include "CGuiPane.hpp"
namespace urde
{
enum class EJustification
{
};
enum class EVerticalJustification
{
};
class CGuiTextProperties
{
bool x0_a;
bool x1_b;
bool x2_c;
EJustification x4_justification;
EVerticalJustification x8_vertJustification;
public:
CGuiTextProperties(bool a, bool b, bool c, EJustification justification,
EVerticalJustification vertJustification)
: x0_a(a), x1_b(b), x2_c(c), x4_justification(justification),
x8_vertJustification(vertJustification) {}
};
class CGuiTextPane : public CGuiPane
{
public:
CGuiTextPane(const CGuiWidgetParms& parms, float a, float b, const zeus::CVector3f& vec,
u32, const CGuiTextProperties& props, const zeus::CColor& col1, const zeus::CColor& col2,
int, int);
static CGuiTextPane* Create(CGuiFrame* frame, CInputStream& in, bool);
};
}

View File

@ -23,6 +23,14 @@ enum class EGuiAnimInitMode
{
};
enum class EGuiTextureClampModeHorz
{
};
enum class EGuiTextureClampModeVert
{
};
class CGuiWidget : public CGuiObject
{
public:
@ -112,7 +120,7 @@ public:
void SetColor(const zeus::CColor& color);
void RecalculateAllRGBA();
void InitializeRGBAFactor();
void FindWidget(u16);
CGuiWidget* FindWidget(s16 id);
bool GetIsFinishedLoading() const;
void InitializeRecursive();

View File

@ -60,8 +60,6 @@ add_library(RuntimeCommonGuiSys
CRasterFont.hpp
CGuiGroup.cpp
CGuiGroup.hpp
CGuiMenuRadial.cpp
CGuiMenuRadial.hpp
CGuiFunctionDef.cpp
CGuiFunctionDef.hpp
CGuiFuncParm.cpp
@ -74,4 +72,8 @@ add_library(RuntimeCommonGuiSys
CGuiWidgetIdDB.cpp
CGuiWidgetIdDB.hpp
CGuiHeadWidget.cpp
CGuiHeadWidget.hpp)
CGuiHeadWidget.hpp
CGuiBackground.cpp
CGuiBackground.hpp
CGuiPane.cpp
CGuiPane.hpp)

View File

@ -3,6 +3,7 @@
#include "CDrawStringOptions.hpp"
#include "CToken.hpp"
#include "zeus/CColor.hpp"
namespace urde
{
@ -12,14 +13,7 @@ class CSaveableState
{
CDrawStringOptions x0_drawStrOpts;
TToken<CRasterFont> x14_token;
struct VecElem
{
u8 a = 0;
u8 b = 0;
u8 c = 0;
u8 d = 0xff;
};
std::vector<VecElem> x20_;
std::vector<zeus::CColor> x20_;
std::vector<u8> x30_;
float x40_ = 1.f;
u32 x44_ = 0;
@ -29,7 +23,7 @@ class CSaveableState
CSaveableState()
{
x20_.resize(3);
x20_.resize(3, zeus::CColor::skBlack);
x30_.resize(16);
}
};