From 29661ddddec6484a96ed2c6e6b84e66f660612ca Mon Sep 17 00:00:00 2001 From: Rinnegatamante Date: Sat, 9 Sep 2023 23:14:53 +0200 Subject: [PATCH] Added implementations for steam_stats_ready and steam_initialised. --- CMakeLists.txt | 4 ++-- loader/trophies.c | 10 ++++++++++ 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/CMakeLists.txt b/CMakeLists.txt index 382035e..c6ef68a 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -66,7 +66,7 @@ target_link_libraries(YoYoLoader mathneon mpg123 curl - ssl + -Wl,--whole-archive ssl -Wl,--no-whole-archive crypto taihen_stub kubridge_stub @@ -122,7 +122,7 @@ target_link_libraries(YoYoLoader SceShaccCgExt mathneon curl - ssl + -Wl,--whole-archive ssl -Wl,--no-whole-archive crypto taihen_stub kubridge_stub diff --git a/loader/trophies.c b/loader/trophies.c index 78968a0..3cbdc29 100644 --- a/loader/trophies.c +++ b/loader/trophies.c @@ -174,6 +174,14 @@ void achievements_available(retval_t *ret, void *self, void *other, int argc, re ret->rvalue.val = trophies_available ? 1.0f : 0.0f; } +void steam_stats_ready(retval_t *ret, void *self, void *other, int argc, retval_t *args) { + ret->rvalue.val = trophies_available ? 1.0f : 0.0f; +} + +void steam_initialised(retval_t *ret, void *self, void *other, int argc, retval_t *args) { + ret->rvalue.val = trophies_available ? 1.0f : 0.0f; +} + void achievements_post(retval_t *ret, void *self, void *other, int argc, retval_t *args) { float progress = YYGetFloat(args, 1); if (progress == 100.0f) { @@ -194,6 +202,8 @@ void patch_trophies() { Function_Add("steam_set_achievement", steam_set_achievement, 1, 0); Function_Add("steam_get_achievement", steam_get_achievement, 1, 0); + Function_Add("steam_stats_ready", steam_stats_ready, 0, 0); + Function_Add("steam_initialised", steam_initialised, 0, 0); Function_Add("achievement_available", achievements_available, 0, 0); Function_Add("YoYo_AchievementsAvailable", achievements_available, 0, 0); Function_Add("achievement_post", achievements_post, 2, 0);