More GuiSys stubs

This commit is contained in:
Jack Andersen 2016-03-10 14:23:16 -10:00
parent 9726682939
commit 1908ac111b
27 changed files with 557 additions and 17 deletions

View File

@ -11,7 +11,6 @@
namespace urde
{
class IObjectStore;
class IObj;
/** Shared data-structure for CToken references, analogous to std::shared_ptr */
class CObjectReference
@ -86,7 +85,7 @@ public:
/** Pointer-synchronized object-destructor, another building Lock cycle may be performed after */
void Unload()
{
delete x10_object;
std::default_delete<IObj>()(x10_object);
x10_object = nullptr;
x3_loading = false;
}
@ -109,7 +108,7 @@ public:
~CObjectReference()
{
if (x10_object)
delete x10_object;
std::default_delete<IObj>()(x10_object);
else if (x3_loading)
xC_objectStore->GetFactory().CancelBuild(x4_objTag);
}
@ -145,7 +144,7 @@ public:
{
if (x0_objRef && x0_objRef->RemoveReference() == 0)
{
delete x0_objRef;
std::default_delete<CObjectReference>()(x0_objRef);
x0_objRef = nullptr;
}
}
@ -183,7 +182,8 @@ public:
CToken(const CToken& other)
: x0_objRef(other.x0_objRef)
{
++x0_objRef->x0_refCount;
if (x0_objRef)
++x0_objRef->x0_refCount;
}
CToken(CToken&& other)
: x0_objRef(other.x0_objRef), x4_lockHeld(other.x4_lockHeld)
@ -230,8 +230,7 @@ public:
TToken() = default;
TToken(const CToken& other) : CToken(other) {}
TToken(CToken&& other) : CToken(std::move(other)) {}
TToken(T* obj)
: CToken(GetIObjObjectFor(std::unique_ptr<T>(obj))) {}
TToken(T* obj) : CToken(GetIObjObjectFor(std::unique_ptr<T>(obj))) {}
TToken& operator=(T* obj) {*this = CToken(GetIObjObjectFor(obj)); return this;}
T* GetObj()
{

View File

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

View File

@ -8,6 +8,8 @@ namespace urde
class CAuiMeter : public CGuiCompoundWidget
{
public:
static void LoadWidgetFnMap();
};
}

View File

View File

@ -0,0 +1,23 @@
#ifndef __URDE_CDRAWSTRINGOPTIONS_HPP__
#define __URDE_CDRAWSTRINGOPTIONS_HPP__
#include <vector>
#include "RetroTypes.hpp"
namespace urde
{
class CDrawStringOptions
{
u32 x0_ = 0;
std::vector<u32> x4_vec;
public:
CDrawStringOptions()
{
x4_vec.resize(16);
}
};
}
#endif // __URDE_CDRAWSTRINGOPTIONS_HPP__

View File

@ -4,6 +4,52 @@
namespace urde
{
enum class EPhysicalControllerID
{
Seventeen = 17,
Eighteen = 18,
Nineteen = 19,
Twenty = 20,
TwentyOne = 21,
TwentyTwo = 22,
TwentyThree = 23,
TwentyFour = 24,
ThirtyThree = 33,
ThirtyFour = 34,
ThirtyFive = 35,
ThirtySix = 36,
ThirtySeven = 37,
ThirtyEight = 38,
ThirtyNine = 39,
Forty = 40,
FortyOne = 41,
FortyTwo = 42,
FortyThree = 43,
FortyFour = 44,
FortyFive = 45,
FortySix = 46,
FortySeven = 47,
FortyEight = 48,
TwentyFive = 25,
TwentySix = 26,
TwentySeven = 27,
TwentyEight = 28,
TwentyNine = 29,
Thirty = 30,
ThirtyOne = 31,
ThirtyTwo = 32
};
class CGuiAutoRepeatData
{
EPhysicalControllerID x0_a;
EPhysicalControllerID x4_b;
float x8_[8] = {0.f, 0.f, 0.f, 0.f, 0.2f, 0.2f, 0.2f, 0.2f};
bool x28_[8] = {};
public:
CGuiAutoRepeatData(EPhysicalControllerID a, EPhysicalControllerID b)
: x0_a(a), x4_b(b) {}
};
}

View File

@ -0,0 +1,10 @@
#include "CGuiGroup.hpp"
namespace urde
{
void CGuiGroup::LoadWidgetFnMap()
{
}
}

View File

@ -0,0 +1,17 @@
#ifndef __URDE_CGUIGROUP_HPP__
#define __URDE_CGUIGROUP_HPP__
#include "CGuiCompoundWidget.hpp"
namespace urde
{
class CGuiGroup : public CGuiCompoundWidget
{
public:
static void LoadWidgetFnMap();
};
}
#endif // __URDE_CGUIGROUP_HPP__

View File

@ -0,0 +1,18 @@
#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

@ -0,0 +1,19 @@
#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

@ -4,6 +4,12 @@
namespace urde
{
CGuiObject::~CGuiObject()
{
delete x74_child;
delete x78_nextSibling;
}
void CGuiObject::Update(float dt)
{
if (x74_child)
@ -31,18 +37,24 @@ void CGuiObject::MoveInWorld(const zeus::CVector3f& vec)
void CGuiObject::RotateReset()
{
x4_localXF.m_basis = zeus::CMatrix3f::skIdentityMatrix3f;
Reorthogonalize();
RecalculateTransforms();
}
zeus::CVector3f CGuiObject::RotateW2O(const zeus::CVector3f& vec) const
{
return x34_worldXF.transposeRotate(vec);
}
zeus::CVector3f CGuiObject::RotateO2P(const zeus::CVector3f& vec) const
{
return x4_localXF.rotate(vec);
}
zeus::CVector3f CGuiObject::RotateTranslateW2O(const zeus::CVector3f& vec) const
{
return x34_worldXF.transposeRotate(vec - x34_worldXF.m_origin);
}
void CGuiObject::MultiplyO2P(const zeus::CTransform& xf)
@ -54,7 +66,7 @@ void CGuiObject::MultiplyO2P(const zeus::CTransform& xf)
RecalculateTransforms();
}
void CGuiObject::AddChildObject(CGuiObject* obj, bool calcChildWorld, bool atEnd)
void CGuiObject::AddChildObject(CGuiObject* obj, bool makeWorldLocal, bool atEnd)
{
obj->x70_parent = this;
@ -76,9 +88,15 @@ void CGuiObject::AddChildObject(CGuiObject* obj, bool calcChildWorld, bool atEnd
x74_child = obj;
}
if (calcChildWorld)
if (makeWorldLocal)
{
// TODO: do
zeus::CVector3f negParentWorld = -x34_worldXF.m_origin;
zeus::CMatrix3f basisMat(
x34_worldXF.m_basis[0] / x34_worldXF.m_basis[0].magnitude(),
x34_worldXF.m_basis[1] / x34_worldXF.m_basis[1].magnitude(),
x34_worldXF.m_basis[2] / x34_worldXF.m_basis[2].magnitude());
zeus::CVector3f xfWorld = basisMat * negParentWorld;
obj->x4_localXF = zeus::CTransform(basisMat, xfWorld) * obj->x34_worldXF;
}
RecalculateTransforms();

View File

@ -8,6 +8,9 @@
namespace urde
{
class CGuiWidgetDrawParms;
class CGuiMessage;
class CGuiFunctionDef;
class CGuiControllerInfo;
class CGuiObject
{
@ -18,9 +21,10 @@ class CGuiObject
CGuiObject* x74_child = nullptr;
CGuiObject* x78_nextSibling = nullptr;
public:
virtual ~CGuiObject() = default;
virtual ~CGuiObject();
virtual void Update(float dt);
virtual void Draw(const CGuiWidgetDrawParms& parms) const;
virtual void Message(const CGuiMessage& msg)=0;
void MoveInWorld(const zeus::CVector3f& vec);
const zeus::CVector3f& GetLocalPosition() const {return x4_localXF.m_origin;}
@ -31,7 +35,7 @@ public:
zeus::CVector3f RotateO2P(const zeus::CVector3f& vec) const;
zeus::CVector3f RotateTranslateW2O(const zeus::CVector3f& vec) const;
void MultiplyO2P(const zeus::CTransform& xf);
void AddChildObject(CGuiObject* obj, bool, bool);
void AddChildObject(CGuiObject* obj, bool makeWorldLocal, bool atEnd);
CGuiObject* RemoveChildObject(CGuiObject* obj, bool makeWorldLocal);
CGuiObject* GetParent() {return x70_parent;}
CGuiObject* GetChildObject() {return x74_child;}

View File

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

View File

@ -1,11 +1,19 @@
#ifndef __URDE_CGUISLIDERGROUP_HPP__
#define __URDE_CGUISLIDERGROUP_HPP__
#include "CGuiWidget.hpp"
#include "CGuiCompoundWidget.hpp"
namespace urde
{
class CGuiSliderGroup : public CGuiCompoundWidget
{
public:
static void LoadWidgetFnMap();
bool MAF_Increment(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_Decrement(CGuiFunctionDef* def, CGuiControllerInfo* info);
};
}

View File

@ -0,0 +1,69 @@
#include "CGuiSys.hpp"
namespace urde
{
void CGuiSys::AddFactories(EUsageMode /* mode */)
{
x8_factoryMgr.m_factories.clear();
}
void CGuiSys::LoadWidgetFunctions()
{
}
CGuiSys::CGuiSys(IFactory& resFactory, CSimplePool& resStore, EUsageMode mode)
: x0_resFactory(resFactory), x4_resStore(resStore), x2c_mode(mode),
x38_frameFactoryParams(new TObjOwnerParam<CGuiResFrameData>(CGuiResFrameData(*this))),
x40_constructTime(std::chrono::steady_clock::now())
{
AddFactories(mode);
LoadWidgetFunctions();
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::Seventeen,
CGuiAutoRepeatData(EPhysicalControllerID::Seventeen, EPhysicalControllerID::Eighteen)));
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::Nineteen,
CGuiAutoRepeatData(EPhysicalControllerID::Nineteen, EPhysicalControllerID::Twenty)));
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::TwentyOne,
CGuiAutoRepeatData(EPhysicalControllerID::TwentyOne, EPhysicalControllerID::TwentyTwo)));
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::TwentyThree,
CGuiAutoRepeatData(EPhysicalControllerID::TwentyThree, EPhysicalControllerID::TwentyFour)));
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::ThirtyFive,
CGuiAutoRepeatData(EPhysicalControllerID::ThirtyFive, EPhysicalControllerID::ThirtySix)));
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::ThirtySeven,
CGuiAutoRepeatData(EPhysicalControllerID::ThirtySeven, EPhysicalControllerID::ThirtyEight)));
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::ThirtyNine,
CGuiAutoRepeatData(EPhysicalControllerID::ThirtyNine, EPhysicalControllerID::Forty)));
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::FortyOne,
CGuiAutoRepeatData(EPhysicalControllerID::FortyOne, EPhysicalControllerID::FortyTwo)));
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::FortyThree,
CGuiAutoRepeatData(EPhysicalControllerID::FortyThree, EPhysicalControllerID::FortyFour)));
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::FortyFive,
CGuiAutoRepeatData(EPhysicalControllerID::FortyFive, EPhysicalControllerID::FortySix)));
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::FortySeven,
CGuiAutoRepeatData(EPhysicalControllerID::FortySeven, EPhysicalControllerID::FortyEight)));
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::TwentyFive,
CGuiAutoRepeatData(EPhysicalControllerID::TwentyFive, EPhysicalControllerID::TwentySix)));
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::TwentySeven,
CGuiAutoRepeatData(EPhysicalControllerID::TwentySeven, EPhysicalControllerID::TwentyEight)));
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::TwentyNine,
CGuiAutoRepeatData(EPhysicalControllerID::TwentyNine, EPhysicalControllerID::Thirty)));
x18_repeatMap.emplace(std::make_pair(EPhysicalControllerID::ThirtyOne,
CGuiAutoRepeatData(EPhysicalControllerID::ThirtyOne, EPhysicalControllerID::ThirtyTwo)));
}
}

