Compare commits

...

3 Commits

Author SHA1 Message Date
ca15fac6a1 fix: don't store SortByInternal in db 2024-08-30 17:20:26 +00:00
ebb78efcde fix: item popup disappearing 2024-08-30 14:54:59 +00:00
2204fb4756 fix: shop confirmation dialog not showing (#7)
Co-authored-by: Jujuforce <jujuforce@gmail.com>
Co-authored-by: akanyan <alicechecker01@proton.me>
Co-authored-by: あかニャン <akanyan@noreply.gitea.tendokyu.moe>
Reviewed-on: akanyan/mu3-mods#7
Co-authored-by: jujuforce <jujuforce@noreply.gitea.tendokyu.moe>
Co-committed-by: jujuforce <jujuforce@noreply.gitea.tendokyu.moe>
2024-08-30 14:53:27 +00:00
5 changed files with 36 additions and 13 deletions

View File

@ -18,14 +18,13 @@ class patch_Scene_32_PrePlayMusic_MusicSelect: Scene_32_PrePlayMusic_MusicSelect
// Walk around the warning dialog
if(_dialogBase == null && !_selector.isDecided && !_selector.isCanceled && (_selector.isPressed || _selector.isPressedDisabledElement)) {
MusicSelectViewData musicViewData = _selectList.getMusicViewData(_selector.selectIndex);
if(musicViewData != null && musicViewData.kind == MusicSelectViewData.Kind.Scenario) {
if(musicViewData.scenarioViewData.ngReason == ScenarioViewData.PlayNGReason.None) {
onFinishPlayScenario(0, false);
}
if(musicViewData != null && musicViewData.kind == MusicSelectViewData.Kind.Scenario
&& musicViewData.scenarioViewData.ngReason == ScenarioViewData.PlayNGReason.None) {
onFinishPlayScenario(0, false);
updateSystemUIPanel();
return;
}
updateSystemUIPanel();
} else {
orig_Execute_Select();
}
orig_Execute_Select();
}
}

View File

@ -2,7 +2,7 @@
<PropertyGroup>
<TargetFramework>net35</TargetFramework>
<Company>7EVENDAYS⇔HOLIDAYS</Company>
<Version>2.3.0</Version>
<Version>2.3.1</Version>
<AllowUnsafeBlocks>true</AllowUnsafeBlocks>
<LangVersion>latest</LangVersion>
<Platforms>x64</Platforms>

View File

@ -23,4 +23,8 @@ class patch_Scene_30_NoticeReward: Scene_30_NoticeReward {
_mode.update();
}
}
private void End_Init() {
Skipped = false;
}
}

View File

@ -0,0 +1,20 @@
using MU3.Client;
using MU3.DB;
namespace MU3.User;
class patch_UserDetail: UserDetail {
public extern void orig_copyTo(UserData userDetail);
public new void copyTo(UserData userDetail) {
orig_copyTo(userDetail);
// Attempting to use a profile with InternalLevel sorting enabled
// causes unpatched clients to crash thanks to enormous incompetence
// of Sxga's interns. So, unfortunately, this value has to be discarded.
// See:
// * MusicSelectViewDataList._sort1 set
// * UserDetail.copyFrom()
if(userDetail.tabSetting == (int)patch_MusicSort1ID.InternalLevel) {
userDetail.tabSetting = (int)patch_MusicSort1ID.Level;
}
}
}

View File

@ -15,6 +15,7 @@ class patch_MusicSelectViewDataList: MusicSelectViewDataList {
private CompareProc _compareProc1;
private CompareProc _compareProc2;
private GetCategoryNameProc _getCategoryNameProc;
private PropertyInfo _reMasterPi = null;
private extern void orig_set__sort1(MusicSort1ID value);
private extern void orig_set__sort2(MusicSort2ID value);
@ -36,19 +37,18 @@ class patch_MusicSelectViewDataList: MusicSelectViewDataList {
}
}
private PropertyInfo reMasterPi = null;
private bool isReMaster(Data.MusicData d) {
// Fall back for pre-Act3
if(reMasterPi == null) {
if(_reMasterPi == null) {
return false;
}
return (bool)reMasterPi.GetValue(d, null);
return (bool)_reMasterPi.GetValue(d, null);
}
public extern void orig_create(GameViewData gameViewData, ChapterSelection chapterSelection, FumenDifficulty difficulty, MusicSort1ID sort1, MusicSort2ID sort2);
public new void create(GameViewData gameViewData, ChapterSelection chapterSelection, FumenDifficulty difficulty, MusicSort1ID sort1, MusicSort2ID sort2) {
reMasterPi = typeof(Data.MusicData).GetProperty("isReMaster");
_reMasterPi = typeof(Data.MusicData).GetProperty("isReMaster");
orig_create(gameViewData, chapterSelection, difficulty, sort1, sort2);
}
@ -100,7 +100,7 @@ class patch_MusicSelectViewDataList: MusicSelectViewDataList {
private extern int orig_getMetaSortKey(MusicSelectViewData d, bool forCategorySort);
private int getMetaSortKey(MusicSelectViewData d, bool forCategorySort) {
if(reMasterPi == null) {
if(_reMasterPi == null) {
return orig_getMetaSortKey(d, forCategorySort);
}
var remas = isReMaster(d.musicViewData.data);