geode/loader/src/hooks/updateResources.cpp

22 lines
443 B
C++
Raw Normal View History

2022-07-30 12:24:03 -04:00
#include <Geode/Modify.hpp>
#include <Geode/loader/Loader.hpp>
USE_GEODE_NAMESPACE();
class $modify(GameManager) {
void reloadAllStep2() {
GameManager::reloadAllStep2();
Loader::get()->updateResourcePaths();
}
};
class $modify(LoadingLayer) {
void loadAssets() {
LoadingLayer::loadAssets();
if (this->m_loadStep == 5) {
Loader::get()->updateResourcePaths();
2022-07-30 12:24:03 -04:00
Loader::get()->updateResources();
}
}
};