1
0
forked from akanyan/mu3-mods

feat(NaiveRating): make it togglable

This commit is contained in:
2024-07-07 23:47:46 +09:00
parent af15a4410a
commit b54b8676c1
13 changed files with 174 additions and 45 deletions

View File

@ -4,7 +4,12 @@ namespace MU3.User;
[MonoModPatch("global::MU3.User.UserUtil")]
public static class patch_UserUtil {
public extern static float orig_toRatingFloat(int rating);
public static float toRatingFloat(int rating) {
return NaiveRating.Get() * 0.01f + 1E-05f;
if(NaiveRating.IsEnabled()) {
return orig_toRatingFloat(NaiveRating.Get());
} else {
return orig_toRatingFloat(rating);
}
}
}