修改本体,添加CrossTrackPoint兼容层,兼容StaticTrack Hold,为难度选项扩增全屏可选,添加和调整某些谱面
Signed-off-by: TRADER_FOER <lhf190@outlook.com>
This commit is contained in:
@@ -21,7 +21,7 @@ namespace Ichni.RhythmGame.Beatmap
|
||||
#if UNITY_STANDALONE
|
||||
return new FullScreenNearTimeJudgeUnit(attachedNote);
|
||||
#elif UNITY_ANDROID || UNITY_IOS
|
||||
if (SettingsManager.instance.gameSettings.judgeType)
|
||||
if (SettingsManager.instance.gameSettings.ShouldUseFullScreenJudge())
|
||||
{
|
||||
return new FullScreenNearTimeJudgeUnit(attachedNote);
|
||||
}
|
||||
@@ -29,6 +29,10 @@ namespace Ichni.RhythmGame.Beatmap
|
||||
{
|
||||
return new TouchAreaJudgeUnit(attachedNote, areaRadius);
|
||||
}
|
||||
#else
|
||||
return SettingsManager.instance.gameSettings.ShouldUseFullScreenJudge()
|
||||
? new FullScreenNearTimeJudgeUnit(attachedNote)
|
||||
: new TouchAreaJudgeUnit(attachedNote, areaRadius);
|
||||
#endif
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,29 +1,47 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
|
||||
namespace Ichni.RhythmGame.Beatmap
|
||||
{
|
||||
public class CrossTrackPoint_BM : GameElement_BM
|
||||
{
|
||||
public FlexibleInt trackSwitch;
|
||||
public FlexibleFloat trackPercent;
|
||||
public FlexibleInt_BM trackSwitch;
|
||||
public FlexibleFloat_BM trackPercent;
|
||||
|
||||
public CrossTrackPoint_BM()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public CrossTrackPoint_BM(string elementName, Guid elementGuid, System.Collections.Generic.List<string> tags,
|
||||
GameElement_BM attachedElement, FlexibleInt trackSwitch, FlexibleFloat trackPercent)
|
||||
public CrossTrackPoint_BM(string elementName, Guid elementGuid, List<string> tags,
|
||||
GameElement_BM attachedElement, FlexibleInt_BM trackSwitch, FlexibleFloat_BM trackPercent)
|
||||
: base(elementName, elementGuid, tags, attachedElement)
|
||||
{
|
||||
this.trackSwitch = trackSwitch;
|
||||
this.trackPercent = trackPercent;
|
||||
}
|
||||
|
||||
public CrossTrackPoint_BM(string elementName, Guid elementGuid, List<string> tags,
|
||||
GameElement_BM attachedElement, FlexibleInt trackSwitch, FlexibleFloat trackPercent)
|
||||
: this(elementName, elementGuid, tags, attachedElement, trackSwitch?.ConvertToBM(), trackPercent?.ConvertToBM())
|
||||
{
|
||||
}
|
||||
|
||||
public override void ExecuteBM()
|
||||
{
|
||||
NormalizeFlexibleFields();
|
||||
matchedElement = CrossTrackPoint.GenerateElement(elementName, elementGuid, tags, false,
|
||||
GetElement(attachedElementGuid) as ElementFolder, trackSwitch, trackPercent);
|
||||
GetElement(attachedElementGuid) as ElementFolder,
|
||||
trackSwitch?.ConvertToGameType() ?? new FlexibleInt(),
|
||||
trackPercent?.ConvertToGameType() ?? new FlexibleFloat());
|
||||
}
|
||||
|
||||
internal void NormalizeFlexibleFields()
|
||||
{
|
||||
trackSwitch ??= new FlexibleInt_BM();
|
||||
trackSwitch.animatedIntList ??= new List<AnimatedInt>();
|
||||
|
||||
trackPercent ??= new FlexibleFloat_BM();
|
||||
trackPercent.animatedFloatList ??= new List<AnimatedFloat>();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user