Small fix

This commit is contained in:
fed 2023-01-27 03:41:47 +01:00
parent d27c723fa1
commit e14000a997
3 changed files with 9 additions and 2 deletions

View File

@ -58,8 +58,7 @@ namespace mods
command::execute("vid_restart");
scheduler::once([]
{
demonware::set_storage_path(mod_path.value_or(""));
utils::hook::invoke<void>(0x4E6B60_b, 0); // read stats
mods::read_stats();
}, scheduler::main);
return;
}
@ -113,6 +112,12 @@ namespace mods
return mod_path;
}
void read_stats()
{
demonware::set_storage_path(mod_path.value_or(""));
utils::hook::invoke<void>(0x4E6B60_b, 0); // read stats
}
class component final : public component_interface
{
public:

View File

@ -4,4 +4,5 @@ namespace mods
{
void set_mod(const std::string& path, bool change_fs_game = true);
std::optional<std::string> get_mod();
void read_stats();
}

View File

@ -435,6 +435,7 @@ namespace party
needs_vid_restart = false;
scheduler::once([=]()
{
mods::read_stats();
connect(target);
}, scheduler::pipeline::main);
return true;