View File

@ -1,11 +1,71 @@
#ifndef __URDE_CGUISYS_HPP__
#define __URDE_CGUISYS_HPP__
#include "hecl/hecl.hpp"
#include <unordered_map>
#include <vector>
#include <stack>
#include <chrono>
#include "CGuiAutoRepeatData.hpp"
#include "CSaveableState.hpp"
namespace std
{
template <> struct hash<urde::EPhysicalControllerID>
{
size_t operator() (const urde::EPhysicalControllerID& id) const NOEXCEPT {return size_t(id);}
};
}
namespace urde
{
class CGuiObject;
class CVParamTransfer;
class SObjectTag;
class IFactory;
class CSimplePool;
typedef CGuiObject*(*FGuiFactoryFunc)(const SObjectTag&, const CVParamTransfer&);
class CGuiFactoryMgr
{
friend class CGuiSys;
std::unordered_map<hecl::FourCC, FGuiFactoryFunc> m_factories;
public:
void AddFactory(hecl::FourCC key, FGuiFactoryFunc func)
{
m_factories[key] = func;
}
};
class CGuiSys
{
public:
enum class EUsageMode
{
Zero
};
private:
IFactory& x0_resFactory;
CSimplePool& x4_resStore;
CGuiFactoryMgr x8_factoryMgr;
std::unordered_map<EPhysicalControllerID, CGuiAutoRepeatData> x18_repeatMap;
EUsageMode x2c_mode;
std::stack<CSaveableState, std::vector<CSaveableState>> x28_saveStack;
CVParamTransfer x38_frameFactoryParams;
std::chrono::time_point<std::chrono::steady_clock> x40_constructTime;
void AddFactories(EUsageMode mode);
void LoadWidgetFunctions();
public:
CGuiSys(IFactory& resFactory, CSimplePool& resStore, EUsageMode mode);
};
/** Parameter pack for FRME factory */
struct CGuiResFrameData
{
CGuiSys& x0_guiSys;
CGuiResFrameData(CGuiSys& guiSys) : x0_guiSys(guiSys) {}
};
}

