mirror of
https://github.com/whoahq/whoa.git
synced 2026-02-01 00:02:45 +03:00
feat(glue): call CGlueLoading::StartLoad from CCharacterSelection::ShowCharacter
This commit is contained in:
parent
5277bf7f5d
commit
550f7dbdd0
@ -2,6 +2,7 @@
|
||||
#include "client/ClientServices.hpp"
|
||||
#include "component/CCharacterComponent.hpp"
|
||||
#include "db/Db.hpp"
|
||||
#include "glue/CGlueLoading.hpp"
|
||||
#include "glue/CGlueMgr.hpp"
|
||||
#include "glue/CRealmList.hpp"
|
||||
#include "glue/Types.hpp"
|
||||
@ -169,7 +170,8 @@ void CCharacterSelection::ShowCharacter() {
|
||||
petModel->AttachToParent(parent, 1, nullptr, 0);
|
||||
}
|
||||
|
||||
// TODO CGlueLoading::StartLoad(&character->component, 0);
|
||||
// TODO a2 may be 1 in some circumstances
|
||||
CGlueLoading::StartLoad(character->component, 0);
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
21
src/glue/CGlueLoading.cpp
Normal file
21
src/glue/CGlueLoading.cpp
Normal file
@ -0,0 +1,21 @@
|
||||
#include "glue/CGlueLoading.hpp"
|
||||
#include "component/CCharacterComponent.hpp"
|
||||
#include "model/Model2.hpp"
|
||||
#include "util/SFile.hpp"
|
||||
|
||||
int32_t CGlueLoading::s_loadState;
|
||||
|
||||
void CGlueLoading::StartLoad(CCharacterComponent* component, int32_t a2) {
|
||||
if (SFile::IsStreamingTrial()) {
|
||||
// TODO
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
if (component) {
|
||||
component->RenderPrep(1);
|
||||
component->m_data.model->IsDrawable(1, 1);
|
||||
}
|
||||
|
||||
CGlueLoading::s_loadState = 3;
|
||||
}
|
||||
17
src/glue/CGlueLoading.hpp
Normal file
17
src/glue/CGlueLoading.hpp
Normal file
@ -0,0 +1,17 @@
|
||||
#ifndef GLUE_C_GLUE_LOADING_HPP
|
||||
#define GLUE_C_GLUE_LOADING_HPP
|
||||
|
||||
#include <cstdint>
|
||||
|
||||
class CCharacterComponent;
|
||||
|
||||
class CGlueLoading {
|
||||
public:
|
||||
// Static variables
|
||||
static int32_t s_loadState;
|
||||
|
||||
// Static functions
|
||||
static void StartLoad(CCharacterComponent* component, int32_t a2);
|
||||
};
|
||||
|
||||
#endif
|
||||
Loading…
Reference in New Issue
Block a user