View File

@ -0,0 +1,78 @@
#include "CGuiTableGroup.hpp"
namespace urde
{
typedef bool(CGuiTableGroup::*FMAF)(CGuiFunctionDef* def, CGuiControllerInfo* info);
static std::unordered_map<u32, FMAF> WidgetFnMap;
void CGuiTableGroup::LoadWidgetFnMap()
{
WidgetFnMap.emplace(std::make_pair(21, &CGuiTableGroup::MAF_SelectNextColumn));
WidgetFnMap.emplace(std::make_pair(22, &CGuiTableGroup::MAF_SelectPrevColumn));
WidgetFnMap.emplace(std::make_pair(23, &CGuiTableGroup::MAF_SelectNextRow));
WidgetFnMap.emplace(std::make_pair(24, &CGuiTableGroup::MAF_SelectPrevRow));
WidgetFnMap.emplace(std::make_pair(25, &CGuiTableGroup::MAF_SelectNextColumnSkipUnActivated));
WidgetFnMap.emplace(std::make_pair(26, &CGuiTableGroup::MAF_SelectPrevColumnSkipUnActivated));
WidgetFnMap.emplace(std::make_pair(27, &CGuiTableGroup::MAF_SelectNextRowSkipUnActivated));
WidgetFnMap.emplace(std::make_pair(28, &CGuiTableGroup::MAF_SelectPrevRowSkipUnActivated));
WidgetFnMap.emplace(std::make_pair(29, &CGuiTableGroup::MAF_SelectColumnAtIndex));
WidgetFnMap.emplace(std::make_pair(30, &CGuiTableGroup::MAF_SelectRowAtIndex));
WidgetFnMap.emplace(std::make_pair(31, &CGuiTableGroup::MAF_InitializeTable));
WidgetFnMap.emplace(std::make_pair(32, &CGuiTableGroup::MAF_MenuAdvance));
WidgetFnMap.emplace(std::make_pair(33, &CGuiTableGroup::MAF_MenuCancel));
}
bool CGuiTableGroup::MAF_SelectNextColumn(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiTableGroup::MAF_SelectPrevColumn(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiTableGroup::MAF_SelectNextRow(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiTableGroup::MAF_SelectPrevRow(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiTableGroup::MAF_SelectNextColumnSkipUnActivated(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiTableGroup::MAF_SelectPrevColumnSkipUnActivated(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiTableGroup::MAF_SelectNextRowSkipUnActivated(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiTableGroup::MAF_SelectPrevRowSkipUnActivated(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiTableGroup::MAF_SelectColumnAtIndex(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiTableGroup::MAF_SelectRowAtIndex(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiTableGroup::MAF_InitializeTable(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiTableGroup::MAF_MenuAdvance(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiTableGroup::MAF_MenuCancel(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
}

View File

@ -1,11 +1,30 @@
#ifndef __URDE_CGUITABLEGROUP_HPP__
#define __URDE_CGUITABLEGROUP_HPP__
#include "CGuiWidget.hpp"
#include "CGuiCompoundWidget.hpp"
namespace urde
{
class CGuiTableGroup : public CGuiCompoundWidget
{
public:
static void LoadWidgetFnMap();
bool MAF_SelectNextColumn(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_SelectPrevColumn(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_SelectNextRow(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_SelectPrevRow(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_SelectNextColumnSkipUnActivated(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_SelectPrevColumnSkipUnActivated(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_SelectNextRowSkipUnActivated(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_SelectPrevRowSkipUnActivated(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_SelectColumnAtIndex(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_SelectRowAtIndex(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_InitializeTable(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_MenuAdvance(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_MenuCancel(CGuiFunctionDef* def, CGuiControllerInfo* info);
};
}

View File

@ -3,4 +3,41 @@
namespace urde
{
typedef bool(CGuiWidget::*FMAF)(CGuiFunctionDef* def, CGuiControllerInfo* info);
static std::unordered_map<u32, FMAF> WidgetFnMap;
void CGuiWidget::LoadWidgetFnMap()
{
WidgetFnMap.emplace(std::make_pair(2, &CGuiWidget::MAF_StartAnimationSet));
WidgetFnMap.emplace(std::make_pair(3, &CGuiWidget::MAF_SendMessage));
WidgetFnMap.emplace(std::make_pair(6, &CGuiWidget::MAF_PauseAnim));
WidgetFnMap.emplace(std::make_pair(7, &CGuiWidget::MAF_ResumeAnim));
WidgetFnMap.emplace(std::make_pair(11, &CGuiWidget::MAF_SetState));
WidgetFnMap.emplace(std::make_pair(12, &CGuiWidget::MAF_SetStateOfWidget));
}
bool CGuiWidget::MAF_StartAnimationSet(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiWidget::MAF_SendMessage(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiWidget::MAF_PauseAnim(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiWidget::MAF_ResumeAnim(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiWidget::MAF_SetState(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
bool CGuiWidget::MAF_SetStateOfWidget(CGuiFunctionDef* def, CGuiControllerInfo* info)
{
}
}

View File

@ -20,6 +20,7 @@ public:
struct CGuiWidgetParms
{
};
static void LoadWidgetFnMap();
private:
public:
virtual void Message(const CGuiMessage& msg);
@ -49,6 +50,13 @@ public:
virtual void OnDeActivate();
virtual void DoRegisterEventHandler();
virtual void DoUnregisterEventHandler();
bool MAF_StartAnimationSet(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_SendMessage(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_PauseAnim(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_ResumeAnim(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_SetState(CGuiFunctionDef* def, CGuiControllerInfo* info);
bool MAF_SetStateOfWidget(CGuiFunctionDef* def, CGuiControllerInfo* info);
};
}

View File

@ -51,4 +51,14 @@ add_library(RuntimeCommonGuiSys
CSplashScreen.cpp
CSplashScreen.hpp
CGuiCompoundWidget.cpp
CGuiCompoundWidget.hpp)
CGuiCompoundWidget.hpp
CSaveableState.cpp
CSaveableState.hpp
CDrawStringOptions.cpp
CDrawStringOptions.hpp
CRasterFont.cpp
CRasterFont.hpp
CGuiGroup.cpp
CGuiGroup.hpp
CGuiMenuRadial.cpp
CGuiMenuRadial.hpp)

View File

View File

@ -0,0 +1,13 @@
#ifndef __URDE_CRASTERFONT_HPP__
#define __URDE_CRASTERFONT_HPP__
namespace urde
{
class CRasterFont
{
};
}
#endif // __URDE_CRASTERFONT_HPP__

View File

@ -0,0 +1,6 @@
#include "CSaveableState.hpp"
namespace urde
{
}

View File

@ -0,0 +1,39 @@
#ifndef __URDE_CSAVEABLESTATE_HPP__
#define __URDE_CSAVEABLESTATE_HPP__
#include "CDrawStringOptions.hpp"
#include "CToken.hpp"
namespace urde
{
class CRasterFont;
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<u8> x30_;
float x40_ = 1.f;
u32 x44_ = 0;
bool x48_ = false;
u32 x4c_ = 0;
u32 x50_ = 0;
CSaveableState()
{
x20_.resize(3);
x30_.resize(16);
}
};
}
#endif // __URDE_CSAVEABLESTATE_HPP__

View File

@ -145,7 +145,8 @@ public:
CGameArchitectureSupport()
: m_audioSys(0,0,0,0,0),
m_inputGenerator(0.0f /*g_tweakPlayer->GetLeftLogicalThreshold()*/,
0.0f /*g_tweakPlayer->GetRightLogicalThreshold()*/)
0.0f /*g_tweakPlayer->GetRightLogicalThreshold()*/),
m_guiSys(*g_ResFactory, *g_SimplePool, CGuiSys::EUsageMode::Zero)
{
m_inputGenerator.startScanning();
}

@ -1 +1 @@
Subproject commit 0b750609a665a47afc959ae58613703a689e91f2
Subproject commit ce321d80fe2b8d5d20a8f4bfce7718700c7e2809